Anything that has dependencies is a service. Anything you'd like to intercept is a service.
Anything that needs the threaded/pooled service model is a service. Tapestry 4.0 includes > 180 services. Very fine grained is perfectly ok. I like each service to be limited, where possible to 2 - 3 collaborators (other services injected in). I think the service interfaces are best with 2 - 3 methods. With all the DI going on, you'll see that the list of parameters for methods shrinks. You don't have to pass the FooBarService in as a parameter when the receiver can have it injected once and for all. Startup cost: Tapestry 4.0 does take a bit longer to start up than I'd like; something like .5 - 1.5 seconds to read the descriptors and build the Registry, then an additional 3 - 5 seconds to initialize things for Tapestry. In addition, the first request through is very sluggish as more services as "realized". This is an issue if you are building the Registry repeatedly for some reason. There is a startup cost for HiveMind that will go up (hopefully O(1)) as the number of services increases. There's also a memory cost. On 6/2/05, Glen Stampoultzis <[EMAIL PROTECTED]> wrote: > Was just wanting to get some peoples opinions on what sort of things should > be made into hivemind services? > > It seems to me that it would be pretty easy to go crazy and make all sorts > of services but I'm thinking that would probably be a bad idea. Where do > you stop? I'd be interested in hearing real life services people have > created. > > Regards, > > Glen Stampoultzis > > -- Howard M. Lewis Ship Independent J2EE / Open-Source Java Consultant Creator, Jakarta Tapestry Creator, Jakarta HiveMind Professional Tapestry training, mentoring, support and project work. http://howardlewisship.com --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
