Everything Java Apache Geospatial Open Source. Hello Shinning Stars!!! Vincent Massol, Raphael Luta, Santiago Gala, Carsten Z.

Wednesday, June 16, 2004

This is my patch for my bug.

modules/core/src/java/org/openejb/deployment/OpenEJBModuleBuilder.java
TransactionPolicyHelper transactionPolicyHelper = new TransactionPolicyHelper(ejbJar.getAssemblyDescriptor());

modules/core/src/java/org/openejb/deployment/TransactionPolicyHelper.java
public TransactionPolicyHelper(AssemblyDescriptorType assemblyDescriptor) {
if (assemblyDescriptor != null) {
processContainerTransactions(assemblyDescriptor.getContainerTransactionArray());
}
}

public TransactionPolicyHelper(ContainerTransactionType[] containerTransactions) {
processContainerTransactions(containerTransactions);
}

private void processContainerTransactions(ContainerTransactionType[] containerTransactions) {
for (int i = 0; i < containerTransactions.length; i++) {
ContainerTransactionType containerTransaction = containerTransactions[i];
String transactionAttribute = containerTransaction.getTransAttribute().getStringValue();
MethodType[] methods = containerTransaction.getMethodArray();
for (int j = 0; j < methods.length; j++) {
MethodType method = methods[j];
String ejbName = method.getEjbName().getStringValue();
MethodTransaction methodTransaction = new MethodTransaction(method, transactionAttribute);
putMethodTransaction(ejbName, methodTransaction);
}
}
}
Keep an eye on the Overview (Geronimo :: System 1.0-SNAPSHOT API)
ejbJar : <xml-fragment version="2.1" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/ejb-jar_2_1.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:j2ee="http://java.sun.com/xml/ns/j2ee">
<j2ee:display-name>ConverterJAR</j2ee:display-name>
<j2ee:enterprise-beans>
<j2ee:session>
<j2ee:ejb-name>ConverterBean</j2ee:ejb-name>
<j2ee:home>converter.ConverterHome</j2ee:home>
<j2ee:remote>converter.Converter</j2ee:remote>
<j2ee:ejb-class>converter.ConverterBean</j2ee:ejb-class>
<j2ee:session-type>Stateless</j2ee:session-type>
<j2ee:transaction-type>Bean</j2ee:transaction-type>
<j2ee:security-identity>
<j2ee:use-caller-identity/>
</j2ee:security-identity>
</j2ee:session>
</j2ee:enterprise-beans>
</xml-fragment>
java.lang.NullPointerException
at org.openejb.deployment.OpenEJBModuleBuilder.addGBeans(OpenEJBModuleBuilder.java:426)
at org.openejb.deployment.OpenEJBModuleBuilder$$FastClassByCGLIB$$11bd7b20.invoke()
at net.sf.cglib.reflect.FastMethod.invoke(FastMethod.java:87)
at org.apache.geronimo.gbean.jmx.FastMethodInvoker.invoke(FastMethodInvoker.java:38)
at org.apache.geronimo.gbean.jmx.GBeanMBeanOperation.invoke(GBeanMBeanOperation.java:141)
at org.apache.geronimo.gbean.jmx.GBeanMBean.invoke(GBeanMBean.java:740)
at org.apache.geronimo.gbean.jmx.RawInvoker.invoke(RawInvoker.java:89)
at org.apache.geronimo.gbean.jmx.RawOperationInvoker.invoke(RawOperationInvoker.java:34)
at org.apache.geronimo.gbean.jmx.CGLibMethodInterceptor.intercept(CGLibMethodInterceptor.java:110)
at org.apache.geronimo.j2ee.deployment.ModuleBuilder$$EnhancerByCGLIB$$9e45a280.addGBeans()
at org.apache.geronimo.j2ee.deployment.EARConfigBuilder.buildConfiguration(EARConfigBuilder.java:225)
at org.apache.geronimo.j2ee.deployment.EARConfigBuilder.buildConfiguration(EARConfigBuilder.java:148)
at org.apache.geronimo.j2ee.deployment.EARConfigBuilder$$FastClassByCGLIB$$38e56ec6.invoke()
at net.sf.cglib.reflect.FastMethod.invoke(FastMethod.java:87)
at org.apache.geronimo.gbean.jmx.FastMethodInvoker.invoke(FastMethodInvoker.java:38)
at org.apache.geronimo.gbean.jmx.GBeanMBeanOperation.invoke(GBeanMBeanOperation.java:141)
at org.apache.geronimo.gbean.jmx.GBeanMBean.invoke(GBeanMBean.java:740)
at org.apache.geronimo.gbean.jmx.RawInvoker.invoke(RawInvoker.java:89)
at org.apache.geronimo.gbean.jmx.RawOperationInvoker.invoke(RawOperationInvoker.java:34)
at org.apache.geronimo.gbean.jmx.CGLibMethodInterceptor.intercept(CGLibMethodInterceptor.java:110)
at org.apache.geronimo.deployment.ConfigurationBuilder$$EnhancerByCGLIB$$7a1ca0ae.buildConfiguration()
at org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:132)
at org.apache.geronimo.deployment.Deployer$$FastClassByCGLIB$$734a235d.invoke()
at net.sf.cglib.reflect.FastMethod.invoke(FastMethod.java:87)
at org.apache.geronimo.gbean.jmx.FastMethodInvoker.invoke(FastMethodInvoker.java:38)
at org.apache.geronimo.gbean.jmx.GBeanMBeanOperation.invoke(GBeanMBeanOperation.java:141)
at org.apache.geronimo.gbean.jmx.GBeanMBean.invoke(GBeanMBean.java:761)
at mx4j.server.interceptor.InvokerMBeanServerInterceptor.invoke(InvokerMBeanServerInterceptor.java:218)
at mx4j.server.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:121)
at mx4j.server.interceptor.SecurityMBeanServerInterceptor.invoke(SecurityMBeanServerInterceptor.java:86)
at mx4j.server.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:121)
at mx4j.server.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:121)
at mx4j.server.interceptor.ContextClassLoaderMBeanServerInterceptor.invoke(ContextClassLoaderMBeanServerInterceptor.java:205)
at mx4j.server.MX4JMBeanServer.invoke(MX4JMBeanServer.java:1079)
at org.apache.geronimo.kernel.Kernel.invoke(Kernel.java:231)
at org.apache.geronimo.system.main.CommandLine.main(CommandLine.java:82)

Seems to be that this bug is due to the fact that the builder is looking for the assembly-descriptor element. This element is optional according xml schema descriptor file http://java.sun.com/xml/ns/j2ee/ejb-jar_2_1.xsd


Friday, June 11, 2004

java.lang.NullPointerException
at org.openejb.deployment.OpenEJBModuleBuilder.addGBeans(OpenEJBModuleBuilder.java:409)
at org.openejb.deployment.OpenEJBModuleBuilder$$FastClassByCGLIB$$11bd7b20.invoke()
at net.sf.cglib.reflect.FastMethod.invoke(FastMethod.java:87)
at org.apache.geronimo.gbean.jmx.FastMethodInvoker.invoke(FastMethodInvoker.java:38)
at org.apache.geronimo.gbean.jmx.GBeanMBeanOperation.invoke(GBeanMBeanOperation.java:141)
at org.apache.geronimo.gbean.jmx.GBeanMBean.invoke(GBeanMBean.java:740)
at org.apache.geronimo.gbean.jmx.RawInvoker.invoke(RawInvoker.java:89)
at org.apache.geronimo.gbean.jmx.RawOperationInvoker.invoke(RawOperationInvoker.java:34)
at org.apache.geronimo.gbean.jmx.CGLibMethodInterceptor.intercept(CGLibMethodInterceptor.java:110)
at org.apache.geronimo.j2ee.deployment.ModuleBuilder$$EnhancerByCGLIB$$9e45a280.addGBeans()
at org.apache.geronimo.j2ee.deployment.EARConfigBuilder.buildConfiguration(EARConfigBuilder.java:209)
at org.apache.geronimo.j2ee.deployment.EARConfigBuilder.buildConfiguration(EARConfigBuilder.java:142)
at org.apache.geronimo.j2ee.deployment.EARConfigBuilder$$FastClassByCGLIB$$38e56ec6.invoke()
at net.sf.cglib.reflect.FastMethod.invoke(FastMethod.java:87)
at org.apache.geronimo.gbean.jmx.FastMethodInvoker.invoke(FastMethodInvoker.java:38)
at org.apache.geronimo.gbean.jmx.GBeanMBeanOperation.invoke(GBeanMBeanOperation.java:141)
at org.apache.geronimo.gbean.jmx.GBeanMBean.invoke(GBeanMBean.java:740)
at org.apache.geronimo.gbean.jmx.RawInvoker.invoke(RawInvoker.java:89)
at org.apache.geronimo.gbean.jmx.RawOperationInvoker.invoke(RawOperationInvoker.java:34)
at org.apache.geronimo.gbean.jmx.CGLibMethodInterceptor.intercept(CGLibMethodInterceptor.java:110)
at org.apache.geronimo.deployment.ConfigurationBuilder$$EnhancerByCGLIB$$7a1ca0ae.buildConfiguration()
at org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:132)
at org.apache.geronimo.deployment.Deployer$$FastClassByCGLIB$$734a235d.invoke()
at net.sf.cglib.reflect.FastMethod.invoke(FastMethod.java:87)
at org.apache.geronimo.gbean.jmx.FastMethodInvoker.invoke(FastMethodInvoker.java:38)
at org.apache.geronimo.gbean.jmx.GBeanMBeanOperation.invoke(GBeanMBeanOperation.java:141)
at org.apache.geronimo.gbean.jmx.GBeanMBean.invoke(GBeanMBean.java:761)
at mx4j.server.interceptor.InvokerMBeanServerInterceptor.invoke(InvokerMBeanServerInterceptor.java:218)
at mx4j.server.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:121)
at mx4j.server.interceptor.SecurityMBeanServerInterceptor.invoke(SecurityMBeanServerInterceptor.java:86)
at mx4j.server.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:121)
at mx4j.server.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:121)
at mx4j.server.interceptor.ContextClassLoaderMBeanServerInterceptor.invoke(ContextClassLoaderMBeanServerInterceptor.java:205)
at mx4j.server.MX4JMBeanServer.invoke(MX4JMBeanServer.java:1079)
at org.apache.geronimo.kernel.Kernel.invoke(Kernel.java:231)
at org.apache.geronimo.system.main.CommandLine.main(CommandLine.java:82)

Thursday, June 10, 2004

How does the demo application work?
Check out Cactus, Clover.

I just had the idea to write a Getting Started guide to Geronimo.
Trying this in Geronimo :

java -jar bin/server.jar org/apache/geronimo/Demo

TIP : Before building Geronimo modify the file modules/assembly/src/plan/system-plan.xml changing INFO to DEBUG. This will tell Log4j to output debug statements.

Friday, June 04, 2004

gisig.com cvs coordinates :

:pserver:gisig.com:/home/cvs/anoncvs
I am trying to get the hang of this so that I can finnish the TutorialHowTo ... Google Search: openejb geronimo