• 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

problem with mvn deploy

 
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I was going through the maven tutorial in apache site, maven in 5 minutes
I created a project 'my-app' using the command:
mvn archetype:create -DgroupId=com.mycompany.app -DartifactId=my-app

I packaged it using the command : mvn package. The result showed BUILD SUCCESSFUL.

When I try to deploy it using : mvn deploy, it throws an exception, which is given below:


The pom.xml file is like below:




I know the <distributionManagement> tag information i provided is wrong, especially the <url>. I don't know what should be value.

Can anybody help me with it?

Thanks in advance,
Teena
 
author
Posts: 3285
13
Mac OS X Eclipse IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Well, that depends where you are trying to deploy it to!
 
Teena Mariam
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Martijn,
Thank you. But I didn't get your point.
I don't know the values to be given to the repository and snapshotRepository elements.
IS the url the location of the .jar file?

Regards,
Teena

 
Martijn Verburg
author
Posts: 3285
13
Mac OS X Eclipse IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Teena,

See the documentation Here basically it is specifynig where you are going to upload your artifact to, e.g. a local maven repository (Nexus, Artifactory etc) or perhaps a hosted repository out there on the internet (e.g. Central)
 
Teena Mariam
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks. I added distributionManagement and gave the url after checking settings.xml.
My settings.xml


My pom.xml now :

When i package it it shows build succesful. when i try to deploy it throws error with return code 405.
The error is :


What is it that I am doing wrong?

Thanks,
Teena
 
Martijn Verburg
author
Posts: 3285
13
Mac OS X Eclipse IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You'll need to talk to the people who run the Jboss repository, it'll be limited as to who can upload what. In general you won't need to upload artifacts to an external repo like this unless you are at the stage where your code is ready to share with hte world. For a more localised sharing you'll want to install something like Nexus or Artifactory, you then upload your artifacts to them and that can be shared across your local network etc.
 
Teena Mariam
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Okay, I got it. Thanks Martijn. My choice is Nexus.
Let me implement it and see if it works.

Thanks,
Teena
 
Martijn Verburg
author
Posts: 3285
13
Mac OS X Eclipse IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
No problems, Nexus is fairly popular so you'll be able to find assistance out there for it.
reply
    Bookmark Topic Watch Topic
  • New Topic