geronimo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Jencks <david_jen...@yahoo.com>
Subject Re: Can not deploy daytrader in geronimo m2
Date Wed, 14 Mar 2007 12:34:01 GMT
I assume you are working with geronimo trunk from svn?

Can you please file a jira?   I recently changed where appclient  
files go and that caused this problem.

What daytrader is doing here is a bit odd (including client side jars  
in the server using manifest classpath) and I'd like to think a bit  
about what the best solution is.  It might be to change daytrader and  
it might be to put the client jar in two places.

thanks
david jencks

On Mar 14, 2007, at 5:56 AM, FranK G wrote:

> Hi,
> I did a little debug to the class not found problem
> when deploy daytrader.
> The MANIFEST.MF of web.war includes the following
> line:
>   Class-Path: dt-ejb.jar streamer.jar wsappclient.jar
> which means the classloader will includes the above
> three jar files. I notice these jars are added to the
> classpath in
> org.apache.geronimo.deployment.DeploymentContext. The
> following method implements this function:
>
>     public void addManifestClassPath(JarFile
> moduleFile, URI moduleBaseUri) throws
> DeploymentException {
>         ......
>         for (StringTokenizer tokenizer = new
> StringTokenizer(manifestClassPath, " ");
> tokenizer.hasMoreTokens();) {
>             ......
>             try {
>                 URI targetUri =
> moduleBaseUri.resolve(pathUri);
>                 if (targetUri.getPath().endsWith("/"))
>                     throw new
> IllegalStateException("target path must not end with a
> '/' character: " + targetUri);
>
> configuration.addToClassPath(targetUri.toString());
>             } catch (IOException e) {
>                 throw new DeploymentException(e);
>             }
>         }
>     }
> Let's take wsappclient.jar for example, its targetUri
> is "../wsappclient.jar", but wsappclient.jar is not
> copied to the parent directory of the web module. So
> class Trade can not be found.
> I also notice the structure of the
> %geronimo_home%\repository in geronimo v2.0 is
> different from v1.1, I don't know why.
>
> Thanks
> Frank
>
> On 2007-03-14 11:16:05, FranK G <frank2006g@yahoo.com>
> wrote:
>> Charis, thank you for your reply.
>> I got the same error when using SUN jdk.
>> C:\>deploy --user system --password manager deploy
>> F:\daytrader\modules\ear\target\daytrader-ear-2.0-SNAPSHOT.ear
>> F:\daytrader\plans\daytrader-2.0-M2-jpa-plan.xml
>> Using JRE_HOME:        C:\Program
>> Files\Java\jdk1.5.0_06\jre
>>    Error: Unable to distribute
>> daytrader-ear-2.0-SNAPSHOT.ear: Could
>>    not load service class
>>
>> org.apache.geronimo.samples.daytrader.client.ws.Trade
>>
>>
>> org.apache.geronimo.samples.daytrader.client.ws.Trade
>> in
>>    classloader
>>
>> org.apache.geronimo.daytrader/daytrader_web.war/2.0-SNAPSHOT/car
>>
>> Thanks
>> Frank
>>
>> On 2007-03-13 21:13:37, Christopher Blythe
>> <cjblythe25@gmail.com> wrote:
>>> Frank...
>>>
>>> Try using the daytrader-2.0-M2-jpa-plan.xml as the
>> deployment plan. If that
>>> doesn't help, it might be worth trying the SUN JDK.
>>>
>>> Chris
>>>
>>> On 3/13/07, FranK G <frank2006g@yahoo.com> wrote:
>>>>
>>>> I checked out the source codes of daytrader from
>>>>
>> https://svn.apache.org/repos/asf/geronimo/daytrader/trunk
>>>> and built it successful. But I encountered the
>>>> following error when I deployed it:
>>>> C:\>deploy --user system --password manager deploy
>>>>
>> F:\daytrader\modules\ear\target\daytrader-ear-2.0-SNAPSHOT.ear
>>>>
>> F:\daytrader\plans\daytrader-geronimo-derby-plan.xml
>>>> Using JRE_HOME:        C:\Program
>> Files\IBM\Java50\jre
>>>>     Error: Unable to distribute
>>>> daytrader-ear-2.0-SNAPSHOT.ear:
>>>>
>>>>
>> com.sun.xml.bind.v2.runtime.IllegalAnnotationsException:
>>>> 51 counts
>>>>     of IllegalAnnotationExceptions
>>>>
>>>>     Property "id" has an XmlID annotation but its
>> type
>>>> is not String.
>>>>
>>>>         this problem is related to the following
>>>> location:
>>>>
>>>>                 at protected java.lang.String
>>>> org.apache.openejb.jee.EjbJar.id
>>>>
>>>>                 at org.apache.openejb.jee.EjbJar
>>>>
>>>>     Property "id" has an XmlID annotation but its
>> type
>>>> is not String.
>>>>
>>>>         this problem is related to the following
>>>> location:
>>>>
>>>>                 at protected java.lang.String
>>>> org.apache.openejb.jee.Text.id
>>>>
>>>>                 at org.apache.openejb.jee.Text
>>>>
>>>>                 at public
>>>> org.apache.openejb.jee.Text[]
>>>>
> org.apache.openejb.jee.EjbJar.getDescriptions()
>>>>
>>>>                 at org.apache.openejb.jee.EjbJar
>>>> .......
>>>>          51 counts of IllegalAnnotationExceptions
>>>>
>>>> I think this is a problem of JAXB, so I replaced
>>>> jaxb-impl-2.0.3.jar and jaxb-api-2.0.jar with
>>>> jaxb-impl-2.1.1.jar and jaxb-api-2.1.jar, then I
>> got
>>>> another error:
>>>> Using JRE_HOME:        C:\Program
>> Files\IBM\Java50\jre
>>>>     Error: Unable to distribute
>>>> daytrader-ear-2.0-SNAPSHOT.ear: Could
>>>>     not load service class
>>>>
>>>>
>> org.apache.geronimo.samples.daytrader.client.ws.Trade
>>>>
>>>>
>>>>
>> org.apache.geronimo.samples.daytrader.client.ws.Trade
>>>> in
>>>>     classloader
>>>> geronimo/daytrader-derby-tomcat_web.war/1.1.1/car
>>>>
>>>> Can anyone help me?
>>>>
>>>> Frank
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>> _____________________________________________________________________ 
>> _______________
>>>> Expecting? Get great news right away with email
>> Auto-Check.
>>>> Try the Yahoo! Mail Beta.
>>>>
>> http://advision.webevents.yahoo.com/mailbeta/newmail_tools.html
>>>>
>>>
>>>
>>>
>>> -- 
>>> "I say never be complete, I say stop being perfect,
> I
>> say let... lets
>>> evolve, let the chips fall where they may." - Tyler
>> Durden
>>>
>>
>>
>>
>>
>>
>>
>> _____________________________________________________________________ 
>> _______________
>> Get your own web address.
>> Have a HUGE year through Yahoo! Small Business.
>> http://smallbusiness.yahoo.com/domains/?p=BESTDEAL
>>
>>
>
>
>
>
>
>
> ______________________________________________________________________ 
> ______________
> Food fight? Enjoy some healthy debate
> in the Yahoo! Answers Food & Drink Q&A.
> http://answers.yahoo.com/dir/?link=list&sid=396545367


Mime
View raw message