I am having trouble to get the LYO OSLC workshop running. In Lab1, I cannot run the project through maven. Please give me some input.
Software:
Windows 8.1 64bit
Java 8
Eclipse Luna Service Release 1a (4.4.1)
M2E - Maven integration fer Eclipse 1.5.0.20140606-0033
EGit 3.6.2.201501210735-r
those should be the most important ones.
I followed the ..\org.eclipse.lyo.docs\Lab1\Lyo_OSLC_Workshop.pdf workshop [you can find it on the Lyo Eclipse website in OSLCWorkshop under "Getting started with the Workshop"] until page 10. When clicking "run" I get the following errors:
[INFO] Scanning for projects...
[WARNING]
[WARNING] Some problems were encountered while building the effective model for org.eclipse.lyo.oslc4j.rio:oslc4j-bugzilla-sample-lab1:war:0.0.1-SNAPSHOT
[WARNING] 'build.plugins.plugin.version' for org.mortbay.jetty:jetty-maven-plugin is missing. @ line 91, column 11
[WARNING]
[WARNING] It is highly recommended to fix these problems because they threaten the stability of your build.
[WARNING]
[WARNING] For this reason, future Maven versions might no longer support building such malformed projects.
[WARNING]
[INFO]
[INFO] Using the builder org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder with a thread count of 1
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building oslc4j-bugzilla-sample-lab1 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] >>> jetty-maven-plugin:8.1.16.v20140903:run (default-cli) @ oslc4j-bugzilla-sample-lab1 >>>
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.517 s
[INFO] Finished at: 2015-01-25T17:44:24+01:00
[INFO] Final Memory: 7M/243M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project oslc4j-bugzilla-sample-lab1: Could not resolve dependencies for project org.eclipse.lyo.oslc4j.rio:oslc4j-bugzilla-sample-lab1:war:0.0.1-SNAPSHOT: Failed to collect dependencies at org.eclipse.lyo.server:oauth-webapp:war:[0.0.1-SNAPSHOT,): No versions available for org.eclipse.lyo.server:oauth-webapp:war:[0.0.1-SNAPSHOT,) within specified range -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] cwiki.apache.org/confluence/display/MAVEN/DependencyResolutionException
I read here stackoverflow.com/questions/10426557/missing-maven-plugin-jetty to have to change pom.xml. the original settings were:
<build>
<finalName>oslc4j-bugzilla-sample</finalName>
<plugins>
<plugin>
<groupId>org.mortbay.jetty</groupId>
<artifactId>jetty-maven-plugin</artifactId>
<!-- <version>7.3.0.v20110203</version> -->
now I have it this way:
<build>
<finalName>oslc4j-bugzilla-sample</finalName>
<plugins>
<plugin>
<groupId>org.mortbay.jetty</groupId>
<artifactId>mvn org.mortbay.jetty:jetty-maven-plugin:run</artifactId>
<version>9.2.7.v20150116</version>
The version corresponds to C:\Users\munk\Downloads\jetty-distribution-9.2.7.v20150116\jetty-distribution-9.2.7.v20150116\demo-base where I can start the web server from.
When I "run" again I get this output:
[INFO] Scanning for projects...
[WARNING] Failed to normalize pathname for lock on C:\Users\munk\.m2\repository\.locks\org.mortbay.jetty~mvn org.mortbay.jetty:jetty-maven-plugin:run~9.2.7.v20150116: java.io.IOException: Die Syntax für den Dateinamen, Verzeichnisnamen oder die Datenträgerbezeichnung ist falsch
[WARNING] Failed to lock file C:\Users\munk\.m2\repository\.locks\org.mortbay.jetty~mvn org.mortbay.jetty:jetty-maven-plugin:run~9.2.7.v20150116: java.io.FileNotFoundException: C:\Users\munk\.m2\repository\.locks\org.mortbay.jetty~mvn org.mortbay.jetty:jetty-maven-plugin:run~9.2.7.v20150116.aetherlock (Die Syntax für den Dateinamen, Verzeichnisnamen oder die Datenträgerbezeichnung ist falsch)
[WARNING] Failed to canonicalize path C:\Users\munk\.m2\repository\org\mortbay\jetty\mvn org.mortbay.jetty:jetty-maven-plugin:run\9.2.7.v20150116\mvn org.mortbay.jetty:jetty-maven-plugin:run-9.2.7.v20150116.pom.lastUpdated: Die Syntax für den Dateinamen, Verzeichnisnamen oder die Datenträgerbezeichnung ist falsch
[INFO] Downloading: repo.maven.apache.org/maven2/org/mortbay/jetty/mvn org.mortbay.jetty:jetty-maven-plugin:run/9.2.7.v20150116/mvn org.mortbay.jetty:jetty-maven-plugin:run-9.2.7.v20150116.pom
[WARNING] Failed to canonicalize path C:\Users\munk\.m2\repository\org\mortbay\jetty\mvn org.mortbay.jetty:jetty-maven-plugin:run\9.2.7.v20150116\mvn org.mortbay.jetty:jetty-maven-plugin:run-9.2.7.v20150116.pom.lastUpdated: Die Syntax für den Dateinamen, Verzeichnisnamen oder die Datenträgerbezeichnung ist falsch
[WARNING] Failed to create parent directories for tracking file C:\Users\munk\.m2\repository\org\mortbay\jetty\mvn org.mortbay.jetty:jetty-maven-plugin:run\9.2.7.v20150116\mvn org.mortbay.jetty:jetty-maven-plugin:run-9.2.7.v20150116.pom.lastUpdated
[WARNING] Failed to retrieve plugin descriptor for org.mortbay.jetty:mvn org.mortbay.jetty:jetty-maven-plugin:run:9.2.7.v20150116: Plugin org.mortbay.jetty:mvn org.mortbay.jetty:jetty-maven-plugin:run:9.2.7.v20150116 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.mortbay.jetty:mvn org.mortbay.jetty:jetty-maven-plugin:run:jar:9.2.7.v20150116
[INFO] Downloading: repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-metadata.xml
[INFO] Downloading: repo.maven.apache.org/maven2/org/codehaus/mojo/maven-metadata.xml
[INFO] Downloaded: repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-metadata.xml (13 KB at 47.1 KB/sec)
[INFO] Downloaded: repo.maven.apache.org/maven2/org/codehaus/mojo/maven-metadata.xml (20 KB at 72.5 KB/sec)
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.733 s
[INFO] Finished at: 2015-01-25T17:09:15+01:00
[INFO] Final Memory: 10M/307M
[INFO] ------------------------------------------------------------------------
[ERROR] No plugin found for prefix 'jetty' in the current project and in the plugin groups [org.apache.maven.plugins, org.codehaus.mojo] available from the repositories [local (C:\Users\munk\.m2\repository), central (repo.maven.apache.org/maven2)] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] cwiki.apache.org/confluence/display/MAVEN/NoPluginFoundForPrefixException
The URL at tthe end does not exist and I cannot get through to build this Lab1 properly. As far as I understand it, the "jetty" plugin is part of Maven but I cannot find it inside maven, so what to do?
I guess now I have to tell Eclipse in the Eclipse runtime configuration "Run Configuration" where to find this jetty dir but I have no idea where exactly and how. It is not mentioned in the PDF file, nor in the other guides that I found so far. So please tell me what are my faults here, and how can I do it right?
Due to the rigid rules towards newbies here not posting more than 2 links I had to remove all http preambles from code. Please add them on your own if you need to follow the links. Thank you.