[chef-dev] Re: Re: dependency spaghetti


Chronological Thread 
  • From: Blake Irvin < >
  • To: Noah Kantrowitz < >
  • Cc: Bryan Taylor < >, " Dev" < >
  • Subject: [chef-dev] Re: Re: dependency spaghetti
  • Date: Wed, 2 Oct 2013 17:41:37 -0700

Noah, your suggestion for 'suggests' sounds like the right compromise to me.

Lamont, parallel downloads would certainly be nice.  My DC is in CA right now, and cookbook sync takes upwards of 6 minutes.  To make test cycles fast enough to be worthwhile I think I'm going to have to roll my own chef servers (I can't ask engineers to wait 7 minutes just to *begin* an initial converge).

IIRC, the biggest reason I've ever used 'depends' in an incorrect way was that chef-client errors if a cookbook is missing are pretty cryptic, so I just (out of blind laziness) ended up depending all over the place.  About a year later (now), I've found that doing this is sub-optimal (and that's being as nice about it as I know how).


Blake


On Wed, Oct 2, 2013 at 5:32 PM, Noah Kantrowitz < " target="_blank"> > wrote:
There has been a long running concept to turn #suggests into an optional form of #depends, so it would have the same effect as depends if the cookbook is found in terms of triggering a download and loading in the right order, but wouldn't cause a failure if that cookbook wasn't found. Maybe after I get this dialect stuff squared away I'll write up that patch :)

--Noah

On Oct 2, 2013, at 5:26 PM, Bryan Taylor < "> > wrote:

>
> I agree. I'd like to see a notion of "conditional dependence", so that java depends on windows OR me setting an opt-out flag that says I won't ever windows.   I sometimes go in and edit these dependencies out of the metadata before I load it to my chef server. It happens a lot with yum or apt as well.
>
> From: Blake Irvin < "> >
> Date: Wednesday, October 2, 2013 6:17 PM
> To: " "> Dev" < "> >
> Subject: [chef-dev] dependency spaghetti
>
> (Please redirect me if this is the wrong list)
>
> We seem to be in a place as a Chef community where the 'depends' feature of cookbook metadata is getting used a little bit too freely.
>
> For example, the 'java' cookbook includes a 'depends' for the 'windows' cookbook - this means that I'm forced to download the 'windows' cookbook to all of my *nix machines.  Messy at best.
>
> Shouldn't we be using 'suggests'?  Or better yet, shouldn't we reserve dependency for cases where a cookbook really *must* have another cookbook available to it to compile (and, shouldn't we avoid tightly-coupled dependencies whenever possible because we don't wan to be brittle)?
>
> This is especially painful for us because we are currently seeing very slow download rates from hosted Chef (about 60kbps), so downloading addt'l cookbooks makes things noticeably slower.
>
> (Another great example of dependency hell is installing the 'nagios' cookbook, which requires 'apache', which requires 'php', which in turn requires 'mysql' - yet it's not really true that all of these things are intrinsically tied together - we are losing the things we've learned from the Unix model and service-oriented architectures when we staple things to each other this way.)
>
> Okay, so that got a little bit ranty, but that's because I really like Chef and I hate to see a slim, sexy, powerful tool get bloated and brittle for no good reason.
>
> Discuss!
>
>
> Blake





Archive powered by MHonArc 2.6.16.

§