Page 1 of 1

Error while perform maven install

Posted: Tue May 29, 2012 5:01 am
by ericncc
Hi, I am newbie to broadleaf commerce.
I'm trying to setup the project in my laptop by follow the Getting Start guideline.
I manage to download the project from eclipes but i getting below error when i run maven install.
Can anyone help me to clarify with the error i get? thanks in advance.

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.0.2:compile (default-compile) on project admin: Compilation failure
[ERROR] error: error reading C:\Documents and Settings\Eric\.m2\repository\org\broadleafcommerce\broadleaf-open-admin-platform\1.5.4-GA\broadleaf-open-admin-platform-1.5.4-GA.jar; error in opening zip file
[ERROR] -> [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] http://cwiki.apache.org/confluence/disp ... eException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR] mvn <goals> -rf :admin

Re: Error while perform maven install

Posted: Tue May 29, 2012 5:25 am
by aniem
Hi ericncc,

I don't have an explanation for your problem, but it seems you're using an old version (1.5.4). Is it an option to try the current version (1.6.0)?

If yes, be sure to checkout the 1.6 documentation as the 1.5 version is still available in the Wiki.

Regards,
Alex

Re: Error while perform maven install

Posted: Tue May 29, 2012 5:37 am
by ericncc
I've follow the wiki guideline on 1.6 and has follow the instruction to create project under eclipes(indigo).
http://wiki.broadleafcommerce.org/confl ... or+Eclipse

Broadleaf archetype has only detect version 1.5.1-GA (as shown in the instruction).
Please guide to download the latest version 1.6. Thanks!

Re: Error while perform maven install

Posted: Tue May 29, 2012 6:31 am
by aniem
The screenshot in the instructions is outdated. The list of archetypes should show 1.6.0-GA as latest version.

I guess that Eclipse uses a archetype catalog which only contains the old version. Maybe a company repository installed at your site? You could check Preferences / Maven / Archetypes and see if there are any individual catalogs configured. In my case I only see the fix ones: Nexus Indexer, Internal and Default Local. If you don't have additonal ones it could still be that there's a mirror defined in /path/to/your/homedir/.m2/settings.xml, which doesn't contain the current version. A list of automatically synced mirrors can be found here:http://docs.codehaus.org/display/MAVENUSER/Mirrors+Repositories.

Regards,
Alex

Re: Error while perform maven install

Posted: Wed May 30, 2012 2:00 am
by ericncc
Thanks alex for the guideline.

I've check my eclipes maven architypes, it seems the same like yours which has only Nexus Indexer, Internal and Default Local.

I don't have settings.xml in my homedir so i've created 1 by following the below reply
viewtopic.php?f=14&t=567&p=1685&hilit=settings.xml&sid=5f3dda7e18c7101ba6e257eecad892e6#p1685

I've even change the settings.xml file to point to the France mirror. The eclipes then perform reindex of repository from the france mirror site after restart.
But I still have no luck, now my eclipes was not able to return broadleafcommerce Archetype, not even the older version.
What else I can do?

Re: Error while perform maven install

Posted: Wed May 30, 2012 6:28 am
by skip
Looks like the broadleaf-open-admin-platform-1.5.4-GA.jar file in your local repository got corrupted somehow.
You could delete it from your repository and try the mvn install again.

In case you still happen to have problems could you try Instructions for using the command line for 1.6.0-GA?

And then when everything seem to be working alright you could import the project to your Eclipse IDE.

Re: Error while perform maven install

Posted: Wed May 30, 2012 12:44 pm
by aniem
ericncc wrote:I don't have settings.xml in my homedir so i've created 1 by following the below reply
viewtopic.php?f=14&t=567&p=1685&hilit=settings.xml&sid=5f3dda7e18c7101ba6e257eecad892e6#p1685

I've even change the settings.xml file to point to the France mirror. The eclipes then perform reindex of repository from the france mirror site after restart.
But I still have no luck, now my eclipes was not able to return broadleafcommerce Archetype, not even the older version.


Since that post I switched to the UK mirror successfully. During my first try Eclipse didn't show me the archetype in the UK mirror, so I used the french one. Later it did. Can't tell you why, maybe because I created a new workspace? Or it was just randomly?

I'm a bit lost now. My next try would be to follow skip's advice to give the command line a chance, to eliminate Eclipse as possible problem within your setting. I bumbled through a lot of strange Maven-related behaviour of Eclipse (and some other things like stopping the HSQL DB via ant which sometimes work and sometimes don't - but that's a different drama). So it's worth a try in this case also, I think.

An additional chance is to delete all your local Maven caches to start over again from a clean starting point.

Re: Error while perform maven install

Posted: Thu May 31, 2012 8:13 pm
by ericncc
Thanks Skip and Aniem for the advise. I will try for the command line approach. Will keep my post on my outcome.