Application cookbook refactoring

Hi everybody,

I wanted to give you an update on the ongoing refactoring of the
application cookbook.

TL;DR

it’s not 100% ready yet, but it’s definitely beta quality.
It has all the features of the current cookbook; adds a few new ones;
and it comes with a very cool DSL.
The only thing that is deprecated is the data bag—you will have to
convert to the DSL.
It is totally worth it, trust me.

Moar info

Let me start with a sample recipe showing off the DSL:


That’s what got me excited at the beginning: when Noah (who should be
credited with all the good and tough parts) showed me this I was
hooked.

What may not be immediately apparent in this example is that “django”,
“unicorn”, “celery” and “nginx_load_balancer” are separate
sub-resource LWRP, which do not live in the application cookbook. The
first three are from the application_python (unsurprisingly) while the
last one comes from application_nginx.
This modular approach makes it very easy to only bring in the
dependencies you need.
Also, implementing support for a new framework or stack component is
easier and much much cleaner than it was with the “old” application
cookbook.

I have gone over all the existing issues in Jira and merged what made
sense to merge; addressed a few issues that were still applicable but
needed a different fixed; and closed others that are not relevant
anymore.

Now I need to take some time off so I’m taking this opportunity to ask
you for help making sure this work for your use cases.
Please try it out and let me know whether you encounter any problem.

Caveats:

  • there probably are bugs, although I’ve spent a lot of time testing
    this. Don’t run this in production just yet;
  • there a few pre-existing warts that I haven’t addressed yet;
  • one of those is the Java support, which is sub-par; you are welcome
    to give it a try, but you are pretty much on your own there
  • some of the dependencies may not be on the community site yet. Make
    you sure you read the documentation through.

Where is it

More examples:

And again, I’d love to hear from you guys!

Andrea

I very much like the direction you are taking this, and look forward
to extended support for various java appservers following the same
model…
but I am curious, are you intending for this to remain a fork of
application, or do you intend to push it back and take over the
existing application cookbook from opscode?

On Mon, Apr 23, 2012 at 11:40 AM, Jesse Campbell hikeit@gmail.com wrote:

but I am curious, are you intending for this to remain a fork of
application, or do you intend to push it back and take over the
existing application cookbook from opscode?

Andrea's work will deprecate the existing Opscode application cookbook
and officially replace it.

--
Bryan McLellan | opscode | technical program manager, open source
(c) 206.607.7108 | (t) @btmspox | (b) http://blog.loftninjas.org

On Apr 23, 2012, at 10:30 AM, Bryan McLellan wrote:

On Mon, Apr 23, 2012 at 11:40 AM, Jesse Campbell hikeit@gmail.com wrote:

but I am curious, are you intending for this to remain a fork of
application, or do you intend to push it back and take over the
existing application cookbook from opscode?

Andrea's work will deprecate the existing Opscode application cookbook
and officially replace it.

More specifically it will merged back to the opscode-cookbooks org and will be maintained by Opscode like all our other cookbooks.

--Noah