Skip to main content

deployment trouble: jar in ear's /lib folder invisible to the ejbmodule

Please note these java.net forums are being decommissioned and use the new and improved forums at https://community.oracle.com/community/java.
12 replies [Last post]
brzhk
Offline
Joined: 2006-12-02

Hi,
I'm trying to deploy an ear on glassfish 3.1 and for some reason an error appeared:
when deploying, an EJB - the first one being deployed - fails to deploy with a Class not found error. Glassfish seems unable to fetch the classes in the jar contained in my ear lib folder.

Is my application.xml wrong? (edit: dont mind the tags, they're added by the java.net forum...)

my application.xml :

<br />
<?xml version="1.0" encoding="UTF-8"?><br />
<application xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee <a href="http://java.sun.com/xml/ns/javaee/application_6.xsd"" title="http://java.sun.com/xml/ns/javaee/application_6.xsd"">http://java.sun.com/xml/ns/javaee/application_6.xsd"</a> version="6"><br />
  <application-name>myapp</application-name><br />
  <display-name>packaging</display-name><br />
  <module><br />
    <java>lib/domain-2.0.3-SNAPSHOT.jar</java><br />
  </module><br />
  <module><br />
    <ejb>business-2.0.3-SNAPSHOT.jar</ejb><br />
  </module><br />
  <library-directory>lib</library-directory><br />
</application><br />

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
ss141213
Offline
Joined: 2005-03-30

Why have you specified lib/domain-2.0.3-SNAPSHOT.jar?
Module type java is used to indicate application client module. Remove
that and try.

Sahoo
On Thursday 26 May 2011 01:49 PM, forums@java.net wrote:
> Hi,
>
> I'm trying to deploy an ear on glassfish 3.1 and for some reason an error
> appeared:
>
> when deploying, an EJB - the first one being deployed - fails to
> deploy with
> a Class not found error. Glassfish seems unable to fetch the classes
> in the
> jar contained in my ear lib folder.
>
>
>
> Is my application.xml wrong?
>
>
> my application.xml :
>
> <?xml version="1.0" encoding="UTF-8"?> xmlns="http://java.sun.com/xml/ns/javaee"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
> http://java.sun.com/xml/ns/javaee/application_6.xsd" version="6">
> myapp
> packaging
> lib/domain-2.0.3-SNAPSHOT.jar
> business-2.0.3-SNAPSHOT.jar
> lib
>
>
> --
>
> [Message sent by forum member 'brzhk']
>
> View Post: http://forums.java.net/node/806322
>
>

Matthieu Bertin...
Offline
Joined: 2011-04-03

Hello Sahoo,

I've added the jarmodule trying to force glassfish to read it. but it didn't
work.
I'm getting the very same error with the following application.xml:

<?xml version="1.0" encoding="UTF-8"?>

myapp
myapp

business-2.0.3-SNAPSHOT.jar

lib

and of course i've doubled-checked that the domain.jar is in the ear lib
folder, and contains the "missing" class.

ss141213
Offline
Joined: 2005-03-30

Send exception stack trace and any relevant info like where is the class
packaged? Is it in two places? Are all its dependencies satisfied?

Sahoo
On Thursday 26 May 2011 02:56 PM, Matthieu Bertin wrote:
> Hello Sahoo,
>
> I've added the jarmodule trying to force glassfish to read it. but it
> didn't work.
> I'm getting the very same error with the following application.xml:
>
> <?xml version="1.0" encoding="UTF-8"?>
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
> http://java.sun.com/xml/ns/javaee/application_6.xsd" version="6">
> myapp
> myapp
>
> business-2.0.3-SNAPSHOT.jar
>
> lib
>
>
> and of course i've doubled-checked that the domain.jar is in the ear
> lib folder, and contains the "missing" class.

Matthieu Bertin...
Offline
Joined: 2011-04-03

EAR

ss141213
Offline
Joined: 2005-03-30

I don't see any classloading errors. It seems there is a wrong EJB name
used somewhere. Most likely it is in one of the sun-*.xml file.

Sahoo
On Thursday 26 May 2011 03:11 PM, Matthieu Bertin wrote:
> EAR
> +--------business.jar <---- containing EJB which fails to find a
> class from the domain.jar
> +--------/lib/
> | +---- domain.jar <---- contains the "missing" class
> +--------META-INF/
> +----- application.xml
>
> all the dependencies of the missing class can be resolved: most of it
> comes from javax.persistence and org.jasypt; the jasypt.jar is in the
> glassfish/lib folder.
>
> here is the server.log i get when deploying:
>
> [#|2011-05-26T10:56:19.181+0200|SEVERE|glassfish3.1|global|_ThreadID=23;_ThreadName=Thread-1;|Class
> [ Lcom/mycompany/myapp/domain/dao/MyClassThatCannotBeFound ; ] not
> found. Error while loading [ class
> com.mycompany.myapp.auth.MyEjbThatFailsToDeploy ]|#]
>
> [#|2011-05-26T10:56:19.188+0200|SEVERE|glassfish3.1|javax.enterprise.system.core.com.sun.enterprise.v3.server|_ThreadID=87;_ThreadName=Thread-1;|Exception
> lors du déploiement de l’application [myapp]|#]
>
> [#|2011-05-26T10:56:19.189+0200|SEVERE|glassfish3.1|javax.enterprise.system.core.com.sun.enterprise.v3.server|_ThreadID=87;_ThreadName=Thread-1;|Erreur
> de référencement : Cet ensemble ne comporte aucun bean nommé
> [MyEjbThatFailsToDeploy]
> java.lang.IllegalArgumentException: Erreur de référencement : Cet
> ensemble ne comporte aucun bean nommé [MyEjbThatFailsToDeploy]
> at
> com.sun.enterprise.deployment.EjbBundleDescriptor.getEjbByName(EjbBundleDescriptor.java:287)
> at
> com.sun.enterprise.deployment.EjbBundleDescriptor.getEjbByName(EjbBundleDescriptor.java:271)
> at
> com.sun.enterprise.deployment.node.runtime.EjbNode.setElementValue(EjbNode.java:125)
> at
> com.sun.enterprise.deployment.node.SaxParserHandler.endElement(SaxParserHandler.java:476)
> at
> com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:604)
> at
> com.sun.org.apache.xerces.internal.impl.dtd.XMLNSDTDValidator.endNamespaceScope(XMLNSDTDValidator.java:266)
> at
> com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.handleEndElement(XMLDTDValidator.java:2053)
> at
> com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.endElement(XMLDTDValidator.java:927)
> at
> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanEndElement(XMLDocumentFragmentScannerImpl.java:1759)
> at
> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2915)
> at
> com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:625)
> at
> com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:116)
> at
> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:488)
> at
> com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:819)
> at
> com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:748)
> at
> com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:123)
> at
> com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1208)
> at
> com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:525)
> at javax.xml.parsers.SAXParser.parse(SAXParser.java:392)
> at
> com.sun.enterprise.deployment.io.DeploymentDescriptorFile.read(DeploymentDescriptorFile.java:309)
> at
> com.sun.enterprise.deployment.archivist.Archivist.readRuntimeDeploymentDescriptor(Archivist.java:718)
> at
> com.sun.enterprise.deployment.archivist.Archivist.readRuntimeDeploymentDescriptor(Archivist.java:668)
> at
> com.sun.enterprise.deployment.archivist.ApplicationArchivist.readRuntimeDeploymentDescriptor(ApplicationArchivist.java:728)
> at
> com.sun.enterprise.deployment.archivist.ApplicationArchivist.openWith(ApplicationArchivist.java:265)
> at
> com.sun.enterprise.deployment.archivist.ApplicationFactory.openWith(ApplicationFactory.java:240)
> at
> org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:170)
> at
> org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:93)
> at
> com.sun.enterprise.v3.server.ApplicationLifecycle.loadDeployer(ApplicationLifecycle.java:826)
> at
> com.sun.enterprise.v3.server.ApplicationLifecycle.setupContainerInfos(ApplicationLifecycle.java:768)
> at
> com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:368)
> at
> com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:240)
> at
> org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:370)
> at
> com.sun.enterprise.v3.admin.CommandRunnerImpl$1.execute(CommandRunnerImpl.java:355)
> at
> com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:370)
> at
> com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1067)
> at
> com.sun.enterprise.v3.admin.CommandRunnerImpl.access$1200(CommandRunnerImpl.java:96)
> at
> com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1247)
> at
> com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1235)
> at
> com.sun.enterprise.v3.admin.AdminAdapter.doCommand(AdminAdapter.java:465)
> at com.sun.enterprise.v3.admin.AdminAdapter.service(AdminAdapter.java:222)
> at
> com.sun.grizzly.tcp.http11.GrizzlyAdapter.service(GrizzlyAdapter.java:168)
> at
> com.sun.enterprise.v3.server.HK2Dispatcher.dispath(HK2Dispatcher.java:117)
> at
> com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:234)
> at
> com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:822)
> at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:719)
> at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:1013)
> at
> com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:225)
> at
> com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:137)
> at
> com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:104)
> at
> com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:90)
> at
> com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:79)
> at
> com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:54)
> at
> com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:59)
> at com.sun.grizzly.ContextTask.run(ContextTask.java:71)
> at
> com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:532)
> at
> com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:513)
> at java.lang.Thread.run(Thread.java:679)
> |#]
>
> [#|2011-05-26T10:56:19.191+0200|SEVERE|glassfish3.1|javax.enterprise.system.tools.admin.org.glassfish.deployment.admin|_ThreadID=87;_ThreadName=Thread-1;|Exception
> lors du déploiement de l’application [myapp] : Erreur de référencement
> : Cet ensemble ne comporte aucun bean nommé [MyEjbThatFailsToDeploy]|#]
>
>
> On Thu, May 26, 2011 at 11:29 AM, Sahoo > wrote:
>
> Send exception stack trace and any relevant info like where is the
> class packaged? Is it in two places? Are all its dependencies
> satisfied?
>
> Sahoo
>
> On Thursday 26 May 2011 02:56 PM, Matthieu Bertin wrote:
>> Hello Sahoo,
>>
>> I've added the jarmodule trying to force glassfish to read it.
>> but it didn't work.
>> I'm getting the very same error with the following application.xml:
>>
>> <?xml version="1.0" encoding="UTF-8"?>
>> > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>> xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
>> http://java.sun.com/xml/ns/javaee/application_6.xsd" version="6">
>> myapp
>> myapp
>>
>> business-2.0.3-SNAPSHOT.jar
>>
>> lib
>>
>>
>> and of course i've doubled-checked that the domain.jar is in the
>> ear lib folder, and contains the "missing" class.
>
>

Matthieu Bertin...
Offline
Joined: 2011-04-03

is this line a false alarm ?

[#|2011-05-26T10:56:19.181+0200|SEVERE|glassfish3.1|global|_ThreadID=23;_ThreadName=Thread-1;|Class
[ Lcom/mycompany/myapp/domain/dao/MyClassThatCannotBeFound ; ] not found.
Error while loading [ class com.mycompany.myapp.auth.MyEjbThatFailsToDeploy
]|#]

I've tried some more. I got another EJB which deploys flawlessly. It is in
the same ejb jar. What is striking me is that it uses exactly the same
MyClassThatCannotBeFound,
in the same way. But it deploys, whereas the other does not.

I've removed the mention of MyEjbThatFailsToDeploy in my
glassfish-ejb-jar.xml, which nows is the following:
<?xml version="1.0" encoding="UTF-8"?>

shop
shop

central
central

CustomerAuthenticationEjb

CustomerAuthenticationEjb

CLIENT-CERT
certificate

CONFIDENTIAL

CustomerAccessManagementEjb

CustomerAccessManagementEjb

CLIENT-CERT certificate

CONFIDENTIAL

-->

and my glassfish-application.xml exists but it is empty.

And i still get the same error message:
[#|2011-05-26T10:56:19.181+0200|SEVERE|glassfish3.1|global|_ThreadID=23;_ThreadName=Thread-1;|Class
[ Lcom/mycompany/myapp/domain/dao/MyClassThatCannotBeFound ; ] not found.
Error while loading [ class com.mycompany.myapp.auth.MyEjbThatFailsToDeploy
]|#]

On Thu, May 26, 2011 at 12:05 PM, Sahoo wrote:

> I don't see any classloading errors. It seems there is a wrong EJB name
> used somewhere. Most likely it is in one of the sun-*.xml file.
>
> Sahoo
>
> On Thursday 26 May 2011 03:11 PM, Matthieu Bertin wrote:
>
> EAR
> +--------business.jar <---- containing EJB which fails to find a class
> from the domain.jar
> +--------/lib/
> | +---- domain.jar <---- contains the "missing" class
> +--------META-INF/
> +----- application.xml
>
> all the dependencies of the missing class can be resolved: most of it
> comes from javax.persistence and org.jasypt; the jasypt.jar is in the
> glassfish/lib folder.
>
> here is the server.log i get when deploying:
>
> [#|2011-05-26T10:56:19.181+0200|SEVERE|glassfish3.1|global|_ThreadID=23;_ThreadName=Thread-1;|Class
> [ Lcom/mycompany/myapp/domain/dao/MyClassThatCannotBeFound ; ] not found.
> Error while loading [ class com.mycompany.myapp.auth.MyEjbThatFailsToDeploy
> ]|#]
>
> [#|2011-05-26T10:56:19.188+0200|SEVERE|glassfish3.1|javax.enterprise.system.core.com.sun.enterprise.v3.server|_ThreadID=87;_ThreadName=Thread-1;|Exception
> lors du déploiement de l’application [myapp]|#]
>
> [#|2011-05-26T10:56:19.189+0200|SEVERE|glassfish3.1|javax.enterprise.system.core.com.sun.enterprise.v3.server|_ThreadID=87;_ThreadName=Thread-1;|Erreur
> de référencement : Cet ensemble ne comporte aucun bean nommé
> [MyEjbThatFailsToDeploy]
> java.lang.IllegalArgumentException: Erreur de référencement : Cet ensemble
> ne comporte aucun bean nommé [MyEjbThatFailsToDeploy]
> at
> com.sun.enterprise.deployment.EjbBundleDescriptor.getEjbByName(EjbBundleDescriptor.java:287)
> at
> com.sun.enterprise.deployment.EjbBundleDescriptor.getEjbByName(EjbBundleDescriptor.java:271)
> at
> com.sun.enterprise.deployment.node.runtime.EjbNode.setElementValue(EjbNode.java:125)
> at
> com.sun.enterprise.deployment.node.SaxParserHandler.endElement(SaxParserHandler.java:476)
> at
> com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:604)
> at
> com.sun.org.apache.xerces.internal.impl.dtd.XMLNSDTDValidator.endNamespaceScope(XMLNSDTDValidator.java:266)
> at
> com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.handleEndElement(XMLDTDValidator.java:2053)
> at
> com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.endElement(XMLDTDValidator.java:927)
> at
> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanEndElement(XMLDocumentFragmentScannerImpl.java:1759)
> at
> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2915)
> at
> com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:625)
> at
> com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:116)
> at
> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:488)
> at
> com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:819)
> at
> com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:748)
> at
> com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:123)
> at
> com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1208)
> at
> com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:525)
> at javax.xml.parsers.SAXParser.parse(SAXParser.java:392)
> at
> com.sun.enterprise.deployment.io.DeploymentDescriptorFile.read(DeploymentDescriptorFile.java:309)
> at
> com.sun.enterprise.deployment.archivist.Archivist.readRuntimeDeploymentDescriptor(Archivist.java:718)
> at
> com.sun.enterprise.deployment.archivist.Archivist.readRuntimeDeploymentDescriptor(Archivist.java:668)
> at
> com.sun.enterprise.deployment.archivist.ApplicationArchivist.readRuntimeDeploymentDescriptor(ApplicationArchivist.java:728)
> at
> com.sun.enterprise.deployment.archivist.ApplicationArchivist.openWith(ApplicationArchivist.java:265)
> at
> com.sun.enterprise.deployment.archivist.ApplicationFactory.openWith(ApplicationFactory.java:240)
> at
> org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:170)
> at
> org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:93)
> at
> com.sun.enterprise.v3.server.ApplicationLifecycle.loadDeployer(ApplicationLifecycle.java:826)
> at
> com.sun.enterprise.v3.server.ApplicationLifecycle.setupContainerInfos(ApplicationLifecycle.java:768)
> at
> com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:368)
> at
> com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:240)
> at
> org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:370)
> at
> com.sun.enterprise.v3.admin.CommandRunnerImpl$1.execute(CommandRunnerImpl.java:355)
> at
> com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:370)
> at
> com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1067)
> at
> com.sun.enterprise.v3.admin.CommandRunnerImpl.access$1200(CommandRunnerImpl.java:96)
> at
> com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1247)
> at
> com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1235)
> at
> com.sun.enterprise.v3.admin.AdminAdapter.doCommand(AdminAdapter.java:465)
> at
> com.sun.enterprise.v3.admin.AdminAdapter.service(AdminAdapter.java:222)
> at
> com.sun.grizzly.tcp.http11.GrizzlyAdapter.service(GrizzlyAdapter.java:168)
> at
> com.sun.enterprise.v3.server.HK2Dispatcher.dispath(HK2Dispatcher.java:117)
> at
> com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:234)
> at
> com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:822)
> at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:719)
> at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:1013)
> at
> com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:225)
> at
> com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:137)
> at
> com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:104)
> at
> com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:90)
> at
> com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:79)
> at
> com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:54)
> at
> com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:59)
> at com.sun.grizzly.ContextTask.run(ContextTask.java:71)
> at
> com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:532)
> at
> com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:513)
> at java.lang.Thread.run(Thread.java:679)
> |#]
>
> [#|2011-05-26T10:56:19.191+0200|SEVERE|glassfish3.1|javax.enterprise.system.tools.admin.org.glassfish.deployment.admin|_ThreadID=87;_ThreadName=Thread-1;|Exception
> lors du déploiement de l’application [myapp] : Erreur de référencement : Cet
> ensemble ne comporte aucun bean nommé [MyEjbThatFailsToDeploy]|#]
>
>
> On Thu, May 26, 2011 at 11:29 AM, Sahoo wrote:
>
>> Send exception stack trace and any relevant info like where is the class
>> packaged? Is it in two places? Are all its dependencies satisfied?
>>
>> Sahoo
>>
>> On Thursday 26 May 2011 02:56 PM, Matthieu Bertin wrote:
>>
>> Hello Sahoo,
>>
>> I've added the jarmodule trying to force glassfish to read it. but it
>> didn't work.
>> I'm getting the very same error with the following application.xml:
>>
>> <?xml version="1.0" encoding="UTF-8"?>
>> > http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="
>> http://java.sun.com/xml/ns/javaee
>> http://java.sun.com/xml/ns/javaee/application_6.xsd" version="6">
>> myapp
>> myapp
>>
>> business-2.0.3-SNAPSHOT.jar
>>
>> lib
>>
>>
>> and of course i've doubled-checked that the domain.jar is in the ear lib
>> folder, and contains the "missing" class.
>>
>>
>>
>
>

ss141213
Offline
Joined: 2005-03-30

No, it's not. I overlooked that log message completely - sorry about
that. Some kind of class loading wrt arraytypes as I see from the
message below:

Lcom/mycompany/myapp/domain/dao/MyClassThatCannotBeFound ; ] not found.
Error while loading [ class
com.mycompany.myapp.auth.MyEjbThatFailsToDeploy ]|#]

How does com.mycompany.myapp.auth.MyEjbThatFailsToDeploy use
com.mycompany.myapp.domain.dao.MyClassThatCannotBeFound ? Where are
these classes packaged in the ear?

Thanks,
Sahoo

On Thursday 26 May 2011 07:53 PM, Matthieu Bertin wrote:
> is this line a false alarm ?
>
> [#|2011-05-26T10:56:19.181+0200|SEVERE|glassfish3.1|global|_ThreadID=23;_ThreadName=Thread-1;|Class
> [ Lcom/mycompany/myapp/domain/dao/MyClassThatCannotBeFound ; ] not
> found. Error while loading [ class
> com.mycompany.myapp.auth.MyEjbThatFailsToDeploy ]|#]
>
> I've tried some more. I got another EJB which deploys flawlessly. It
> is in the same ejb jar. What is striking me is that it uses exactly
> the same MyClassThatCannotBeFound, in the same way. But it deploys,
> whereas the other does not.
>
> I've removed the mention of MyEjbThatFailsToDeploy in my
> glassfish-ejb-jar.xml, which nows is the following:
> <?xml version="1.0" encoding="UTF-8"?>
> Application Server 3.1 EJB 3.1//EN"
> "http://glassfish.org/dtds/glassfish-ejb-jar_3_1-1.dtd">
>
>
>
> shop
> shop
>
>
>
> central
> central
>
>
>
>
> CustomerAuthenticationEjb
>
> CustomerAuthenticationEjb
>
> CLIENT-CERT
> certificate
>
> CONFIDENTIAL
>
> CustomerAccessManagementEjb
>
> CustomerAccessManagementEjb
>
> CLIENT-CERT certificate
>
> CONFIDENTIAL
>
> -->
>
>
>
>
>
>
> and my glassfish-application.xml exists but it is empty.
>
> And i still get the same error message:
> [#|2011-05-26T10:56:19.181+0200|SEVERE|glassfish3.1|global|_ThreadID=23;_ThreadName=Thread-1;|Class
> [ Lcom/mycompany/myapp/domain/dao/MyClassThatCannotBeFound ; ] not
> found. Error while loading [ class
> com.mycompany.myapp.auth.MyEjbThatFailsToDeploy ]|#]
>
> On Thu, May 26, 2011 at 12:05 PM, Sahoo > wrote:
>
> I don't see any classloading errors. It seems there is a wrong EJB
> name used somewhere. Most likely it is in one of the sun-*.xml file.
>
> Sahoo
>
> On Thursday 26 May 2011 03:11 PM, Matthieu Bertin wrote:
>> EAR
>> +--------business.jar <---- containing EJB which fails to find
>> a class from the domain.jar
>> +--------/lib/
>> | +---- domain.jar <---- contains the "missing" class
>> +--------META-INF/
>> +----- application.xml
>>
>> all the dependencies of the missing class can be resolved: most
>> of it comes from javax.persistence and org.jasypt; the jasypt.jar
>> is in the glassfish/lib folder.
>>
>> here is the server.log i get when deploying:
>>
>> [#|2011-05-26T10:56:19.181+0200|SEVERE|glassfish3.1|global|_ThreadID=23;_ThreadName=Thread-1;|Class
>> [ Lcom/mycompany/myapp/domain/dao/MyClassThatCannotBeFound ; ]
>> not found. Error while loading [ class
>> com.mycompany.myapp.auth.MyEjbThatFailsToDeploy ]|#]
>>
>> [#|2011-05-26T10:56:19.188+0200|SEVERE|glassfish3.1|javax.enterprise.system.core.com.sun.enterprise.v3.server|_ThreadID=87;_ThreadName=Thread-1;|Exception
>> lors du déploiement de l’application [myapp]|#]
>>
>> [#|2011-05-26T10:56:19.189+0200|SEVERE|glassfish3.1|javax.enterprise.system.core.com.sun.enterprise.v3.server|_ThreadID=87;_ThreadName=Thread-1;|Erreur
>> de référencement : Cet ensemble ne comporte aucun bean nommé
>> [MyEjbThatFailsToDeploy]
>> java.lang.IllegalArgumentException: Erreur de référencement : Cet
>> ensemble ne comporte aucun bean nommé [MyEjbThatFailsToDeploy]
>> at
>> com.sun.enterprise.deployment.EjbBundleDescriptor.getEjbByName(EjbBundleDescriptor.java:287)
>> at
>> com.sun.enterprise.deployment.EjbBundleDescriptor.getEjbByName(EjbBundleDescriptor.java:271)
>> at
>> com.sun.enterprise.deployment.node.runtime.EjbNode.setElementValue(EjbNode.java:125)
>> at
>> com.sun.enterprise.deployment.node.SaxParserHandler.endElement(SaxParserHandler.java:476)
>> at
>> com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:604)
>> at
>> com.sun.org.apache.xerces.internal.impl.dtd.XMLNSDTDValidator.endNamespaceScope(XMLNSDTDValidator.java:266)
>> at
>> com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.handleEndElement(XMLDTDValidator.java:2053)
>> at
>> com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.endElement(XMLDTDValidator.java:927)
>> at
>> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanEndElement(XMLDocumentFragmentScannerImpl.java:1759)
>> at
>> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2915)
>> at
>> com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:625)
>> at
>> com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:116)
>> at
>> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:488)
>> at
>> com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:819)
>> at
>> com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:748)
>> at
>> com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:123)
>> at
>> com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1208)
>> at
>> com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:525)
>> at javax.xml.parsers.SAXParser.parse(SAXParser.java:392)
>> at
>> com.sun.enterprise.deployment.io.DeploymentDescriptorFile.read(DeploymentDescriptorFile.java:309)
>> at
>> com.sun.enterprise.deployment.archivist.Archivist.readRuntimeDeploymentDescriptor(Archivist.java:718)
>> at
>> com.sun.enterprise.deployment.archivist.Archivist.readRuntimeDeploymentDescriptor(Archivist.java:668)
>> at
>> com.sun.enterprise.deployment.archivist.ApplicationArchivist.readRuntimeDeploymentDescriptor(ApplicationArchivist.java:728)
>> at
>> com.sun.enterprise.deployment.archivist.ApplicationArchivist.openWith(ApplicationArchivist.java:265)
>> at
>> com.sun.enterprise.deployment.archivist.ApplicationFactory.openWith(ApplicationFactory.java:240)
>> at
>> org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:170)
>> at
>> org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:93)
>> at
>> com.sun.enterprise.v3.server.ApplicationLifecycle.loadDeployer(ApplicationLifecycle.java:826)
>> at
>> com.sun.enterprise.v3.server.ApplicationLifecycle.setupContainerInfos(ApplicationLifecycle.java:768)
>> at
>> com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:368)
>> at
>> com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:240)
>> at
>> org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:370)
>> at
>> com.sun.enterprise.v3.admin.CommandRunnerImpl$1.execute(CommandRunnerImpl.java:355)
>> at
>> com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:370)
>> at
>> com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1067)
>> at
>> com.sun.enterprise.v3.admin.CommandRunnerImpl.access$1200(CommandRunnerImpl.java:96)
>> at
>> com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1247)
>> at
>> com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1235)
>> at
>> com.sun.enterprise.v3.admin.AdminAdapter.doCommand(AdminAdapter.java:465)
>> at
>> com.sun.enterprise.v3.admin.AdminAdapter.service(AdminAdapter.java:222)
>> at
>> com.sun.grizzly.tcp.http11.GrizzlyAdapter.service(GrizzlyAdapter.java:168)
>> at
>> com.sun.enterprise.v3.server.HK2Dispatcher.dispath(HK2Dispatcher.java:117)
>> at
>> com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:234)
>> at
>> com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:822)
>> at
>> com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:719)
>> at
>> com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:1013)
>> at
>> com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:225)
>> at
>> com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:137)
>> at
>> com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:104)
>> at
>> com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:90)
>> at
>> com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:79)
>> at
>> com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:54)
>> at
>> com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:59)
>> at com.sun.grizzly.ContextTask.run(ContextTask.java:71)
>> at
>> com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:532)
>> at
>> com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:513)
>> at java.lang.Thread.run(Thread.java:679)
>> |#]
>>
>> [#|2011-05-26T10:56:19.191+0200|SEVERE|glassfish3.1|javax.enterprise.system.tools.admin.org.glassfish.deployment.admin|_ThreadID=87;_ThreadName=Thread-1;|Exception
>> lors du déploiement de l’application [myapp] : Erreur de
>> référencement : Cet ensemble ne comporte aucun bean nommé
>> [MyEjbThatFailsToDeploy]|#]
>>
>>
>> On Thu, May 26, 2011 at 11:29 AM, Sahoo > > wrote:
>>
>> Send exception stack trace and any relevant info like where
>> is the class packaged? Is it in two places? Are all its
>> dependencies satisfied?
>>
>> Sahoo
>>
>> On Thursday 26 May 2011 02:56 PM, Matthieu Bertin wrote:
>>> Hello Sahoo,
>>>
>>> I've added the jarmodule trying to force glassfish to read
>>> it. but it didn't work.
>>> I'm getting the very same error with the following
>>> application.xml:
>>>
>>> <?xml version="1.0" encoding="UTF-8"?>
>>> >> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>>> xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
>>> http://java.sun.com/xml/ns/javaee/application_6.xsd"
>>> version="6">
>>> myapp
>>> myapp
>>>
>>> business-2.0.3-SNAPSHOT.jar
>>>
>>> lib
>>>
>>>
>>> and of course i've doubled-checked that the domain.jar is in
>>> the ear lib folder, and contains the "missing" class.
>>
>>
>
>

Matthieu Bertin...
Offline
Joined: 2011-04-03

EAR

ss141213
Offline
Joined: 2005-03-30

That does not provide much clue. Given the exception, I do feel some
where there is an MyClassThatCannotBeFound[]

and it is being attempted to be loaded using ClassLoader.loadClass() as
opposed to Class.forName(). ClassLoader.loadClass() can't be used to
load array types. So, I think you can try adding a conditional
breakpoint in ClassLoader.loadClass with your matching class name or use
something like BTrace to trace the class loading attempt. Or, if you
have a reproducible test case, file a bug against deployment.

Sahoo

On Friday 27 May 2011 01:35 PM, Matthieu Bertin wrote:
> EAR
> +--------business.jar <---- containing MyEjbThatFailsToDeploy
> +--------/lib/
> | +---- domain.jar <---- contains MyClassThatCannotBeFound
> +--------META-INF/
> +----- application.xml
>
> MyEjbThatFailsToDeploy uses MyClassThatCannotBeFound as a private
> field. maybe the use of a @resource is a problem.
> here's a snippet :
>
> import com.mycompany.domain. MyClassThatCannotBeFound;
>
>
> @Stateless
> @WebService(endpointInterface = "com. mycompany.business.I
> MyEjbThatFailsToDeploy", targetNamespace =
> "http://myapp.mycompany.com/ns/ MyEjbThatFailsToDeploy")
> public class MyEjbThatFailsToDeploy implements
> IMyEjbThatFailsToDeployLocal, IMyEjbThatFailsToDeploy {
>
> private MyClassThatCannotBeFound dao;
>
> @PersistenceContext
> private EntityManager em;
>
> public MyEjbThatFailsToDeploy() {
> this. dao = new MyClassThatCannotBeFound(em);
> }
>
> (...)
> On Thu, May 26, 2011 at 5:47 PM, Sahoo > wrote:
>
> No, it's not. I overlooked that log message completely - sorry
> about that. Some kind of class loading wrt arraytypes as I see
> from the message below:
>
>
> Lcom/mycompany/myapp/domain/dao/MyClassThatCannotBeFound ; ] not
> found. Error while loading [ class
> com.mycompany.myapp.auth.MyEjbThatFailsToDeploy ]|#]
>
> How does com.mycompany.myapp.auth.MyEjbThatFailsToDeploy use
> com.mycompany.myapp.domain.dao.MyClassThatCannotBeFound ? Where
> are these classes packaged in the ear?
>
> Thanks,
> Sahoo
>
>
> On Thursday 26 May 2011 07:53 PM, Matthieu Bertin wrote:
>> is this line a false alarm ?
>>
>> [#|2011-05-26T10:56:19.181+0200|SEVERE|glassfish3.1|global|_ThreadID=23;_ThreadName=Thread-1;|Class
>> [ Lcom/mycompany/myapp/domain/dao/MyClassThatCannotBeFound ; ]
>> not found. Error while loading [ class
>> com.mycompany.myapp.auth.MyEjbThatFailsToDeploy ]|#]
>>
>> I've tried some more. I got another EJB which deploys flawlessly.
>> It is in the same ejb jar. What is striking me is that it uses
>> exactly the same MyClassThatCannotBeFound, in the same way. But
>> it deploys, whereas the other does not.
>>
>> I've removed the mention of MyEjbThatFailsToDeploy in my
>> glassfish-ejb-jar.xml, which nows is the following:
>> <?xml version="1.0" encoding="UTF-8"?>
>> > GlassFish Application Server 3.1 EJB 3.1//EN"
>> "http://glassfish.org/dtds/glassfish-ejb-jar_3_1-1.dtd">
>>
>>
>>
>> shop
>> shop
>>
>>
>>
>> central
>> central
>>
>>
>>
>>
>> CustomerAuthenticationEjb
>>
>> CustomerAuthenticationEjb
>>
>> CLIENT-CERT
>> certificate
>>
>> CONFIDENTIAL
>>
>> CustomerAccessManagementEjb
>>
>> CustomerAccessManagementEjb
>>
>> CLIENT-CERT certificate
>>
>> CONFIDENTIAL
>>
>> -->
>>
>>
>>
>>
>>
>>
>> and my glassfish-application.xml exists but it is empty.
>>
>> And i still get the same error message:
>> [#|2011-05-26T10:56:19.181+0200|SEVERE|glassfish3.1|global|_ThreadID=23;_ThreadName=Thread-1;|Class
>> [ Lcom/mycompany/myapp/domain/dao/MyClassThatCannotBeFound ; ]
>> not found. Error while loading [ class
>> com.mycompany.myapp.auth.MyEjbThatFailsToDeploy ]|#]
>>
>> On Thu, May 26, 2011 at 12:05 PM, Sahoo > > wrote:
>>
>> I don't see any classloading errors. It seems there is a
>> wrong EJB name used somewhere. Most likely it is in one of
>> the sun-*.xml file.
>>
>> Sahoo
>>
>> On Thursday 26 May 2011 03:11 PM, Matthieu Bertin wrote:
>>> EAR
>>> +--------business.jar <---- containing EJB which fails to
>>> find a class from the domain.jar
>>> +--------/lib/
>>> | +---- domain.jar <---- contains the "missing" class
>>> +--------META-INF/
>>> +----- application.xml
>>>
>>> all the dependencies of the missing class can be resolved:
>>> most of it comes from javax.persistence and org.jasypt; the
>>> jasypt.jar is in the glassfish/lib folder.
>>>
>>> here is the server.log i get when deploying:
>>>
>>> [#|2011-05-26T10:56:19.181+0200|SEVERE|glassfish3.1|global|_ThreadID=23;_ThreadName=Thread-1;|Class
>>> [ Lcom/mycompany/myapp/domain/dao/MyClassThatCannotBeFound ;
>>> ] not found. Error while loading [ class
>>> com.mycompany.myapp.auth.MyEjbThatFailsToDeploy ]|#]
>>>
>>> [#|2011-05-26T10:56:19.188+0200|SEVERE|glassfish3.1|javax.enterprise.system.core.com.sun.enterprise.v3.server|_ThreadID=87;_ThreadName=Thread-1;|Exception
>>> lors du déploiement de l’application [myapp]|#]
>>>
>>> [#|2011-05-26T10:56:19.189+0200|SEVERE|glassfish3.1|javax.enterprise.system.core.com.sun.enterprise.v3.server|_ThreadID=87;_ThreadName=Thread-1;|Erreur
>>> de référencement : Cet ensemble ne comporte aucun bean nommé
>>> [MyEjbThatFailsToDeploy]
>>> java.lang.IllegalArgumentException: Erreur de référencement
>>> : Cet ensemble ne comporte aucun bean nommé
>>> [MyEjbThatFailsToDeploy]
>>> at
>>> com.sun.enterprise.deployment.EjbBundleDescriptor.getEjbByName(EjbBundleDescriptor.java:287)
>>> at
>>> com.sun.enterprise.deployment.EjbBundleDescriptor.getEjbByName(EjbBundleDescriptor.java:271)
>>> at
>>> com.sun.enterprise.deployment.node.runtime.EjbNode.setElementValue(EjbNode.java:125)
>>> at
>>> com.sun.enterprise.deployment.node.SaxParserHandler.endElement(SaxParserHandler.java:476)
>>> at
>>> com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:604)
>>> at
>>> com.sun.org.apache.xerces.internal.impl.dtd.XMLNSDTDValidator.endNamespaceScope(XMLNSDTDValidator.java:266)
>>> at
>>> com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.handleEndElement(XMLDTDValidator.java:2053)
>>> at
>>> com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.endElement(XMLDTDValidator.java:927)
>>> at
>>> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanEndElement(XMLDocumentFragmentScannerImpl.java:1759)
>>> at
>>> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2915)
>>> at
>>> com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:625)
>>> at
>>> com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:116)
>>> at
>>> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:488)
>>> at
>>> com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:819)
>>> at
>>> com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:748)
>>> at
>>> com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:123)
>>> at
>>> com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1208)
>>> at
>>> com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:525)
>>> at javax.xml.parsers.SAXParser.parse(SAXParser.java:392)
>>> at
>>> com.sun.enterprise.deployment.io.DeploymentDescriptorFile.read(DeploymentDescriptorFile.java:309)
>>> at
>>> com.sun.enterprise.deployment.archivist.Archivist.readRuntimeDeploymentDescriptor(Archivist.java:718)
>>> at
>>> com.sun.enterprise.deployment.archivist.Archivist.readRuntimeDeploymentDescriptor(Archivist.java:668)
>>> at
>>> com.sun.enterprise.deployment.archivist.ApplicationArchivist.readRuntimeDeploymentDescriptor(ApplicationArchivist.java:728)
>>> at
>>> com.sun.enterprise.deployment.archivist.ApplicationArchivist.openWith(ApplicationArchivist.java:265)
>>> at
>>> com.sun.enterprise.deployment.archivist.ApplicationFactory.openWith(ApplicationFactory.java:240)
>>> at
>>> org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:170)
>>> at
>>> org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:93)
>>> at
>>> com.sun.enterprise.v3.server.ApplicationLifecycle.loadDeployer(ApplicationLifecycle.java:826)
>>> at
>>> com.sun.enterprise.v3.server.ApplicationLifecycle.setupContainerInfos(ApplicationLifecycle.java:768)
>>> at
>>> com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:368)
>>> at
>>> com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:240)
>>> at
>>> org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:370)
>>> at
>>> com.sun.enterprise.v3.admin.CommandRunnerImpl$1.execute(CommandRunnerImpl.java:355)
>>> at
>>> com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:370)
>>> at
>>> com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1067)
>>> at
>>> com.sun.enterprise.v3.admin.CommandRunnerImpl.access$1200(CommandRunnerImpl.java:96)
>>> at
>>> com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1247)
>>> at
>>> com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1235)
>>> at
>>> com.sun.enterprise.v3.admin.AdminAdapter.doCommand(AdminAdapter.java:465)
>>> at
>>> com.sun.enterprise.v3.admin.AdminAdapter.service(AdminAdapter.java:222)
>>> at
>>> com.sun.grizzly.tcp.http11.GrizzlyAdapter.service(GrizzlyAdapter.java:168)
>>> at
>>> com.sun.enterprise.v3.server.HK2Dispatcher.dispath(HK2Dispatcher.java:117)
>>> at
>>> com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:234)
>>> at
>>> com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:822)
>>> at
>>> com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:719)
>>> at
>>> com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:1013)
>>> at
>>> com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:225)
>>> at
>>> com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:137)
>>> at
>>> com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:104)
>>> at
>>> com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:90)
>>> at
>>> com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:79)
>>> at
>>> com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:54)
>>> at
>>> com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:59)
>>> at com.sun.grizzly.ContextTask.run(ContextTask.java:71)
>>> at
>>> com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:532)
>>> at
>>> com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:513)
>>> at java.lang.Thread.run(Thread.java:679)
>>> |#]
>>>
>>> [#|2011-05-26T10:56:19.191+0200|SEVERE|glassfish3.1|javax.enterprise.system.tools.admin.org.glassfish.deployment.admin|_ThreadID=87;_ThreadName=Thread-1;|Exception
>>> lors du déploiement de l’application [myapp] : Erreur de
>>> référencement : Cet ensemble ne comporte aucun bean nommé
>>> [MyEjbThatFailsToDeploy]|#]
>>>
>>>
>>> On Thu, May 26, 2011 at 11:29 AM, Sahoo
>>> >
>>> wrote:
>>>
>>> Send exception stack trace and any relevant info like
>>> where is the class packaged? Is it in two places? Are
>>> all its dependencies satisfied?
>>>
>>> Sahoo
>>>
>>> On Thursday 26 May 2011 02:56 PM, Matthieu Bertin wrote:
>>>> Hello Sahoo,
>>>>
>>>> I've added the jarmodule trying to force glassfish to
>>>> read it. but it didn't work.
>>>> I'm getting the very same error with the following
>>>> application.xml:
>>>>
>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>> >>> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>>>> xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
>>>> http://java.sun.com/xml/ns/javaee/application_6.xsd"
>>>> version="6">
>>>> myapp
>>>> myapp
>>>>
>>>> business-2.0.3-SNAPSHOT.jar
>>>>
>>>> lib
>>>>
>>>>
>>>> and of course i've doubled-checked that the domain.jar
>>>> is in the ear lib folder, and contains the "missing" class.
>>>
>>>
>>
>>
>
>

Matthieu Bertin...
Offline
Joined: 2011-04-03

OK. I've tried installing the app on another server: worked as expected.
Something obviously was wrong with my installation.

I've reinstalled everything and it works wonders...

On Fri, May 27, 2011 at 10:22 AM, Sahoo wrote:

> That does not provide much clue. Given the exception, I do feel some where
> there is an MyClassThatCannotBeFound[]
>
>
> and it is being attempted to be loaded using ClassLoader.loadClass() as
> opposed to Class.forName(). ClassLoader.loadClass() can't be used to load
> array types. So, I think you can try adding a conditional breakpoint in
> ClassLoader.loadClass with your matching class name or use something like
> BTrace to trace the class loading attempt. Or, if you have a reproducible
> test case, file a bug against deployment.
>
> Sahoo
>
>
> On Friday 27 May 2011 01:35 PM, Matthieu Bertin wrote:
>
> EAR
> +--------business.jar <---- containing MyEjbThatFailsToDeploy
> +--------/lib/
> | +---- domain.jar <---- contains MyClassThatCannotBeFound
> +--------META-INF/
> +----- application.xml
>
> MyEjbThatFailsToDeploy uses MyClassThatCannotBeFound as a private field.
> maybe the use of a @resource is a problem.
> here's a snippet :
>
> import com.mycompany.domain. MyClassThatCannotBeFound;
>
>
> @Stateless
> @WebService(endpointInterface = "com. mycompany.business.I
> MyEjbThatFailsToDeploy", targetNamespace = "http://myapp.mycompany.com/ns/
> MyEjbThatFailsToDeploy")
> public class MyEjbThatFailsToDeploy implements IMyEjbThatFailsToDeployLocal,
> IMyEjbThatFailsToDeploy {
>
> private MyClassThatCannotBeFound dao;
>
> @PersistenceContext
> private EntityManager em;
>
> public MyEjbThatFailsToDeploy() {
> this. dao = new MyClassThatCannotBeFound(em);
> }
>
> (...)
> On Thu, May 26, 2011 at 5:47 PM, Sahoo wrote:
>
>> No, it's not. I overlooked that log message completely - sorry about
>> that. Some kind of class loading wrt arraytypes as I see from the message
>> below:
>>
>>
>> Lcom/mycompany/myapp/domain/dao/MyClassThatCannotBeFound ; ] not found.
>> Error while loading [ class com.mycompany.myapp.auth.MyEjbThatFailsToDeploy
>> ]|#]
>>
>> How does com.mycompany.myapp.auth.MyEjbThatFailsToDeploy use com.mycompany.myapp.domain.dao.MyClassThatCannotBeFound
>> ? Where are these classes packaged in the ear?
>>
>> Thanks,
>> Sahoo
>>
>>
>> On Thursday 26 May 2011 07:53 PM, Matthieu Bertin wrote:
>>
>> is this line a false alarm ?
>>
>> [#|2011-05-26T10:56:19.181+0200|SEVERE|glassfish3.1|global|_ThreadID=23;_ThreadName=Thread-1;|Class
>> [ Lcom/mycompany/myapp/domain/dao/MyClassThatCannotBeFound ; ] not found.
>> Error while loading [ class com.mycompany.myapp.auth.MyEjbThatFailsToDeploy
>> ]|#]
>>
>> I've tried some more. I got another EJB which deploys flawlessly. It is
>> in the same ejb jar. What is striking me is that it uses exactly the same MyClassThatCannotBeFound,
>> in the same way. But it deploys, whereas the other does not.
>>
>> I've removed the mention of MyEjbThatFailsToDeploy in my
>> glassfish-ejb-jar.xml, which nows is the following:
>> <?xml version="1.0" encoding="UTF-8"?>
>> > Application Server 3.1 EJB 3.1//EN" "
>> http://glassfish.org/dtds/glassfish-ejb-jar_3_1-1.dtd">
>>
>>
>>
>> shop
>> shop
>>
>>
>>
>> central
>> central
>>
>>
>>
>>
>> CustomerAuthenticationEjb
>>
>> CustomerAuthenticationEjb
>>
>> CLIENT-CERT
>> certificate
>>
>> CONFIDENTIAL
>>
>> CustomerAccessManagementEjb
>>
>> CustomerAccessManagementEjb
>>
>> CLIENT-CERT certificate
>>
>> CONFIDENTIAL
>>
>> -->
>>
>>
>>
>>
>>
>>
>> and my glassfish-application.xml exists but it is empty.
>>
>> And i still get the same error message:
>> [#|2011-05-26T10:56:19.181+0200|SEVERE|glassfish3.1|global|_ThreadID=23;_ThreadName=Thread-1;|Class
>> [ Lcom/mycompany/myapp/domain/dao/MyClassThatCannotBeFound ; ] not found.
>> Error while loading [ class com.mycompany.myapp.auth.MyEjbThatFailsToDeploy
>> ]|#]
>>
>> On Thu, May 26, 2011 at 12:05 PM, Sahoo wrote:
>>
>>> I don't see any classloading errors. It seems there is a wrong EJB name
>>> used somewhere. Most likely it is in one of the sun-*.xml file.
>>>
>>> Sahoo
>>>
>>> On Thursday 26 May 2011 03:11 PM, Matthieu Bertin wrote:
>>>
>>> EAR
>>> +--------business.jar <---- containing EJB which fails to find a class
>>> from the domain.jar
>>> +--------/lib/
>>> | +---- domain.jar <---- contains the "missing" class
>>> +--------META-INF/
>>> +----- application.xml
>>>
>>> all the dependencies of the missing class can be resolved: most of it
>>> comes from javax.persistence and org.jasypt; the jasypt.jar is in the
>>> glassfish/lib folder.
>>>
>>> here is the server.log i get when deploying:
>>>
>>> [#|2011-05-26T10:56:19.181+0200|SEVERE|glassfish3.1|global|_ThreadID=23;_ThreadName=Thread-1;|Class
>>> [ Lcom/mycompany/myapp/domain/dao/MyClassThatCannotBeFound ; ] not found.
>>> Error while loading [ class com.mycompany.myapp.auth.MyEjbThatFailsToDeploy
>>> ]|#]
>>>
>>> [#|2011-05-26T10:56:19.188+0200|SEVERE|glassfish3.1|javax.enterprise.system.core.com.sun.enterprise.v3.server|_ThreadID=87;_ThreadName=Thread-1;|Exception
>>> lors du déploiement de l’application [myapp]|#]
>>>
>>> [#|2011-05-26T10:56:19.189+0200|SEVERE|glassfish3.1|javax.enterprise.system.core.com.sun.enterprise.v3.server|_ThreadID=87;_ThreadName=Thread-1;|Erreur
>>> de référencement : Cet ensemble ne comporte aucun bean nommé
>>> [MyEjbThatFailsToDeploy]
>>> java.lang.IllegalArgumentException: Erreur de référencement : Cet
>>> ensemble ne comporte aucun bean nommé [MyEjbThatFailsToDeploy]
>>> at
>>> com.sun.enterprise.deployment.EjbBundleDescriptor.getEjbByName(EjbBundleDescriptor.java:287)
>>> at
>>> com.sun.enterprise.deployment.EjbBundleDescriptor.getEjbByName(EjbBundleDescriptor.java:271)
>>> at
>>> com.sun.enterprise.deployment.node.runtime.EjbNode.setElementValue(EjbNode.java:125)
>>> at
>>> com.sun.enterprise.deployment.node.SaxParserHandler.endElement(SaxParserHandler.java:476)
>>> at
>>> com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:604)
>>> at
>>> com.sun.org.apache.xerces.internal.impl.dtd.XMLNSDTDValidator.endNamespaceScope(XMLNSDTDValidator.java:266)
>>> at
>>> com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.handleEndElement(XMLDTDValidator.java:2053)
>>> at
>>> com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.endElement(XMLDTDValidator.java:927)
>>> at
>>> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanEndElement(XMLDocumentFragmentScannerImpl.java:1759)
>>> at
>>> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2915)
>>> at
>>> com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:625)
>>> at
>>> com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:116)
>>> at
>>> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:488)
>>> at
>>> com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:819)
>>> at
>>> com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:748)
>>> at
>>> com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:123)
>>> at
>>> com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1208)
>>> at
>>> com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:525)
>>> at javax.xml.parsers.SAXParser.parse(SAXParser.java:392)
>>> at
>>> com.sun.enterprise.deployment.io.DeploymentDescriptorFile.read(DeploymentDescriptorFile.java:309)
>>> at
>>> com.sun.enterprise.deployment.archivist.Archivist.readRuntimeDeploymentDescriptor(Archivist.java:718)
>>> at
>>> com.sun.enterprise.deployment.archivist.Archivist.readRuntimeDeploymentDescriptor(Archivist.java:668)
>>> at
>>> com.sun.enterprise.deployment.archivist.ApplicationArchivist.readRuntimeDeploymentDescriptor(ApplicationArchivist.java:728)
>>> at
>>> com.sun.enterprise.deployment.archivist.ApplicationArchivist.openWith(ApplicationArchivist.java:265)
>>> at
>>> com.sun.enterprise.deployment.archivist.ApplicationFactory.openWith(ApplicationFactory.java:240)
>>> at
>>> org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:170)
>>> at
>>> org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:93)
>>> at
>>> com.sun.enterprise.v3.server.ApplicationLifecycle.loadDeployer(ApplicationLifecycle.java:826)
>>> at
>>> com.sun.enterprise.v3.server.ApplicationLifecycle.setupContainerInfos(ApplicationLifecycle.java:768)
>>> at
>>> com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:368)
>>> at
>>> com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:240)
>>> at
>>> org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:370)
>>> at
>>> com.sun.enterprise.v3.admin.CommandRunnerImpl$1.execute(CommandRunnerImpl.java:355)
>>> at
>>> com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:370)
>>> at
>>> com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1067)
>>> at
>>> com.sun.enterprise.v3.admin.CommandRunnerImpl.access$1200(CommandRunnerImpl.java:96)
>>> at
>>> com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1247)
>>> at
>>> com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1235)
>>> at
>>> com.sun.enterprise.v3.admin.AdminAdapter.doCommand(AdminAdapter.java:465)
>>> at
>>> com.sun.enterprise.v3.admin.AdminAdapter.service(AdminAdapter.java:222)
>>> at
>>> com.sun.grizzly.tcp.http11.GrizzlyAdapter.service(GrizzlyAdapter.java:168)
>>> at
>>> com.sun.enterprise.v3.server.HK2Dispatcher.dispath(HK2Dispatcher.java:117)
>>> at
>>> com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:234)
>>> at
>>> com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:822)
>>> at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:719)
>>> at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:1013)
>>> at
>>> com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:225)
>>> at
>>> com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:137)
>>> at
>>> com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:104)
>>> at
>>> com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:90)
>>> at
>>> com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:79)
>>> at
>>> com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:54)
>>> at
>>> com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:59)
>>> at com.sun.grizzly.ContextTask.run(ContextTask.java:71)
>>> at
>>> com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:532)
>>> at
>>> com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:513)
>>> at java.lang.Thread.run(Thread.java:679)
>>> |#]
>>>
>>> [#|2011-05-26T10:56:19.191+0200|SEVERE|glassfish3.1|javax.enterprise.system.tools.admin.org.glassfish.deployment.admin|_ThreadID=87;_ThreadName=Thread-1;|Exception
>>> lors du déploiement de l’application [myapp] : Erreur de référencement : Cet
>>> ensemble ne comporte aucun bean nommé [MyEjbThatFailsToDeploy]|#]
>>>
>>>
>>> On Thu, May 26, 2011 at 11:29 AM, Sahoo wrote:
>>>
>>>> Send exception stack trace and any relevant info like where is the
>>>> class packaged? Is it in two places? Are all its dependencies satisfied?
>>>>
>>>> Sahoo
>>>>
>>>> On Thursday 26 May 2011 02:56 PM, Matthieu Bertin wrote:
>>>>
>>>> Hello Sahoo,
>>>>
>>>> I've added the jarmodule trying to force glassfish to read it. but it
>>>> didn't work.
>>>> I'm getting the very same error with the following application.xml:
>>>>
>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>> >>> http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="
>>>> http://java.sun.com/xml/ns/javaee
>>>> http://java.sun.com/xml/ns/javaee/application_6.xsd" version="6">
>>>> myapp
>>>> myapp
>>>>
>>>> business-2.0.3-SNAPSHOT.jar
>>>>
>>>> lib
>>>>
>>>>
>>>> and of course i've doubled-checked that the domain.jar is in the ear
>>>> lib folder, and contains the "missing" class.
>>>>
>>>>
>>>>
>>>
>>>
>>
>>
>
>

Matthieu Bertin...
Offline
Joined: 2011-04-03

geez, i forgot to rename the classes..

Here is a version of my file with the classes renamed.
<?xml version="1.0" encoding="UTF-8"?>

shop
shop

central
central

MyEjbThatSucceedsToDeploy

MyEjbThatSucceedsToDeploy

CLIENT-CERT
certificate

CONFIDENTIAL

MyEjbThatFailsToDeploy

MyEjbThatFailsToDeploy

CLIENT-CERT certificate

CONFIDENTIAL

-->

On Thu, May 26, 2011 at 4:23 PM, Matthieu Bertin <
> wrote:

> is this line a false alarm ?
>
> [#|2011-05-26T10:56:19.181+0200|SEVERE|glassfish3.1|global|_ThreadID=23;_ThreadName=Thread-1;|Class
> [ Lcom/mycompany/myapp/domain/dao/MyClassThatCannotBeFound ; ] not found.
> Error while loading [ class com.mycompany.myapp.auth.MyEjbThatFailsToDeploy
> ]|#]
>
> I've tried some more. I got another EJB which deploys flawlessly. It is in
> the same ejb jar. What is striking me is that it uses exactly the same MyClassThatCannotBeFound,
> in the same way. But it deploys, whereas the other does not.
>
> I've removed the mention of MyEjbThatFailsToDeploy in my
> glassfish-ejb-jar.xml, which nows is the following:
> <?xml version="1.0" encoding="UTF-8"?>
> Application Server 3.1 EJB 3.1//EN" "
> http://glassfish.org/dtds/glassfish-ejb-jar_3_1-1.dtd">
>
>
>
> shop
> shop
>
>
>
> central
> central
>
>
>
>
> CustomerAuthenticationEjb
>
> CustomerAuthenticationEjb
>
> CLIENT-CERT
> certificate
>
> CONFIDENTIAL
>
> CustomerAccessManagementEjb
>
> CustomerAccessManagementEjb
>
> CLIENT-CERT certificate
>
> CONFIDENTIAL
>
> -->
>
>
>
>
>
>
> and my glassfish-application.xml exists but it is empty.
>
> And i still get the same error message:
> [#|2011-05-26T10:56:19.181+0200|SEVERE|glassfish3.1|global|_ThreadID=23;_ThreadName=Thread-1;|Class
> [ Lcom/mycompany/myapp/domain/dao/MyClassThatCannotBeFound ; ] not found.
> Error while loading [ class com.mycompany.myapp.auth.MyEjbThatFailsToDeploy
> ]|#]
>
> On Thu, May 26, 2011 at 12:05 PM, Sahoo wrote:
>
>> I don't see any classloading errors. It seems there is a wrong EJB name
>> used somewhere. Most likely it is in one of the sun-*.xml file.
>>
>> Sahoo
>>
>> On Thursday 26 May 2011 03:11 PM, Matthieu Bertin wrote:
>>
>> EAR
>> +--------business.jar <---- containing EJB which fails to find a class
>> from the domain.jar
>> +--------/lib/
>> | +---- domain.jar <---- contains the "missing" class
>> +--------META-INF/
>> +----- application.xml
>>
>> all the dependencies of the missing class can be resolved: most of it
>> comes from javax.persistence and org.jasypt; the jasypt.jar is in the
>> glassfish/lib folder.
>>
>> here is the server.log i get when deploying:
>>
>> [#|2011-05-26T10:56:19.181+0200|SEVERE|glassfish3.1|global|_ThreadID=23;_ThreadName=Thread-1;|Class
>> [ Lcom/mycompany/myapp/domain/dao/MyClassThatCannotBeFound ; ] not found.
>> Error while loading [ class com.mycompany.myapp.auth.MyEjbThatFailsToDeploy
>> ]|#]
>>
>> [#|2011-05-26T10:56:19.188+0200|SEVERE|glassfish3.1|javax.enterprise.system.core.com.sun.enterprise.v3.server|_ThreadID=87;_ThreadName=Thread-1;|Exception
>> lors du déploiement de l’application [myapp]|#]
>>
>> [#|2011-05-26T10:56:19.189+0200|SEVERE|glassfish3.1|javax.enterprise.system.core.com.sun.enterprise.v3.server|_ThreadID=87;_ThreadName=Thread-1;|Erreur
>> de référencement : Cet ensemble ne comporte aucun bean nommé
>> [MyEjbThatFailsToDeploy]
>> java.lang.IllegalArgumentException: Erreur de référencement : Cet ensemble
>> ne comporte aucun bean nommé [MyEjbThatFailsToDeploy]
>> at
>> com.sun.enterprise.deployment.EjbBundleDescriptor.getEjbByName(EjbBundleDescriptor.java:287)
>> at
>> com.sun.enterprise.deployment.EjbBundleDescriptor.getEjbByName(EjbBundleDescriptor.java:271)
>> at
>> com.sun.enterprise.deployment.node.runtime.EjbNode.setElementValue(EjbNode.java:125)
>> at
>> com.sun.enterprise.deployment.node.SaxParserHandler.endElement(SaxParserHandler.java:476)
>> at
>> com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:604)
>> at
>> com.sun.org.apache.xerces.internal.impl.dtd.XMLNSDTDValidator.endNamespaceScope(XMLNSDTDValidator.java:266)
>> at
>> com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.handleEndElement(XMLDTDValidator.java:2053)
>> at
>> com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.endElement(XMLDTDValidator.java:927)
>> at
>> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanEndElement(XMLDocumentFragmentScannerImpl.java:1759)
>> at
>> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2915)
>> at
>> com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:625)
>> at
>> com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:116)
>> at
>> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:488)
>> at
>> com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:819)
>> at
>> com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:748)
>> at
>> com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:123)
>> at
>> com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1208)
>> at
>> com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:525)
>> at javax.xml.parsers.SAXParser.parse(SAXParser.java:392)
>> at
>> com.sun.enterprise.deployment.io.DeploymentDescriptorFile.read(DeploymentDescriptorFile.java:309)
>> at
>> com.sun.enterprise.deployment.archivist.Archivist.readRuntimeDeploymentDescriptor(Archivist.java:718)
>> at
>> com.sun.enterprise.deployment.archivist.Archivist.readRuntimeDeploymentDescriptor(Archivist.java:668)
>> at
>> com.sun.enterprise.deployment.archivist.ApplicationArchivist.readRuntimeDeploymentDescriptor(ApplicationArchivist.java:728)
>> at
>> com.sun.enterprise.deployment.archivist.ApplicationArchivist.openWith(ApplicationArchivist.java:265)
>> at
>> com.sun.enterprise.deployment.archivist.ApplicationFactory.openWith(ApplicationFactory.java:240)
>> at
>> org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:170)
>> at
>> org.glassfish.javaee.core.deployment.DolProvider.load(DolProvider.java:93)
>> at
>> com.sun.enterprise.v3.server.ApplicationLifecycle.loadDeployer(ApplicationLifecycle.java:826)
>> at
>> com.sun.enterprise.v3.server.ApplicationLifecycle.setupContainerInfos(ApplicationLifecycle.java:768)
>> at
>> com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:368)
>> at
>> com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:240)
>> at
>> org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:370)
>> at
>> com.sun.enterprise.v3.admin.CommandRunnerImpl$1.execute(CommandRunnerImpl.java:355)
>> at
>> com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:370)
>> at
>> com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1067)
>> at
>> com.sun.enterprise.v3.admin.CommandRunnerImpl.access$1200(CommandRunnerImpl.java:96)
>> at
>> com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1247)
>> at
>> com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1235)
>> at
>> com.sun.enterprise.v3.admin.AdminAdapter.doCommand(AdminAdapter.java:465)
>> at
>> com.sun.enterprise.v3.admin.AdminAdapter.service(AdminAdapter.java:222)
>> at
>> com.sun.grizzly.tcp.http11.GrizzlyAdapter.service(GrizzlyAdapter.java:168)
>> at
>> com.sun.enterprise.v3.server.HK2Dispatcher.dispath(HK2Dispatcher.java:117)
>> at
>> com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:234)
>> at
>> com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:822)
>> at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:719)
>> at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:1013)
>> at
>> com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:225)
>> at
>> com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:137)
>> at
>> com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:104)
>> at
>> com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:90)
>> at
>> com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:79)
>> at
>> com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:54)
>> at
>> com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:59)
>> at com.sun.grizzly.ContextTask.run(ContextTask.java:71)
>> at
>> com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:532)
>> at
>> com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:513)
>> at java.lang.Thread.run(Thread.java:679)
>> |#]
>>
>> [#|2011-05-26T10:56:19.191+0200|SEVERE|glassfish3.1|javax.enterprise.system.tools.admin.org.glassfish.deployment.admin|_ThreadID=87;_ThreadName=Thread-1;|Exception
>> lors du déploiement de l’application [myapp] : Erreur de référencement : Cet
>> ensemble ne comporte aucun bean nommé [MyEjbThatFailsToDeploy]|#]
>>
>>
>> On Thu, May 26, 2011 at 11:29 AM, Sahoo wrote:
>>
>>> Send exception stack trace and any relevant info like where is the class
>>> packaged? Is it in two places? Are all its dependencies satisfied?
>>>
>>> Sahoo
>>>
>>> On Thursday 26 May 2011 02:56 PM, Matthieu Bertin wrote:
>>>
>>> Hello Sahoo,
>>>
>>> I've added the jarmodule trying to force glassfish to read it. but it
>>> didn't work.
>>> I'm getting the very same error with the following application.xml:
>>>
>>> <?xml version="1.0" encoding="UTF-8"?>
>>> >> http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="
>>> http://java.sun.com/xml/ns/javaee
>>> http://java.sun.com/xml/ns/javaee/application_6.xsd" version="6">
>>> myapp
>>> myapp
>>>
>>> business-2.0.3-SNAPSHOT.jar
>>>
>>> lib
>>>
>>>
>>> and of course i've doubled-checked that the domain.jar is in the ear
>>> lib folder, and contains the "missing" class.
>>>
>>>
>>>
>>
>>
>

357 Guest
Offline
Joined: 2011-05-23

This is an auto-replied message. I am out of office right now and will be back on June 5th. For any urgent issues, please contact ved.singh...

Thanks,
Deepak