![]() |
![]() |
|
Welcome
Guest
| Register
| Login
|
| Index | Recent Threads | Unanswered Threads | Who's Online | User List | Help |
|
|
| No member browsing this thread |
|
Thread Status: Active Total posts in this thread: 17
|
|
| Author |
|
|
Newbie Ireland Joined: Jan 26, 2008 Post Count: 6 Status: Offline |
I am currently trying to setup an Maven2 POM using the latest beta 5, version 1.2.0 of JPOX. But getting errors due to missing artifacts. The issue is with the POM files for the jpox version 1.2.0-beta-5 files checked into the Maven repository. There dependencies are incorrectly defined for the eclipse osgi dependencies. Yes, I know I can solve this issue be downloading these and installing them into my local repository, but that defeats the purpose of Maven, especially when these jar files are in a repository. It looks like your builds seems to work, which I can only think you are using Maven 1 maybe or that you have these eclipse osgi jar files defined into your local repository. Getting: 5 required artifacts are missing. from the specified remote repositories: from the specified remote repositories: ibiblio (http://mirrors.ibiblio.org/pub/mirrors/maven2), central (http://repo1.maven.org/maven2), eclipse (http://repo1.maven.org/eclipse), refractions (http://lists.refractions.net/m2/), datanucleus (http://www.datanucleus.org/downloads/maven2), jpox (http://www.jpox.org/downloads/maven2) errors like: Path to dependency: 1) org.dit:jpox-test1:jar:1.0 2) jpox:jpox-core:jar:1.2.0-beta-5 3) org.eclipse:org.eclipse.equinox.common:jar:3.2.0 I did some research and found that the dependencies are not defined correctly for the eclipse osgi dependencies. This is based on my investigation, but please correct me if I have gone wrong. Example: In jpox-core-1.2.0-beta-5.jar located at http://mirrors.ibiblio.org/pub/mirrors/maven2/jpox/jpox-core/1.2.0-beta-5/ has a POM file that Maven 2.0.9 will look at ensure that dependencies are resolved. For instance looking at the following dependency: This dependency can not be found. I did some digging around and found that this dependency requires repository eclipse (http://repo1.maven.org/eclipse), and within this repository the following dependency definition should be used to find the correct jar I have had a quick look at previous beta versions and find it strange that they all define these eclipse osgi dependencies like this. Is this a problem on my side or is it that no one is using Maven 2 or is it that people are installing these JAR files manually? I think all the eclipse osgi dependencies should be defined as follow: Regards, Francois Groenewald ---------------------------------------- -- Francois -- |
||
|
|
Newbie Ireland Joined: Jan 26, 2008 Post Count: 6 Status: Offline |
The issue still exist if I try and use the beta-5 version, but I have a work around by adding the nightly snapshot build as a LEGACY repository to my POM and then point to the version 2.1-SNAPSHOT, but for the JDO I had to be pointed to the 2.1 release version. Additional Repositories that I required: https://maven-repository.dev.java.net/repository/, was for the javax.transaction api version 1.1 ---------------------------------------- -- Francois -- |
||
|
|
Expert UK / España Joined: Mar 13, 2004 Post Count: 4882 Status: Offline |
using the latest beta 5, version 1.2.0 of JPOX. But the latest is not beta-5, nor is it 1.2.0, nor is it JPOX. JPOX development has finished. Also this particular forum (where you posted the issue) is for people developing DataNucleus, not for usage issues, so we have to assume that you are wanting to contribute code and build DataNucleus. Anyone building DataNucleus would have downloaded "local.repository" and would have no such build issues. The issue is with the POM files for the jpox version 1.2.0-beta-5 files checked into the Maven repository. By the "Maven repository" you presumably mean the central Maven repo that is nothing to do with us, nor where we advertise our jars. We provide our own Maven repo(s) - stated in the docs as Maven1 type, hence legacy. Maven1 doesn't support optional deps. Access Platform is provided with all required jars for running anyway. Eclipse jars were never in any public repo when we started using it so we provided a group id for them. Ok, some Maven person has (finally) bothered to put them in a repo now and chosen a different groupId to what we guessed. AccessPlatform 1.0 final will use this new groupId when it is released - thx for letting us know about it. As we've said for the last 4 yrs, if people want an M2 repo with our jars in it then they should contribute their time so that the full DataNucleus build process works using Maven2. It currently doesn't, e.g jdo.connector project doesnt create a rar, e.g some test projects don't have POMs. ---------------------------------------- -Andy ![]() ![]() |
||
|
|
Newbie Ireland Joined: Jan 26, 2008 Post Count: 6 Status: Offline |
Hi Andy, I am willing to contribute my time to getting DataNucleus Maven2 compliant. I have obtained the latest source code, but I will have to spend some time to familiarise myself a bit more with it. My goal would be to create Maven2 archtypes for DataNucleus to enable newcomers or experienced developers to quickly create new DataNucleus projects. Regards, Francois ---------------------------------------- -- Francois -- |
||
|
|
Advanced Member Germany Joined: Jun 18, 2004 Post Count: 405 Status: Offline |
If you want to build datanucleus itself using maven2, the docs on doing that most conveniently aren't up-to-date, unfortunately. In case you didn't figure out yourself already, there are two parent POMs now:
(yes we should settle for either "-" or "." in the names ;) If you do a "mvn clean install" of both in the given order, the platform and tests are built and installed. Precondition is a SVN checkout that preserves the directory structure in SVN (aka "deep checkout"). |
||
|
|
Newbie Ireland Joined: Jan 26, 2008 Post Count: 6 Status: Offline |
Thanks, I have started looking at these. Francois ---------------------------------------- -- Francois -- |
||
|
|
Novice USA Joined: Dec 15, 2007 Post Count: 31 Status: Offline |
Is there a convenient way to perform Maven2 builds of releases? Last time I looked at this, it seemed I'd have to go manually roll each project back to the appropriate "released" revision. Is there a simpler way? Thanks, Karl |
||
|
|
Advanced Member Germany Joined: Jun 18, 2004 Post Count: 405 Status: Offline |
I guess not. Alternatively, you could do a fresh checkout of the revision in question and build from there. |
||
|
|
Novice USA Joined: Dec 15, 2007 Post Count: 31 Status: Offline |
Yeah, I was actually looking to build the whole accessplatform. As I recall, each release of that isn't one revision, but rather a separate revision for each of the sub-projects. |
||
|
|
Expert UK / España Joined: Mar 13, 2004 Post Count: 4882 Status: Offline |
When someone finally provides a working M2 setup for DataNucleus they really ought to consider whether having a parent POM is of much use in these two places :- Plugin Development People developing DataNucleus are typically working on one plugin at a time, hence can build that plugin with a single command and no need for parentage. A shell script can provide whatever build automation is required. Use of parentage here complicates things because each plugin has its own lifecycle and hence its own space in SVN. When you branch plugin X then its source resides under pluginX/branches/{version}/ yet trunk for the plugin is at pluginX/trunk/ so the use of relativePath in the parent and plugin POMs don't work. Also dependencies are on a plugin-by-plugin basis, so no benefit from having a parent POM. Conclusion thus far : strip out parentage for plugins Testing People want to run all tests (in general). In this situation parentage can be useful since it would trigger the run of all tests, and the dependencies across the test projects are similar. In terms of SVN, all test scenarios are in the same part of SVN so when they are branched the parent POM is branched in the same area so relativePaths work still. Conclusion : leave parentage as is Comments ? ---------------------------------------- -Andy ![]() ![]() |
||
|
|
|
|
|
Current timezone is GMT Dec 3, 2008 1:17:07 AM |