Re: [JBoss-dev] JSR-77 and Jetty
As Jetty already wraps it's major components as MBeans (Listeners and Contexts) then I think it makes sense for the AbstractWebContainer only to define interfaces for the components that need to be managed. Then the specific web container can instantiate those component MBeans with the JSR-77 attributes plus any container specific attributes. If the web container only provided data rather than created the management objects, then it would be difficult to include additional attributes and methods. I guess we could have two sets of MBeans, but that is a bit ugly. Scott M Stark wrote: It does not have to be exposed if its not a useful op. These management objects can just be created, registered on deployment of a web module and unregistered when the web module is undeployed. That would be simpler. I'm not sure if the web container will have to actually create the management objects or just provide the info to create these. Since you could define a WebModule that has its stateManageable, statisticsProvider, and eventProvider attributes false, a minimal managed view could be provided using simple data objects from the web server. That should be a supported option as it is a low barrier of entry for the web server integrater. The more complex the management object implementation in terms of those attributes the more it seems the web server itself will have to create the management object. Scott Stark Chief Technology Officer JBoss Group, LLC - Original Message - From: Andreas Schaefer [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, June 20, 2002 5:43 PM Subject: Re: [JBoss-dev] JSR-77 and Jetty Hi Scott At a minimum at the AbstractWebContainer level we define the hooks to obtain the required Servlet[] management objects needed to make up the WebModule management object. There may not be much to this other than a simple template method that defines the requirements for obtaining management information/callbacks to impliment the JSR-77 objects. These are not attributes or operations of the web container right? They are just mbeans bound into the JSR-77 management namespace. Maybe there is a WebModule[] getWebModules() operation here? Just to see that I understand you correctly. You want to expose a list of JSR-77 MBeans by the AbstractWebContainer with getWebModule(). And the JSR-77 MBeans are provided by the Web server. Correct ? Andy --- Sponsored by: ThinkGeek at http://www.ThinkGeek.com/ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development -- Greg Wilkins[EMAIL PROTECTED] GB Phone: +44-(0)7092063462 Mort Bay Consulting Australia and UK.Mbl Phone: +61-(0)4 17786631 http://www.mortbay.com AU Phone: +61-(0)2 98107029 --- Sponsored by: ThinkGeek at http://www.ThinkGeek.com/ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] JSR-77 and Jetty
Contexts, filters and servlets can all be individually stopped and started in Jetty, with the following results: A stopped context will not be given any new requests. All components (servlets/filters) of a context will be stopped when stop is called on the context However, there may be an issue with the getContext().getRequestDispatcher() path still being able to inject requests to a stopped context. These should not be handled, but I'll look at dealing with them better. If a request does make it to a stopped servlet, then an Unavailable exception will be thrown. Need to consider if this is correct, maybe their mapping should just dissappear. However, they could still be access by RequestDispatcher that were created before the stop, so the Unavailable exception is correct then. A stop/start of a servlet does the servlet lifecycle destroy/initialize thang. Looking at it, I think I need to tidy up handling of stopped filters. Does JSR77 say anything about managing Filters? They should look pretty much the same as servlets. Note there are no methods to get all the servlets, but it is trivial to add and I will do so shortly. The question is what API should it return for each servlet? Not the servlet itself as calls to the lifecycle methods will go straight to client code and the container will not be able to manage them properly. Jules Gosnell wrote: Andreas Schaefer wrote: Hi Jules 1. Are you sure that JSR77 talks at the granularity of Servlets - or is it WebApplications - or both. A Servlet is not the unit of deployment, the WebApplication is. A WebApplication may contain 0-n Servlets. JSR-77 have an application (EAR) with one or more modules (WAR,JAR,RAR) and each containing eithe EJBs, Servlets or ResourceAdaptors. So, yes, JSR-77 needs both the web application and the servlets its contains. OK - can do. 2. Jetty has a concept of deploy, start, stop and undeploy. Currently webapps are started as soon as they are deployed - so when you say start/stop, do you mean deploy/undeploy or start/stop ? JSR-77 is not clear in this point but the lack of the creation of services I think it means to start/stop but not deploy/undeploy. BTW what does start/stop mean (make it available/unavailable to serve) ? What happens with the servlets at this time. Can you start/stop servlets ? start/stop means (Greg can give you the exact definition for Jetty) something like make-available-to-client. If the webapp is stopped, it is still deployed but the client cannot see it - although it can be restarted very quickly... 3. I am keen for Jetty to support a restart() and a redeploy() - atomic functions which put incoming requests on hold while they do their job - thus ensuring 24*7 service, with no lost requests, even if you upgrade your website at a peak time... I believe JSR77 also has optional? provision for (at least one of) these. I think that it is important that we support it from the start even if it is simply implemented in terms of the others... Ahhmm, where did you see that in JSR-77 ? Aha ! - I think I am getting 77 and 88 confused again ! Jules Thanx - Andy --- Sponsored by: ThinkGeek at http://www.ThinkGeek.com/ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development -- Greg Wilkins[EMAIL PROTECTED] GB Phone: +44-(0)7092063462 Mort Bay Consulting Australia and UK.Mbl Phone: +61-(0)4 17786631 http://www.mortbay.com AU Phone: +61-(0)2 98107029 --- Sponsored by: ThinkGeek at http://www.ThinkGeek.com/ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] JSR-77 and Jetty
Hi Greg To make JSR-77 implementation (a J2EE management API) complete I need to support the web-service and I wills start with Jetty (it seems to be tough enough). To start with I need a place where I can create a WebModule (represents a WAR file) and each Servlet (for now the once defined in web.xml). For me its seems that the deployment of the servlets are deep inside Jetty and I am not quite sure how we want to integrate JSR-77 into Jetty. Beause JSR-77 does not provide Java classes to implement I would suggest that the necessary information are provide by Jetty MBeans so that JSR-77 can pick it up and perform the appropriate steps. Therefore I need: - List of Servlets deployed - A way to start/stop servlets if possible (I would think this means load/unload a Servlet) - Any attributes you maybe want to expose to manage servlets (no attributes specified in the JSR-77 spec.) Is this possible ? Thanx Andy Schaefer Code or be coded Check out: www.madplanet.com --- Sponsored by: ThinkGeek at http://www.ThinkGeek.com/ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] JSR-77 and Jetty
As much of this as possible should be handled at the org.jboss.web.AbstractWebContainer or else we will have to duplicate this for every web container service. Scott Stark Chief Technology Officer JBoss Group, LLC - Original Message - From: Andreas Schaefer [EMAIL PROTECTED] To: Greg Wilkins [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Sent: Thursday, June 20, 2002 3:59 PM Subject: [JBoss-dev] JSR-77 and Jetty Hi Greg To make JSR-77 implementation (a J2EE management API) complete I need to support the web-service and I wills start with Jetty (it seems to be tough enough). To start with I need a place where I can create a WebModule (represents a WAR file) and each Servlet (for now the once defined in web.xml). For me its seems that the deployment of the servlets are deep inside Jetty and I am not quite sure how we want to integrate JSR-77 into Jetty. Beause JSR-77 does not provide Java classes to implement I would suggest that the necessary information are provide by Jetty MBeans so that JSR-77 can pick it up and perform the appropriate steps. Therefore I need: - List of Servlets deployed - A way to start/stop servlets if possible (I would think this means load/unload a Servlet) - Any attributes you maybe want to expose to manage servlets (no attributes specified in the JSR-77 spec.) Is this possible ? Thanx Andy Schaefer Code or be coded Check out: www.madplanet.com --- Sponsored by: ThinkGeek at http://www.ThinkGeek.com/ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] JSR-77 and Jetty
Hi Scott As much of this as possible should be handled at the org.jboss.web.AbstractWebContainer or else we will have to duplicate this for every web container service. I would like that but how are we going to expose attributes and methods dynamically in the Abstract- WebContainer ? Andy --- Sponsored by: ThinkGeek at http://www.ThinkGeek.com/ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] JSR-77 and Jetty
Andreas, I think that you will find that Jetty already exposes all this to JBoss via JMX (perhaps not the list of current deployments - but that's not a problem - I will sort it). However a few points. 1. Are you sure that JSR77 talks at the granularity of Servlets - or is it WebApplications - or both. A Servlet is not the unit of deployment, the WebApplication is. A WebApplication may contain 0-n Servlets. 2. Jetty has a concept of deploy, start, stop and undeploy. Currently webapps are started as soon as they are deployed - so when you say start/stop, do you mean deploy/undeploy or start/stop ? 3. I am keen for Jetty to support a restart() and a redeploy() - atomic functions which put incoming requests on hold while they do their job - thus ensuring 24*7 service, with no lost requests, even if you upgrade your website at a peak time... I believe JSR77 also has optional? provision for (at least one of) these. I think that it is important that we support it from the start even if it is simply implemented in terms of the others... Comments ? Jules Andreas Schaefer wrote: Hi Greg To make JSR-77 implementation (a J2EE management API) complete I need to support the web-service and I wills start with Jetty (it seems to be tough enough). To start with I need a place where I can create a WebModule (represents a WAR file) and each Servlet (for now the once defined in web.xml). For me its seems that the deployment of the servlets are deep inside Jetty and I am not quite sure how we want to integrate JSR-77 into Jetty. Beause JSR-77 does not provide Java classes to implement I would suggest that the necessary information are provide by Jetty MBeans so that JSR-77 can pick it up and perform the appropriate steps. Therefore I need: - List of Servlets deployed - A way to start/stop servlets if possible (I would think this means load/unload a Servlet) - Any attributes you maybe want to expose to manage servlets (no attributes specified in the JSR-77 spec.) Is this possible ? Thanx Andy Schaefer Code or be coded Check out: www.madplanet.com --- Sponsored by: ThinkGeek at http://www.ThinkGeek.com/ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development --- Sponsored by: ThinkGeek at http://www.ThinkGeek.com/ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] JSR-77 and Jetty
No problem - you specify the interface, and I shall implement the Jetty side. Jules Scott M Stark wrote: As much of this as possible should be handled at the org.jboss.web.AbstractWebContainer or else we will have to duplicate this for every web container service. Scott Stark Chief Technology Officer JBoss Group, LLC - Original Message - From: Andreas Schaefer [EMAIL PROTECTED] To: Greg Wilkins [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Sent: Thursday, June 20, 2002 3:59 PM Subject: [JBoss-dev] JSR-77 and Jetty Hi Greg To make JSR-77 implementation (a J2EE management API) complete I need to support the web-service and I wills start with Jetty (it seems to be tough enough). To start with I need a place where I can create a WebModule (represents a WAR file) and each Servlet (for now the once defined in web.xml). For me its seems that the deployment of the servlets are deep inside Jetty and I am not quite sure how we want to integrate JSR-77 into Jetty. Beause JSR-77 does not provide Java classes to implement I would suggest that the necessary information are provide by Jetty MBeans so that JSR-77 can pick it up and perform the appropriate steps. Therefore I need: - List of Servlets deployed - A way to start/stop servlets if possible (I would think this means load/unload a Servlet) - Any attributes you maybe want to expose to manage servlets (no attributes specified in the JSR-77 spec.) Is this possible ? Thanx Andy Schaefer Code or be coded Check out: www.madplanet.com --- Sponsored by: ThinkGeek at http://www.ThinkGeek.com/ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development --- Sponsored by: ThinkGeek at http://www.ThinkGeek.com/ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] JSR-77 and Jetty
At a minimum at the AbstractWebContainer level we define the hooks to obtain the required Servlet[] management objects needed to make up the WebModule management object. There may not be much to this other than a simple template method that defines the requirements for obtaining management information/callbacks to impliment the JSR-77 objects. These are not attributes or operations of the web container right? They are just mbeans bound into the JSR-77 management namespace. Maybe there is a WebModule[] getWebModules() operation here? Scott Stark Chief Technology Officer JBoss Group, LLC - Original Message - From: Andreas Schaefer [EMAIL PROTECTED] To: [EMAIL PROTECTED]; Scott M Stark [EMAIL PROTECTED] Sent: Thursday, June 20, 2002 5:08 PM Subject: Re: [JBoss-dev] JSR-77 and Jetty Hi Scott As much of this as possible should be handled at the org.jboss.web.AbstractWebContainer or else we will have to duplicate this for every web container service. I would like that but how are we going to expose attributes and methods dynamically in the Abstract- WebContainer ? Andy --- Sponsored by: ThinkGeek at http://www.ThinkGeek.com/ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] JSR-77 and Jetty
Hi Jules 1. Are you sure that JSR77 talks at the granularity of Servlets - or is it WebApplications - or both. A Servlet is not the unit of deployment, the WebApplication is. A WebApplication may contain 0-n Servlets. JSR-77 have an application (EAR) with one or more modules (WAR,JAR,RAR) and each containing eithe EJBs, Servlets or ResourceAdaptors. So, yes, JSR-77 needs both the web application and the servlets its contains. 2. Jetty has a concept of deploy, start, stop and undeploy. Currently webapps are started as soon as they are deployed - so when you say start/stop, do you mean deploy/undeploy or start/stop ? JSR-77 is not clear in this point but the lack of the creation of services I think it means to start/stop but not deploy/undeploy. BTW what does start/stop mean (make it available/unavailable to serve) ? What happens with the servlets at this time. Can you start/stop servlets ? 3. I am keen for Jetty to support a restart() and a redeploy() - atomic functions which put incoming requests on hold while they do their job - thus ensuring 24*7 service, with no lost requests, even if you upgrade your website at a peak time... I believe JSR77 also has optional? provision for (at least one of) these. I think that it is important that we support it from the start even if it is simply implemented in terms of the others... Ahhmm, where did you see that in JSR-77 ? Thanx - Andy --- Sponsored by: ThinkGeek at http://www.ThinkGeek.com/ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] JSR-77 and Jetty
Hi Jules No problem - you specify the interface, and I shall implement the Jetty side. The problem is there is no interface. That is what I need to have: - WebModule (represents WAR) - web.xml content - List of Servlets per WebModule Both WebModule can emits Notifications, manage a state (start() and stop()) and statistics. You can also exposes any other methods and attributes as you like and that is what I want to expose additionally: - WebModule - jboss-web.xml content - Servlet - load on startup - init parameters See me anwser to Scotts email as well. Andy Scott M Stark wrote: As much of this as possible should be handled at the org.jboss.web.AbstractWebContainer or else we will have to duplicate this for every web container service. Scott Stark Chief Technology Officer JBoss Group, LLC --- Sponsored by: ThinkGeek at http://www.ThinkGeek.com/ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] JSR-77 and Jetty
Hi Scott At a minimum at the AbstractWebContainer level we define the hooks to obtain the required Servlet[] management objects needed to make up the WebModule management object. There may not be much to this other than a simple template method that defines the requirements for obtaining management information/callbacks to impliment the JSR-77 objects. These are not attributes or operations of the web container right? They are just mbeans bound into the JSR-77 management namespace. Maybe there is a WebModule[] getWebModules() operation here? Just to see that I understand you correctly. You want to expose a list of JSR-77 MBeans by the AbstractWebContainer with getWebModule(). And the JSR-77 MBeans are provided by the Web server. Correct ? Andy --- Sponsored by: ThinkGeek at http://www.ThinkGeek.com/ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] JSR-77 and Jetty
Andreas Schaefer wrote: Hi Jules 1. Are you sure that JSR77 talks at the granularity of Servlets - or is it WebApplications - or both. A Servlet is not the unit of deployment, the WebApplication is. A WebApplication may contain 0-n Servlets. JSR-77 have an application (EAR) with one or more modules (WAR,JAR,RAR) and each containing eithe EJBs, Servlets or ResourceAdaptors. So, yes, JSR-77 needs both the web application and the servlets its contains. OK - can do. 2. Jetty has a concept of deploy, start, stop and undeploy. Currently webapps are started as soon as they are deployed - so when you say start/stop, do you mean deploy/undeploy or start/stop ? JSR-77 is not clear in this point but the lack of the creation of services I think it means to start/stop but not deploy/undeploy. BTW what does start/stop mean (make it available/unavailable to serve) ? What happens with the servlets at this time. Can you start/stop servlets ? start/stop means (Greg can give you the exact definition for Jetty) something like make-available-to-client. If the webapp is stopped, it is still deployed but the client cannot see it - although it can be restarted very quickly... 3. I am keen for Jetty to support a restart() and a redeploy() - atomic functions which put incoming requests on hold while they do their job - thus ensuring 24*7 service, with no lost requests, even if you upgrade your website at a peak time... I believe JSR77 also has optional? provision for (at least one of) these. I think that it is important that we support it from the start even if it is simply implemented in terms of the others... Ahhmm, where did you see that in JSR-77 ? Aha ! - I think I am getting 77 and 88 confused again ! Jules Thanx - Andy --- Sponsored by: ThinkGeek at http://www.ThinkGeek.com/ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development --- Sponsored by: ThinkGeek at http://www.ThinkGeek.com/ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] JSR-77 and Jetty
It does not have to be exposed if its not a useful op. These management objects can just be created, registered on deployment of a web module and unregistered when the web module is undeployed. That would be simpler. I'm not sure if the web container will have to actually create the management objects or just provide the info to create these. Since you could define a WebModule that has its stateManageable, statisticsProvider, and eventProvider attributes false, a minimal managed view could be provided using simple data objects from the web server. That should be a supported option as it is a low barrier of entry for the web server integrater. The more complex the management object implementation in terms of those attributes the more it seems the web server itself will have to create the management object. Scott Stark Chief Technology Officer JBoss Group, LLC - Original Message - From: Andreas Schaefer [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, June 20, 2002 5:43 PM Subject: Re: [JBoss-dev] JSR-77 and Jetty Hi Scott At a minimum at the AbstractWebContainer level we define the hooks to obtain the required Servlet[] management objects needed to make up the WebModule management object. There may not be much to this other than a simple template method that defines the requirements for obtaining management information/callbacks to impliment the JSR-77 objects. These are not attributes or operations of the web container right? They are just mbeans bound into the JSR-77 management namespace. Maybe there is a WebModule[] getWebModules() operation here? Just to see that I understand you correctly. You want to expose a list of JSR-77 MBeans by the AbstractWebContainer with getWebModule(). And the JSR-77 MBeans are provided by the Web server. Correct ? Andy --- Sponsored by: ThinkGeek at http://www.ThinkGeek.com/ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development