RE: resource within jar is not being found
Hi Yann, Yes, I meant B depends on A. Maven version is 1.0.2. A POM: ?xml version=1.0 encoding=UTF-8? project pomVersion3/pomVersion artifactIdA/artifactId nameA/name groupIdA/groupId currentVersion1.0/currentVersion organization/ inceptionYear2005/inceptionYear logo/ urlTBD/url issueTrackingUrlTBD/issueTrackingUrl siteAddressTBD/siteAddress siteDirectoryTBD/siteDirectory distributionSiteTBD/distributionSite distributionDirectoryTBD/distributionDirectory repository connectionTBD/connection /repository mailingLists mailingList name${pom.name} Dev List/name /mailingList mailingList name${pom.name} User List/name /mailingList /mailingLists developers developer nameErick Dovale/name idedovale/id email[EMAIL PROTECTED]/email organizationNA/organization /developer /developers dependencies dependency groupIdjunit/groupId artifactIdjunit/artifactId version3.8.1/version typejar/type /dependency dependency groupIdcommons-logging/groupId artifactIdcommons-logging/artifactId version1.0.4/version typejar/type /dependency dependency groupIdjdom/groupId artifactIdjdom/artifactId version1.0/version typejar/type /dependency dependency groupIdlog4j/groupId artifactIdlog4j/artifactId version1.2.8/version typejar/type /dependency dependency groupIdcommons-httpclient/groupId artifactIdcommons-httpclient/artifactId version2.0.2/version typejar/type /dependency dependency groupIdcommons-net/groupId artifactIdcommons-net/artifactId version1.4/version typejar/type /dependency dependency groupIdxmlParserAPIs/groupId artifactIdxmlParserAPIs/artifactId version2.6.2/version typejar/type /dependency dependency groupIdxerces/groupId artifactIdxercesImpl/artifactId version2.6.2/version typejar/type /dependency /dependency dependency groupIdx10/groupId artifactIdx10/artifactId version1.0.1/version typejar/type /dependency /dependencies build nagEmailAddress[EMAIL PROTECTED]/nagEmailAddress sourceDirectorysrc/main/java/sourceDirectory unitTestSourceDirectorysrc/test/java/unitTestSourceDirectory unitTest includes include**/*Test.java/include /includes resources resource directorysrc/test/resources/directory filteringfalse/filtering includes include**/*/include /includes /resource /resources /unitTest resources resource directorysrc/main/java/directory includes include**/*/include /includes filteringfalse/filtering /resource /resources /build /project B POM: ?xml version=1.0 encoding=UTF-8? project pomVersion3/pomVersion artifactIdBb/artifactId nameB/name groupIdB/groupId currentVersion1.0/currentVersion organization/ inceptionYear2005/inceptionYear logo/ urlTBD/url issueTrackingUrlTBD/issueTrackingUrl siteAddressTBD/siteAddress siteDirectoryTBD/siteDirectory distributionSiteTBD/distributionSite distributionDirectoryTBD/distributionDirectory repository connectionTBD/connection /repository mailingLists mailingList name${pom.name} Dev List/name /mailingList mailingList name${pom.name} User List/name /mailingList /mailingLists developers developer nameErick Dovale/name idedovale/id email[EMAIL PROTECTED]/email organizationNA/organization /developer /developers dependencies dependency groupIdA/groupId artifactIdA/artifactId version1.0/version typejar/type /dependency dependency groupIdjunit/groupId artifactIdjunit/artifactId version3.8.1/version typejar/type /dependency dependency groupIdcommons-logging/groupId
RE: resource within jar is not being found
Erick, There's an erroneous tag in your A POM on line 85 : /dependency /dependency dependency groupIdx10/groupId artifactIdx10/artifactId Maybe it's a coincidence, but the erroneous tag is just before your failing dependency. Please correct it and let me know if your problem persists. Yann -- Mail d'origine --- De : quot;Erick Dovalequot; [EMAIL PROTECTED] A : quot;Maven Users Listquot; users@maven.apache.org Cc : Date : Thu, 16 Jun 2005 09:37:28 -0400 Objet : RE: resource within jar is not being found -Hi Yann, - -Yes, I meant B depends on A. Maven version is 1.0.2. -A POM: -... - -B POM: -... - -The java code in B actually trying to read the resource is like this: - - final void loadXMLDocument(InputSource in) throws IOException, -JDOMException - { - setDocument(getSaxBuilder().build(in)); - } - -where the InputSource instance was created like this: - -new InputSource(uri) - -and uri has this path to the resource: - -C:\Documents and -Settings\edovale\.maven\repository\A\jars\A-1.0.jar!\resource.xml - -I hope that gives you a better understanding of the environment. - -Yhanks. - -Erick. - - --Original Message- -From: Yann LE DU [mailto:[EMAIL PROTECTED] -Sent: Thursday, June 16, 2005 5:05 AM -To: Maven Users List -Subject: Re:resource within jar is not being found - -Hi Erick, - -Can you provide any details for reproducibility ? -* A B POM contents -* A-1.0.jar structure -* Java code calling resource.xml - - -Also, you said A depends on B. Didn't you mean the -contrary ? - -Are you using Maven 1.0.2 or 2.0 ? - -Regards, - -Yann - - --- Mail d'origine --- - - De : quot;Erick Dovalequot; [EMAIL PROTECTED] - A : quot;Maven Users Listquot; [EMAIL PROTECTED] - Cc : - Date : Wed, 15 Jun 2005 15:07:08 -0400 - Objet : resource within jar is not being found - - - --Hello out there, -- --I am having a problem I am not sure is directly -related to maven, so --forgive me if it is not. --I have 2 projects A and B. A depends on B. When I am -running tests in B --it is not finding stuff into A-1.0.jar. More -specifically an xml file --needed. This is happening although the jar exists and -maven seems to be --looking for it in the right place using the following uri: --C:\Documents and --Settings\edovale\.maven\repository\A\jars\A-1.0.jar!\resource.xml -(The --system cannot find the path specified) -- --I have checked the content of the jar and the -resource.xml file is where - --it is suppose to be, still it is not been found, As a -matter of fact, - --nothing is been found into this jar file. -- --Any clue as to where to look to solve this issue? -- --I am using maven 1.2 -- - - -- -To unsubscribe, e-mail: [EMAIL PROTECTED] -For additional commands, e-mail: [EMAIL PROTECTED] - - - -- -To unsubscribe, e-mail: [EMAIL PROTECTED] -For additional commands, e-mail: [EMAIL PROTECTED] - - - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]