[Embedlets-dev] Embedlet components
Status: Alpha
Brought to you by:
tkosan
|
From: Christopher S. <cs...@oo...> - 2003-07-06 21:20:12
Attachments:
EmbedletContainerLevels.pdf
|
On the Embedlet/Outpost front... I have run into some complexities attempting to integrate the Persistence model into the current Component model. The issue centers around the inclusion of the Context in the core definition of the component such that every component has to be aware of the context. This is the case as well with the model in the OopScope Process Components, hence the conflict... the component would now have to handle the Context and the Persistent models in order to integrate with both. It occurred to me that a more flexible approach would be to make it so that the core component requires no knowlege of the Context (unless explicitly required) or Persistence classes. A partner class would provide the Persistence/Context interface for the component and interact through the regular get/set Bean patterns. This would allow lightweight implementations (James) to drop the Persistence and Context models in favor of a hard-wired approach, yet the same Embedlet would be able to operate in these enriched enviroments, without modification, through the inclusion of the appropriate 'partner' class. A vendor would make the core Embedlet and the enriched partner available seperatly. Developers could choose the appropriate level of complexity based on their project needs and know that they could scale up to the enriched container model with the same components. This solves the JAPL initialization issue as well. Here the JAPL API is published with the standard Bean patterns and an Embedlet partner class provides the initialization when the JAPL component resides in an Embedlet container. Outside of the Embedlet container the JAPL can operate as a standalone device driver. In this light it may make sense to define Level I, Level II... container specifications that would outline the services avaiable: Level I (no partner required) - Life cycle - Logging - Event management - Requires hard code initialization Level II - Dynamic initialization (Context/Persistence) - Networking/Remote management Level III - Enterprise integration - Web Services (SOAP RPC) I have included a diagram to (hopefully) clarify this idea. I will post a sample Embedlet and partner class with this concept in place. This will be the BinaryToggle and BinaryToggleContext classes. Feedback? |