[Design of POJO Server] - Re: Updating docs
by adrian@jboss.org
They express an intention to implement 2 phase deployment
and atomic redeployment.
new.prepareDeploy() // take the new deployment to the ready stage
old.prepareUndeploy() // get ready to undeploy
handoff(new, old); // handover control
new.commitDeploy(); // you are now in control
old.commitUndeploy(); // you are out of here
I doubt the final api will be this simple since it will have to deal
with mutliple deployers on multiple aspects of the deployment. :-)
For now, the AbstractSimpleDeployer is a better api
with its deploy()/undeploy()
In fact, I'm aiming for an api where the deployers don't
really deal with the lifecycle directly and instead provide
metadata on which parts of the deployment they want
to do work on and "when".
e.g.
SARDeployer
I create a ServiceDeployment and LoaderRepositoryConfig from -service.xml
ServiceDeploymentDeployer
I split a ServiceDeployment into its component ServiceMetaData
ServiceClassLoaderDeployer
I create classloaders from LoaderRepositoryConfig
ServiceDeployer
I'm the real deployer of ServiceMetaData
etc.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3972610#3972610
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3972610
19 years, 6 months
[Design the new POJO MicroContainer] - Deploying MC 2.0 snapshot in JBoss 4.0x
by kabir.khan@jboss.com
I am trying to get things ready for an AOP 2.0 alpha release, and since AOP now depends a lot more on the microcontainer I need to get the jboss-beans.deployer from head deployed in Branch_4_0. (This is just trying it out, I will package a real release later on).
Classes that definitely are missing in JBoss 4.0 are:
org.jboss.deployment.SchemaResolverSimpleSubDeployerSupport
org.jboss.util.collection.WeakClassCache (moved from org.jboss.util.connection since jboss 4.0.x)
org.jboss.util.collection.CollectionsFactory (moved from org.jboss.util.connection since jboss 4.0.x)
After adding these missing classes I am able to get the JBossBeanDeployer started, but when starting web services I get the following error
| 2006-09-19 14:00:45,468 ERROR [org.jboss.deployment.MainDeployer] Could not initialise deployment: file:/C:/cygwin/home/Kabir/sourcecontrol/Branch_4_0/build/output/jboss-4.0.5.GA-ejb3/server/aop2/deploy/jbossws.sar/
| org.jboss.deployment.DeploymentException: Error parsing meta data jar:file:/C:/cygwin/home/Kabir/sourcecontrol/Branch_4_0/build/output/jboss-4.0.5.GA-ejb3/server/aop2/tmp/deploy/tmp49993jbossws.beans!/META-INF/jboss-beans.xml; - nested throwable: (org.jboss.xb.binding.JBossXBException: Failed to parse source: jar:file:/C:/cygwin/home/Kabir/sourcecontrol/Branch_4_0/build/output/jboss-4.0.5.GA-ejb3/server/aop2/tmp/deploy/tmp49993jbossws.beans!/META-INF/jboss-beans.xml@5,35)
| at org.jboss.deployment.DeploymentException.rethrowAsDeploymentException(DeploymentException.java:53)
| at org.jboss.deployment.SchemaResolverSimpleSubDeployerSupport.parseMetaData(SchemaResolverSimpleSubDeployerSupport.java:57)
| at org.jboss.kernel.deployment.jboss.JBossBeanDeployer.parseMetaData(JBossBeanDeployer.java:87)
| at org.jboss.deployment.SimpleSubDeployerSupport.init(SimpleSubDeployerSupport.java:88)
| at org.jboss.deployment.MainDeployer.init(MainDeployer.java:872)
| at org.jboss.deployment.MainDeployer.init(MainDeployer.java:895)
| --- SNIP ----
| Caused by: org.jboss.xb.binding.JBossXBException: Failed to parse source: jar:file:/C:/cygwin/home/Kabir/sourcecontrol/Branch_4_0/build/output/jboss-4.0.5.GA-ejb3/server/aop2/tmp/deploy/tmp49993jbossws.beans!/META-INF/jboss-beans.xml@5,35
| at org.jboss.xb.binding.parser.sax.SaxJBossXBParser.parse(SaxJBossXBParser.java:142)
| at org.jboss.xb.binding.UnmarshallerImpl.unmarshal(UnmarshallerImpl.java:133)
| at org.jboss.deployment.SchemaResolverSimpleSubDeployerSupport.parseMetaData(SchemaResolverSimpleSubDeployerSupport.java:51)
| ... 71 more
| Caused by: java.lang.NullPointerException
| at org.jboss.kernel.plugins.deployment.xml.BeanSchemaBinding.configureValueBindings(BeanSchemaBinding.java:1207)
| at org.jboss.kernel.plugins.deployment.xml.BeanSchemaBinding.init(BeanSchemaBinding.java:410)
| at org.jboss.kernel.plugins.deployment.xml.BeanSchemaInitializer.init(BeanSchemaInitializer.java:37)
| at org.jboss.xb.binding.sunday.unmarshalling.DefaultSchemaResolver.resolve(DefaultSchemaResolver.java:257)
| at org.jboss.xb.binding.sunday.unmarshalling.SundayContentHandler.startElement(SundayContentHandler.java:162)
| at org.jboss.xb.binding.parser.sax.SaxJBossXBParser$DelegatingContentHandler.startElement(SaxJBossXBParser.java:301)
| at org.apache.xerces.parsers.AbstractSAXParser.startElement(Unknown Source)
| at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source)
| at org.apache.xerces.impl.XMLNSDocumentScannerImpl$NSContentDispatcher.scanRootElementHook(Unknown Source)
| at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
| at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
| at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
| at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
| at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
| at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
| at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
| at org.jboss.xb.binding.parser.sax.SaxJBossXBParser.parse(SaxJBossXBParser.java:138)
| ... 73 more
|
| private static void configureValueBindings(TypeBinding typeBinding)
| {
| // type has values
| typeBinding.pushInterceptor(valueQName, VALUES); <- failure
|
| ...
| }
|
The typeBinding passed in to BeanSchemaBinding.configureValueBindings() is null. I'm not that familiar with JBoss XB, is there a simple explanation? Is there anything else I need to configure?
BTW the null type binding seems to be obtained via
| // classloader binding
| TypeBinding classloaderType = schemaBinding.getType(classloaderTypeQName);
| configureValueBindings(classloaderType);
| classloaderType.setHandler(new DefaultElementHandler()
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3972590#3972590
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3972590
19 years, 6 months