I am now trying to use HiveMind as the kernel of my server (to replace some home-built code). I use it to register all the services and manage their lifecycle as needed. This allows me to separate the actual service definition and implementation from the core server code.
Eric
Howard M. Lewis Ship wrote:
Good, all is explained.
We have plans afoot to allow a much more complicated environment in the future using a two-step registry process. Basically, we build one registry, a bootstrap registry, and use that registry to build the actual runtime registry. Haven't thought through the details fully, yet, and this is something I want to do after the 1.0 release.
-- Howard M. Lewis Ship Creator, Tapestry: Java Web Components http://jakarta.apache.org/tapestry http://jakarta.apache.org/commons/sandbox/hivemind/ http://javatapestry.blogspot.com
-----Original Message----- From: news [mailto:[EMAIL PROTECTED] On Behalf Of Eric Yung Sent: Thursday, October 09, 2003 8:53 AM To: [EMAIL PROTECTED] Subject: Re: [HiveMind] extending BuilderFactory
Since I would like to record the ids of the services created by the BuilderFactory, I want to use an interceptor to do the job. Before I implements that solution, I take the logging interceptor as a test to check if HiveMind allows such setup.
And the result is that I cannot take this approach - HiveMind does NOT allow such setup. Add an interceptor to an BuilderFactory since the interceptor uses the BuilderFactory service.
Regards, Eric
Howard M. Lewis Ship wrote:
Did you add a logging interceptor to BuilderFactory?
--
Howard M. Lewis Ship
Creator, Tapestry: Java Web Components http://jakarta.apache.org/tapestry
http://jakarta.apache.org/commons/sandbox/hivemind/
http://javatapestry.blogspot.com
-----Original Message----- From: news [mailto:[EMAIL PROTECTED] On Behalf Of Eric Yung Sent: Thursday, October 09, 2003 5:44 AM To: [EMAIL PROTECTED] Subject: Re: [HiveMind] extending BuilderFactory
Hi,
After the testing I have built the newest version from the
CVS. When I re-run the test today, it shows the following error.
[junit] Unable to construct service js.util.testA: Unable to
construct service hivemind.BuilderFactory: Unable to construct service hivemind.LoggingInterceptor: A recursive call to construct service hivemind.BuilderFactory has occured. This indicates a cycle between one or more services or configurations.
And that's OK since the code can detect the cyclic dependency of the services.
BTW, I have changed my code to extend the BuilderFactory and create
another service point by copying the default BuilderFactory definition.
Regards, Eric
Howard M. Lewis Ship wrote:
But I notes from the debug log that the system creates multiple instances of the BuilderFactory & the interceptor - one for each <invoke-factory> config in the xml file. If I replace my
interceptor
with the "hivemind.LoggingInterceptor", the behavior is the same.
I would like to know if this is the system behavior if I add a interceptor in the service "hivemind.BuilderFactory" since the instantiation of interceptor requests the
"hivemind.BuilderFactory"
service.
hivemind.BuilderFactory is a singleton; it is created
exactly once.
I'd like to see the debug output you mention; there must be
misleading
output (perhaps due to the recent refactoring).
-- Howard M. Lewis Ship Creator, Tapestry: Java Web Components http://jakarta.apache.org/tapestry http://jakarta.apache.org/commons/sandbox/hivemind/ http://javatapestry.blogspot.com
------------------------------------------------------------
---------
To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]