cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Berin Loritsch <>
Subject Re: Singleton Component?
Date Mon, 29 Oct 2001 14:11:20 GMT
Ovidiu Predescu wrote:
> Is it possible to create a Component which is a singleton? I can
> implement the singleton myself but I was hoping to reuse an already
> implemented pattern from Avalon.

Extend the following interface:


This will share one instance between all Components in the CM.
WARNING: You better make sure that the Component is indeed ThreadSafe
or you will experience run-time anomolies.

Good thing for you, Avalon provides a number of Locks, Mutexes
Semaphores, ThreadBarrier, and other concurrency management tools.

To unsubscribe, e-mail:
For additional commands, email:

View raw message