-
-
2. Re: upgrading from 2.4.4 to 3.0.7
jonlee Jul 28, 2003 8:44 AM (in response to djs1w)OK. As best I can:
The addition of the doctype is not absolutely necessary in 3.0.x but is necessary in 3.2.x to pass the strict verification of the XML. I suppose it is to indicate the
The explicit CMP definition is to tell the container which CMP engine to use. Because you have included the EJB template for spec 2.0, normally the assumption would be that you want to use the CMP 2.0 engine (2.4.x did not support CMP 2.0).
Not quite sure why the ejb-ref tags were commented out. I would have assumed you are still going to want to reference these other components. Unless the intention was to recode and use local references through <ejb-local-ref>. This would make sense I suppose, so to support that you would need the EJB 2.0 DTD. However, you probably don't want to do a major recode of any entity beans for CMP 2.0 so you need to specify the CMP spec you are adhering to is 1.x.
Otherwise, to avoid all this and avoid having to recode anything, you would just re-instate your ejb-refs, remove the CMP 1.x tags and substitute your doctype with this:
<!DOCTYPE ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 1.1//EN" "http://java.sun.com/j2ee/dtds/ejb-jar_1_1.dtd">
I'm assuming the internal servlet error is due to some EJB not being found because you've removed the reference and not replaced it with anything. You should be getting console errors, or something in the logs saying why the JSP failed - probably "null" something or other.
A bit hard to guess without specific cases though. Hope that helps a bit. -
3. Re: upgrading from 2.4.4 to 3.0.7
jonlee Jul 28, 2003 8:53 AM (in response to djs1w)Sorr that first paragraph was munged by a combination of network and Opera. What I mean to say at the end of it is that your doctype specifies the DTD to be used to verify your XML. In this case, it says use the DTD for the EJB 2.0 spec.
-
4. Re: upgrading from 2.4.4 to 3.0.7
djs1w Jul 29, 2003 7:24 AM (in response to djs1w)Ok, it's slowly starting to make some sense. I did the following things you mentioned:
1) reinstated my ejb-refs
2) removed the CMP 1.x tags
3) and changed the doctype to 1.1
All the things you wanted me to do, are what our application code repository looks like when we do a build (with ant) for JBoss 2.4.4. So I really didn't have to do anything you asked, I just checkout a fresh copy from CVS. If I take that repository and do a build against JBoss 3.x, the build is successful, however I get these errors when the application is deployed:
----------------------------------------------
2003-07-29 08:10:57,311 WARN [org.jboss.metadata.EntityMetaData] Client: The abstract-schema-name Element must be specified for CMP 2.x Beans
2003-07-29 08:10:57,313 WARN [org.jboss.metadata.EntityMetaData] Client: The abstract-schema-name must be a valid Java Identifier 'null'
-----------------------------------------------
followed by:
---------------------------------------
Bean : Client
Section: 10.6.2
Warning: The entity bean class must be defined as public and abstract.
2003-07-29 08:10:58,317 INFO [org.jboss.ejb.EJBDeployer]
Bean : Client
Section: 10.6.2
Warning: The entity bean class must define a set accessor for each CMP field.
Info : Field: clientId
----------------------------------------------------
Let me know if you need any more information, and the help is much appreciated, thanks! -
5. Re: upgrading from 2.4.4 to 3.0.7
jonlee Jul 29, 2003 8:03 AM (in response to djs1w)I would manually check the ejb-jar.xml of the JARs that failed deployment. I'm not sure if you have EAR bundles or JAR bundles for your EJB deployment but you need to track down the particular EJB deployments that failed and check these files. You will probably find they still have the DTD for 2.0 specified. This is causing JBoss to think they are CMP 2.x deployments and it expects the <abstract-schema-name> defined in the deployment. That will probably lead to your other failures - otherwise they are a different issue.
I just experimented with some old 2.4.x deployments I had lying around. It spits this out with the 2.0 doctype declaration (<!DOCTYPE ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN" "http://java.sun.com/j2ee/dtds/ejb-jar_2_0.dtd">
):
org.jboss.deployment.DeploymentException: Error in ejb-jar.xml for Entity Bean BiblioRef: The abstract-schema-name must be specified for CMP 2.x Beans
at org.jboss.metadata.ApplicationMetaData.importEjbJarXml(Unknown Source
)
at org.jboss.metadata.XmlFileLoader.load(Unknown Source) -
6. Re: upgrading from 2.4.4 to 3.0.7
djs1w Jul 29, 2003 9:32 AM (in response to djs1w)Yeah there was one file I missed that had the 2.0 specified. Now I'm receiving this error on deployment:
org.jboss.deployment.DeploymentException: ejb-ref: Blotter/Blotter, no ejb-link match, use jndi-name in jboss-web.xml; - nested throwable: (javax.naming.NamingException: ejb-ref: Blotter/Blotter, no ejb-link match, use jndi-name in jboss-web.xml) -
7. Re: upgrading from 2.4.4 to 3.0.7
jonlee Jul 29, 2003 12:15 PM (in response to djs1w)Sounds like some changes have been made in this area. You are referencing Blotter/Blotter but this should link through to an entry specifying the actual JNDI name reference but you don't have that. I'm going off-line but someone should be able to provide some help if you can show - I'm assuming the problem is with a web application - probably the jboss-web.xml and the corresponding web.xml.