From: Alistair Y. <ali...@sm...> - 2006-03-23 13:06:24
|
That's interesting Jon. I take you mean http://www.clan.uhi.ac.uk/ mymodules Can you provide an exmaple of how a template would do RequestDispatcher.include() ? if it can't then I'd argue not to bother implementing it as we're back to the same thing. The plugin is neither a facility nor a servlet. It's a good idea for static output though, i.e. a news feed maybe and it's worth looking into. Be good for a /status servlet. However, the plugin can't be accessed outwith it's context - it means nothing until it's invoked by a template and it can get access to current user environment. Worth looking into though, thanks for the pointer. My only concern is exposing functionality to the world - that's a lot of security updates to maintain as every plugin is accessible via it's servlet. Each parallel servlet will have access to the bod environment but the difference will be they're publicly accessible and attackable. A plugin isn't. I'm still not convinced though. My Modules is just like a private JSP that lives in WEB-INF. It can't be accessed via a browser. Only a template can access it. I don't think you can get a "private" servlet but I haven't looked into it enough. I'm resisting labelling it anything other than a plugin - coz that's what it is. Interesting discussions, keep 'em coming :) Alistair On 23 Mar 2006, at 12:47, Jon Maber wrote: > Alistair, > > Basically your plugin is a servlet. You could implement it as a > subclass of HttpServlet, deploy it by referencing the class in the > web app config. file and access it from the Bodington template as a > servlet include. You could even update the class and the standard > Tomcat class loader will reload and instantiate the new version. If > there is something about the templates that stops the call to > "include" that could be easily fixed and should be fixed because > calling installed servlets is a very obvious thing that people will > want to do. > > In the future people might want runtime installable modules that > really interact with Bodington and that would require a more > involved solution. > > This is my recommendation as an unpaid consultant - if you don't > like it pay me to give you the answer you want ;-) > > Jon > > > Alistair Young wrote: > >>> Instantiation of the Plugin >> >> at the moment, one instance per template with shared functionality >> in that instance. It's in it's infancy just now so that's likely >> to change. >> >>> Initialisation >> >> at first instantiation >> >>> Calls out from plugin >> >> uses some bod methods to get current user > > >> >>> Calls into the plugin >>> Does your plugin have multiple functionality? >> >> no >> >>> Does it use parameters to its method calls? >> >> no >> >> It's functionality is implied by it's interface contract - it's >> an HTMLPlugin so that's all it does, outputs HTML. Facility just >> calls it's run() method. >> >> It connects to a database to get the info to generate the HTML. >> >> Alistair >> >> On 23 Mar 2006, at 12:11, Jon Maber wrote: >> > > > > ------------------------------------------------------- > This SF.Net email is sponsored by xPML, a groundbreaking scripting > language > that extends applications into web and mobile media. Attend the > live webcast > and join the prime developer group breaking into this new coding > territory! > http://sel.as-us.falkag.net/sel? > cmd=lnk&kid=110944&bid=241720&dat=121642 > _______________________________________________ > Bodington-developers mailing list > Bod...@li... > https://lists.sourceforge.net/lists/listinfo/bodington-developers |