ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "M.A.Dunphy" <madun...@bigfoot.com>
Subject RE: weblogic ejbjar creation failure
Date Fri, 09 Feb 2001 13:50:44 GMT
Conor,

I think you are on the right track (but not sure how!!!). OK, I had a path
element as illustrated below;

<path id="project.class.path" location="${lib.dir}/"
path="${java.class.path}/">
        <fileset dir="${lib.dir}" includes="**/*.jar"/>
</path>

because some of my targets require other classes to be built before they can
compile, I wanted to add these classes to the classpath via a jar. And thus
I used the above as the classpath on the javac task. This appears to be
where the problem is, but I cant see why, as the definition for creating the
ejbjar it doesn't allow the classpath to be given by a reference ID, see
below:

        <ejbjar basejarname="${ejbjar.generic.basename}"
srcdir="${ejbjar.generic.srcdir}"
descriptordir="${ejbjar.generic.descriptordir}" includes="**/ejb-jar.xml"
excludes="**/weblogic*.xml">
            <weblogic destdir="${ejbjar.generic.destdir}"
classpath="${java.class.path}:${fw.classes}:${sa.classes}"
keepgenerated="true" keepgeneric="true"/>
        </ejbjar>

as you can see, for the classpath, I pass the pre-defined classpath
(${java.class.path}) and the two other directories that are the roots to
package structures that contain supporting classes used by the ejb classes.
No where do I pass the ${lib.dir} or project.class.path variable which
contain all generated jar files.

Conor, I do feel you are right as I modified the path id above to be more
restrictive (i.e. includes="**/*classes.jar) which meant that the ejb jars
would be ignored and this solved the problem. But how I might ask? At this
stage I'm totally confused (now I'm new to java and am not an expert as to
how java sources/gets it's classes!!)

Mick

-----Original Message-----
From: Conor MacNeill [mailto:conor@cortexebusiness.com.au]
Sent: 09 February 2001 12:29
To: ant-user@jakarta.apache.org
Subject: Re: weblogic ejbjar creation failure


Mick,

Are the generated jars in your classpath, or the classpath given to the
ejbjar/weblogic element? The code attempts to load super classes to add to
the generic jar. It is possible that these are being picked up from your
generated jar instead of your classes. It would probably be best if the
destination where the jars are placed is NOT in your classpath.

Conor

----- Original Message -----
From: "M.A.Dunphy" <madunphy@bigfoot.com>
To: <ant-user@jakarta.apache.org>
Sent: Friday, February 09, 2001 10:58 PM
Subject: RE: weblogic ejbjar creation failure


> And more info.
>
> Just got somebody else to install ant, and sun's xml parser on another
> machine. changed the dos environment so that it knows about these two.
Ran
> ant and got the same result!!! So would this imply it's something to do
with
> the build.xml file rather than my machine?
>
> Mick
>
> -----Original Message-----
> From: M.A.Dunphy [mailto:madunphy@bigfoot.com]
> Sent: 09 February 2001 10:37
> To: 'ant-user@jakarta.apache.org'
> Subject: RE: weblogic ejbjar creation failure
>
>
> And more info,
>
> When ant debug prints to show that it is attempting to build the ejbjar,
> from an explorer if I attempt to delete the original login.jar file,
windows
> returns saying access denied, share violation.
>
> So who's acessing the original jar file?
>
> -----Original Message-----
> From: M.A.Dunphy [mailto:madunphy@bigfoot.com]
> Sent: 09 February 2001 10:27
> To: 'ant-user@jakarta.apache.org'
> Subject: RE: weblogic ejbjar creation failure
>
>
> Conor,
>
> In the weblogic nested element, I've set the keepgeneric option, so that
> after running ant, I still have the login-generic.jar. I've then run the
> java weblogic.ejbc call in the same DOS window and it has no problem over
> writing the original login.jar file. What has changed, this was working
> before?. The only different I can see visually, is the ant debug says it
is
> forking to run the java weblogic.ejbc call. What does this do exactly? Is
> there some way to not fork to identify if this is the problem?
>
> Thanks
>
> Mick
>
> -----Original Message-----
> From: Conor MacNeill [mailto:conor@cortexebusiness.com.au]
> Sent: 09 February 2001 10:19
> To: ant-user@jakarta.apache.org
> Subject: Re: weblogic ejbjar creation failure
>
>
> Mick,
>
> Perhaps some other process has a lock on the jar. Can you delete the file
> by hand using explorer? Also trying running the ejbc invocation directly
> rather than through Ant and see if it gives the same behaviour.
>
> Conor
>

Mime
View raw message