• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

Jenkins via Maven deploy to Nexus snapshot repository

 
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
We have project use ant script and build ear. I have created pom and setting.xml to deploy to nexus. It's working, but only META_INF deploying to nexus. The ear is 18MB, but in nexus snapshot repo just 2.2 kb. Would you let me know what is wrong here?

Thanks,
Bob

------------

war:
[war] Building war: /var/lib/jenkins/jobs/Zur-18-ClaimswebService-build/workspace/ClaimService/build/ClaimService.war

ClaimServiceEAR:

clean:
[delete] Deleting directory /var/lib/jenkins/jobs/Zur-18-ClaimswebService-build/workspace/ClaimServiceEAR/build
[mkdir] Created dir: /var/lib/jenkins/jobs/Zur-18-ClaimswebService-build/workspace/ClaimServiceEAR/build

copy:
[copy] Copying 1 file to /var/lib/jenkins/jobs/Zur-18-ClaimswebService-build/workspace/ClaimServiceEAR/build

buildEar:
[jar] Building jar: /var/lib/jenkins/jobs/Zur-18-ClaimswebService-build/workspace/ClaimServiceEAR/build/ClaimsService.ear

BUILD SUCCESSFUL
Total time: 10 seconds
[workspace] $ /bin/sh -xe /tmp/hudson8209605888787588565.sh
+ cd /var/lib/jenkins/jobs/Zur-18-ClaimswebService-build/workspace/ClaimService
+ /maven/apache-maven-3.0.5/bin/mvn -e -s settings.xml deploy
log4j:WARN No appenders could be found for logger (Sisu).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
[INFO] Error stacktraces are turned on.
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building claimservice 1.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-ear-plugin:2.6:generate-application-xml (default-generate-application-xml) @ claimservice ---
[INFO] Generating application.xml
[INFO]
[INFO] --- maven-resources-plugin:2.4.3:resources (default-resources) @ claimservice ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /var/lib/jenkins/jobs/Zur-18-ClaimswebService-build/workspace/ClaimService/src/main/resources
[INFO]
[INFO] --- maven-ear-plugin:2.6:ear (default-ear) @ claimservice ---
[INFO] Could not find manifest file: /var/lib/jenkins/jobs/Zur-18-ClaimswebService-build/workspace/ClaimService/target/claimservice-1.0-SNAPSHOT/META-INF/MANIFEST.MF - Generating one
[INFO] Building jar: /var/lib/jenkins/jobs/Zur-18-ClaimswebService-build/workspace/ClaimService/target/claimservice-1.0-SNAPSHOT.ear
[INFO]
[INFO] --- maven-install-plugin:2.3.1:install (default-install) @ claimservice ---
[INFO] Installing /var/lib/jenkins/jobs/Zur-18-ClaimswebService-build/workspace/ClaimService/target/claimservice-1.0-SNAPSHOT.ear to /var/lib/jenkins/.m2/repository/com/xxxx/claimservice/1.0-SNAPSHOT/claimservice-1.0-SNAPSHOT.ear
[INFO] Installing /var/lib/jenkins/jobs/Zur-18-ClaimswebService-build/workspace/ClaimService/pom.xml to /var/lib/jenkins/.m2/repository/com/xxxxx/claimservice/1.0-SNAPSHOT/claimservice-1.0-SNAPSHOT.pom
[INFO]
[INFO] --- maven-deploy-plugin:2.7:deploy (default-deploy) @ claimservice ---
Downloading:
http://xxx.xx.xxx.xxx:8081/content/repositories/snapshots/com/xxxxx/claimservice/1.0-SNAPSHOT/maven-metadata.xml
769/769 B
Downloaded: http://xxx.xx.xxx.xxx:8081/content/repositories/snapshots/com/xxxxx/claimservice/1.0-SNAPSHOT/maven-metadata.xml (769 B at 5.3 KB/sec)

Uploaded: http://xxx.xx.xxx.xxx:8081/content/repositories/snapshots/com/xxxxx/claimservice/1.0-SNAPSHOT/claimservice-1.0-20140922.162539-92.ear (3 KB at 38.1 KB/sec)
Uploading: http://xxx.xx.xxx.xxx:8081/content/repositories/snapshots/com/xxxxx/claimservice/1.0-SNAPSHOT/claimservice-1.0-20140922.162539-92.pom
2/2 KB

Uploaded: http://xxx.xx.xxx.xxx:8081/content/repositories/snapshots/com/xxxxx/claimservice/1.0-SNAPSHOT/claimservice-1.0-20140922.162539-92.pom (2 KB at 47.8 KB/sec)
Downloading: http://xxx.xx.xxx.xxx:8081/content/repositories/snapshots/com/xxxxx/claimservice/maven-metadata.xml
280/280 B

Downloaded: http://xxx.xx.xxx.xxx:8081/content/repositories/snapshots/com/xxxxx/claimservice/maven-metadata.xml (280 B at 14.4 KB/sec)
Uploading: http://xxx.xx.xxx.xxx:8081/content/repositories/snapshots/com/xxxxx/claimservice/1.0-SNAPSHOT/maven-metadata.xml
769/769 B

Uploaded: http://xxx.xx.xxx.xxx:8081/content/repositories/snapshots/com/xxxxx/claimservice/1.0-SNAPSHOT/maven-metadata.xml (769 B at 25.9 KB/sec)
Uploading: http://xxx.xx.xxx.xxx:8081/content/repositories/snapshots/com/xxxxx/claimservice/maven-metadata.xml
280/280 B

Uploaded: http://xxx.xx.xxx.xxx:8081/content/repositories/snapshots/com/xxxxx/claimservice/maven-metadata.xml (280 B at 10.5 KB/sec)
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.760s
[INFO] Finished at: Mon Sep 22 12:25:39 EDT 2014
 
author & internet detective
Posts: 40035
809
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is the problem that the ear only contains a META-INF folder? If so, that sounds like an Ant problem. Or it the problem occurring after that?
 
Bob pat
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The ear build correct and it has META-INF and war folder, but it just copying META-INF.

Thanks,
Bob
 
Jeanne Boyarsky
author & internet detective
Posts: 40035
809
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
So you are saying that the ear generated by Ant has the war folder but http://xxx.xx.xxx.xxx:8081/content/repositories/snapshots/com/xxxxx/claimservice/1.0-SNAPSHOT/claimservice-1.0-20140922.162539-92.ear (3 KB at 38.1 KB/sec) does not? Can you check again? That seems bizzare. All Maven is doing in that line is uploading your file to Nexus.
 
Bob pat
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The ear is 18MB and it is fine, but the ear in nexus repo is just 2.2kb. Why war folder is not copying/deploying and only META-INF folder copying/deploying? That is the issue I don't understand.

Thanks,
Bob
 
author
Posts: 5856
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Look at target/claimservice-1.0-20140922.162539-92.ear and tell us what its size is. And let us know if it contains the WAR. I suspect it doesn't (based on the upload statements in the output you posted).

You need to post your pom.xml so that we can see how the EAR file is being built.\

Or are you saying that you are using an Ant script to build the EAR and then attempting to use a Maven POM to upload the EAR to Nexus? If that is what you are doing, then besides posting the POM you'll also have to tell us where in the project directory the EAR is located. Basically, you'll have tov register the EAR as the build artifact, and then Maven will upload it correctly. But we need to see the pom.xml and the project relative path of the EAR.
 
machines help you to do more, but experience less. Experience this tiny ad:
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
    Bookmark Topic Watch Topic
  • New Topic