Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Web Tools Project (WTP) » Java EE dependencies not added to lib
Java EE dependencies not added to lib [message #515035] Wed, 17 February 2010 09:28 Go to next message
Matt Rossner is currently offline Matt Rossner
Messages: 18
Registered: July 2009
Junior Member
Hi,

I have a web project that references some other Jars on the build path. I've gone into the project properties --> Java EE Module Dependcies, it also relies on a utility project. I check the utility project and the jars required. When I publish, it only copies the utility project but not the other jars selected. This seems like it may be a bug but I'm not sure if I'm missing something here.

I'm using Ganymede version 3.4.2, build M20090211-1700
Re: Java EE dependencies not added to lib [message #516625 is a reply to message #515035] Wed, 24 February 2010 10:44 Go to previous messageGo to next message
Matt Rossner is currently offline Matt Rossner
Messages: 18
Registered: July 2009
Junior Member
No one has any ideas on this or seen or heard of this problem before?
Re: Java EE dependencies not added to lib [message #516636 is a reply to message #515035] Wed, 24 February 2010 11:10 Go to previous messageGo to next message
Matt Rossner is currently offline Matt Rossner
Messages: 18
Registered: July 2009
Junior Member
Ok so after seeing another thread on this I have some additional info but still no solution:

This is my org.eclipse.wst.common.component file

<?xml version="1.0" encoding="UTF-8"?>
<project-modules id="moduleCoreId" project-version="1.5.0">
<wb-module deploy-name="Ibee">
<wb-resource deploy-path="/" source-path="/WebContent"/>
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src"/>
        <dependent-module archiveName="IbeeCommon.jar" deploy-path="/WEB-INF/lib" handle="module:/resource/IbeeCommon/IbeeCommon">
            <dependency-type>uses</dependency-type>
        </dependent-module>
<property name="java-output-path" value="build/classes"/>
<property name="context-root" value="Ibee"/>
</wb-module>
</project-modules>


In the "Java EE Module Dependencies" tab I have a bunch of others checked but none of them are in this file. The Jars are in another project in the same workspace and already in the build path. If I click "Add Jars" and manually add them, they'll appear with a little yellow warning sign. They'll be in the xml file but they won't get copied over to the lib.
Re: Java EE dependencies not added to lib [message #516671 is a reply to message #516636] Wed, 24 February 2010 07:54 Go to previous messageGo to next message
Larry Isaacs is currently offline Larry Isaacs
Messages: 1305
Registered: July 2009
Senior Member
Matt Rossner wrote:
> Ok so after seeing another thread on this I have some additional info
> but still no solution:
>
> This is my org.eclipse.wst.common.component file
>
>
> <?xml version="1.0" encoding="UTF-8"?>
> <project-modules id="moduleCoreId" project-version="1.5.0">
> <wb-module deploy-name="Ibee">
> <wb-resource deploy-path="/" source-path="/WebContent"/>
> <wb-resource deploy-path="/WEB-INF/classes" source-path="/src"/>
> <dependent-module archiveName="IbeeCommon.jar"
> deploy-path="/WEB-INF/lib" handle="module:/resource/IbeeCommon/IbeeCommon">
> <dependency-type>uses</dependency-type>
> </dependent-module>
> <property name="java-output-path" value="build/classes"/>
> <property name="context-root" value="Ibee"/>
> </wb-module>
> </project-modules>
>
>
> In the "Java EE Module Dependencies" tab I have a bunch of others
> checked but none of them are in this file. The Jars are in another
> project in the same workspace and already in the build path. If I click
> "Add Jars" and manually add them, they'll appear with a little yellow
> warning sign. They'll be in the xml file but they won't get copied over
> to the lib.

Sorry I overlooked this one. You need to also post your ".classpath"
file. I'm wondering if a jar appears multiple times in the build path
(in a project and in dependent projects) whether there could be
ambiguity about whether to publish or not publish that is confusing the
publishing code.

Cheers,
Larry
Re: Java EE dependencies not added to lib [message #517116 is a reply to message #515035] Fri, 26 February 2010 05:28 Go to previous messageGo to next message
Matt Rossner is currently offline Matt Rossner
Messages: 18
Registered: July 2009
Junior Member
Thanks for your reply. Here's my .classpath, sorry it's quite long... It seems I'm not allowed to add attachments.

<?xml version="1.0" encoding="UTF-8"?>
<classpath>
	<classpathentry kind="src" path="src"/>
	<classpathentry kind="con" path="org.eclipse.jst.j2ee.internal.web.container"/>
	<classpathentry kind="con" path="org.eclipse.jst.server.core.container/org.eclipse.jst.server.tomcat.runtimeTarget/Apache Tomcat v5.0"/>
	<classpathentry combineaccessrules="false" kind="src" path="/IbeeCommon"/>
	<classpathentry kind="lib" path="/IbeeBOF/jars/sbo/interface/IAclManager.jar"/>
	<classpathentry kind="lib" path="/IbeeBOF/jars/sbo/interface/IChannelManager.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/sbo/interface/IDmObjectManager.jar"/>
	<classpathentry kind="lib" path="/IbeeBOF/jars/sbo/interface/IFclManager.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/sbo/interface/IFolderManager.jar" sourcepath="/IbeeBOF/src">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/sbo/interface/IGenericObjectManager.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/sbo/interface/IGroupManager.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/sbo/interface/IIbeeNavMenuManager.jar"/>
	<classpathentry kind="lib" path="/IbeeBOF/jars/sbo/interface/ILanguageManager.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/sbo/interface/ILifecycleManager.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/sbo/interface/IPublicationManager.jar"/>
	<classpathentry kind="lib" path="/IbeeBOF/jars/sbo/interface/IRelationManager.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/sbo/interface/IStructContentManager.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/sbo/interface/IVersionManager.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/sbo/interface/IWcmCopyDocumentManager.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/sbo/interface/IWcmDocumentManager.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/sbo/interface/IXMLTransformManager.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/tbos/interface/IIbeeRelation.jar"/>
	<classpathentry kind="lib" path="/IbeeBOF/jars/tbos/interface/ISATCabinet.jar"/>
	<classpathentry kind="lib" path="/IbeeBOF/jars/tbos/interface/ISATDocument.jar"/>
	<classpathentry kind="lib" path="/IbeeBOF/jars/tbos/interface/ISATFolder.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/tbos/interface/ISATIbeeNavmenu.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/tbos/interface/ISATPersistent.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/tbos/interface/ISATSysobject.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/tbos/interface/ISATWcmChannel.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/tbos/interface/ISATWcmChannelFld.jar"/>
	<classpathentry kind="lib" path="/IbeeBOF/jars/tbos/interface/ISATWcmCopyDocument.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/tbos/interface/ISATWcmDocument.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/tbos/interface/ISATWcmEdition.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/tbos/interface/ISATWcmFeed.jar"/>
	<classpathentry kind="lib" path="/IbeeBOF/jars/tbos/interface/ISATWcmFeedViewer.jar"/>
	<classpathentry kind="lib" path="/IbeeBOF/jars/tbos/interface/ISATWcmFolder.jar"/>
	<classpathentry kind="lib" path="/IbeeBOF/jars/tbos/interface/ISATWcmStructItem.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="lib" path="/IbeeBOF/jars/tbos/interface/ISATWcmStructType.jar">
		<attributes>
			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
		</attributes>
	</classpathentry>
	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/jre6"/>
	<classpathentry kind="lib" path="dfc.jar"/>
	<classpathentry kind="lib" path="dfcbase.jar"/>
	<classpathentry kind="lib" path="/IbeeBOF/jars/sbo/interface/IAbstractManager.jar" sourcepath="/IbeeBOF/src"/>
	<classpathentry kind="output" path="WebContent/WEB-INF/classes"/>
</classpath>


I'm not really sure why some of them have the dependency attribute and some don't
Re: Java EE dependencies not added to lib [message #517199 is a reply to message #517116] Fri, 26 February 2010 10:00 Go to previous messageGo to next message
Larry Isaacs is currently offline Larry Isaacs
Messages: 1305
Registered: July 2009
Senior Member
Are any jars appearing in the published WEB-INF/lib besides the
IbeeCommon.jar? If so, are there any jars that are not appearing in
WEB-INF/lib that have the "org.eclipse.jst.component.dependency"
attribute in the ".classpath" file?

Cheers,
Larry

Matt Rossner wrote:
> Thanks for your reply. Here's my .classpath, sorry it's quite long... It
> seems I'm not allowed to add attachments.
>
>
<snip />
>
>
> I'm not really sure why some of them have the dependency attribute and
> some don't
Re: Java EE dependencies not added to lib [message #517549 is a reply to message #515035] Mon, 01 March 2010 04:41 Go to previous messageGo to next message
Matt Rossner is currently offline Matt Rossner
Messages: 18
Registered: July 2009
Junior Member
Actually I understand why only some had the dependency. I had unchecked a few at some point just as a test and forgot to recheck them. When I check them all, they all have the dependency attribute and none of them get copied over. Although the IbeeCommon jar does get copied.

Thanks
Re: Java EE dependencies not added to lib [message #517602 is a reply to message #517549] Mon, 01 March 2010 09:06 Go to previous messageGo to next message
Larry Isaacs is currently offline Larry Isaacs
Messages: 1305
Registered: July 2009
Senior Member
Matt Rossner wrote:
> Actually I understand why only some had the dependency. I had unchecked
> a few at some point just as a test and forgot to recheck them. When I
> check them all, they all have the dependency attribute and none of them
> get copied over. Although the IbeeCommon jar does get copied.
> Thanks

Please post the ".classpath" and
".settings/org.eclipse.wst.common.component" file for the IbeeCommon
project. Maybe something in there is confusing things. Also, are you
using 3.4.2 of the Java EE package? If not, what version of WTP are you
using with Eclipse 3.4.2?

Cheers,
Larry
Re: Java EE dependencies not added to lib [message #517661 is a reply to message #515035] Mon, 01 March 2010 11:07 Go to previous messageGo to next message
Matt Rossner is currently offline Matt Rossner
Messages: 18
Registered: July 2009
Junior Member
Classpath:

<?xml version="1.0" encoding="UTF-8"?>
<classpath>
	<classpathentry kind="src" path="src"/>
	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
	<classpathentry kind="lib" path="log4j.jar"/>
	<classpathentry kind="con" path="org.eclipse.jst.j2ee.internal.module.container"/>
	<classpathentry kind="lib" path="dfc.jar"/>
	<classpathentry kind="output" path="bin"/>
</classpath>


Settings:
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
	<classpathentry kind="src" path="src"/>
	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
	<classpathentry kind="lib" path="log4j.jar"/>
	<classpathentry kind="con" path="org.eclipse.jst.j2ee.internal.module.container"/>
	<classpathentry kind="lib" path="dfc.jar"/>
	<classpathentry kind="output" path="bin"/>
</classpath>


As for Eclipse it is the Java EE package (all in one).
Re: Java EE dependencies not added to lib [message #517705 is a reply to message #517661] Mon, 01 March 2010 13:42 Go to previous messageGo to next message
Larry Isaacs is currently offline Larry Isaacs
Messages: 1305
Registered: July 2009
Senior Member
Matt Rossner wrote:
> Classpath:
>
>
> <?xml version="1.0" encoding="UTF-8"?>
> <classpath>
> <classpathentry kind="src" path="src"/>
> <classpathentry kind="con"
> path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
> <classpathentry kind="lib" path="log4j.jar"/>
> <classpathentry kind="con"
> path="org.eclipse.jst.j2ee.internal.module.container"/>
> <classpathentry kind="lib" path="dfc.jar"/>
> <classpathentry kind="output" path="bin"/>
> </classpath>
>
>
> Settings:
> <?xml version="1.0" encoding="UTF-8"?>
> <classpath>
> <classpathentry kind="src" path="src"/>
> <classpathentry kind="con"
> path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
> <classpathentry kind="lib" path="log4j.jar"/>
> <classpathentry kind="con"
> path="org.eclipse.jst.j2ee.internal.module.container"/>
> <classpathentry kind="lib" path="dfc.jar"/>
> <classpathentry kind="output" path="bin"/>
> </classpath>
>
>
> As for Eclipse it is the Java EE package (all in one).

Ah ha. Your component file looks strangely like your ".classpath" file.
Could that be the problem? :) Would I be correct in assuming you
haven't updated to WTP 3.0.5?

On the assumption that the ".components" file has nothing odd in it,
probably the best way to make progress on this is to first try
temporarily removing the dependency on IbeeCommon and see if that
affects publishing. If the jars still don't appear, create a separate
workspace and see if you can create scaled down versions of Ibee and
IbeeBOF, with minimal content and minimal number of jars, which still
exhibits this problem. If you can duplicate this problem in a new
workspace, create a WebTools bugzilla report with WTP ServerTools as the
Product and "jst.server" as the Component. Attach a zip of the
minimal projects to the bug and post the bug number here. Hopefully
with minimal projects, it won't take a lot of effort to get them up my
own workspace. Then I can examine exactly what is not working for you.
So far, all attempts to duplicate this behavior based on what
information I can glean so far have failed. The jars publish as expected.

Cheers,
Larry
Re: Java EE dependencies not added to lib [message #520227 is a reply to message #515035] Thu, 11 March 2010 10:46 Go to previous messageGo to next message
Matt Rossner is currently offline Matt Rossner
Messages: 18
Registered: July 2009
Junior Member
Actually, looks like I just copy/pasted the wrong file. The settings file is like this:

<?xml version="1.0" encoding="UTF-8"?>
<project-modules id="moduleCoreId" project-version="1.5.0">
    <wb-module deploy-name="IbeeCommon">
        <wb-resource deploy-path="/" source-path="/src"/>
    </wb-module>
</project-modules>


Anyway, I've tried making a new workspace with just a basic configuration and sure enough Jars get copied over correctly. I've compared all the .classpath and .setting files and I don't really see any difference but on my project it just doesn't work.

For a while I'm just using an Ant script to copy the missing jars whenever I do a clean on the server but it would be really nice to get this working properly.
Re: Java EE dependencies not added to lib [message #520289 is a reply to message #520227] Thu, 11 March 2010 14:48 Go to previous message
Larry Isaacs is currently offline Larry Isaacs
Messages: 1305
Registered: July 2009
Senior Member
Matt Rossner wrote:
> Actually, looks like I just copy/pasted the wrong file. The settings
> file is like this:
>
>
> <?xml version="1.0" encoding="UTF-8"?>
> <project-modules id="moduleCoreId" project-version="1.5.0">
> <wb-module deploy-name="IbeeCommon">
> <wb-resource deploy-path="/" source-path="/src"/>
> </wb-module>
> </project-modules>
>
>
> Anyway, I've tried making a new workspace with just a basic
> configuration and sure enough Jars get copied over correctly. I've
> compared all the .classpath and .setting files and I don't really see
> any difference but on my project it just doesn't work.
>
> For a while I'm just using an Ant script to copy the missing jars
> whenever I do a clean on the server but it would be really nice to get
> this working properly.

In this new workspace, import the problem projects, making sure to copy
the projects over to the new workspace. Then see if they misbehave in
the new workspace. The source of the behavior could be something
"odd/corrupt" in the metadata associated with the workspace.

Cheers,
Larry
Previous Topic:Forcing existing project into WTP
Next Topic:TargetId for WTP XML Editor Popup
Goto Forum:
  


Current Time: Sat Aug 23 16:02:35 EDT 2014

Powered by FUDForum. Page generated in 0.06160 seconds