Post new topic   Reply to topic
Author Message
ed4becky
Registered Member
Registered Member
Joined: Mar 01, 2005
Posts: 41

Since upgrading to 8.5 (and several variations thereof) when my team tries to create a Maven project using a custom archtype, the rults are:

File->New->Other->Maven Project
1st screen: leave defaults
2nd screen: select one of three custom archtypes that used to work fine
3rd screen: add an ArtifactId and select Finish

Failed to create project.
java.lang.NullPointerException

Anyone know what changed?

tried it with Version: 8.5
Build id: 8.5-20100319
Code:

!ENTRY org.maven.ide.eclipse 4 0 2010-05-25 12:55:03.471
!MESSAGE Failed to create project.
!STACK 0
java.lang.NullPointerException
   at org.apache.maven.artifact.repository.DefaultArtifactRepositoryFactory.createArtifactRepository(DefaultArtifactRepositoryFactory.java:90)
   at org.maven.ide.eclipse.internal.project.ProjectConfigurationManager.resolveArchetype(ProjectConfigurationManager.java:540)
   at org.maven.ide.eclipse.internal.project.ProjectConfigurationManager.createArchetypeProject(ProjectConfigurationManager.java:463)
   at org.maven.ide.eclipse.wizards.MavenProjectWizard$5.runInWorkspace(MavenProjectWizard.java:279)
   at org.eclipse.core.internal.resources.InternalWorkspaceJob.run(InternalWorkspaceJob.java:38)
   at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)

_________________
Edward Thompson
Matthews, NC
 
 View user's profile Send private message  
Reply with quote Back to top
support-chakri
Registered Member
Registered Member
Joined: Apr 05, 2010
Posts: 68

Hi Edward Thompson,

I could not able to replicate the issue.
1) I tried creating Java Maven Project using default values when Project name is given.
2) Tried creating project with a different Artifact Id other than project name.

Can you send a screen shot of the when you are getting the error. Also, can you try the below steps:

3) Are the check boxes in Maven preference page checked adjacent to "Download Repository index updates on startup", "Download Artifacts Sources" and "Download Artifact Javadoc". Maven preference page is available at "Windows-->Preference-->MyEclipse-->Maven4MyEclipse-->Maven" and select Maven. If not, can you check them and try creating a web project with Maven support? This may take few minutes to download Maven repository which depends on the Internet band width.

Thanks,
Chakri Vedula.
 
 View user's profile Send private message  
Reply with quote Back to top
ed4becky
Registered Member
Registered Member
Joined: Mar 01, 2005
Posts: 41

I can't see how to attach a file to the post.

For #3, the first as already checked. I checked the other two, restarted MyEclipse, and tried again, same problem

As a side note, running mvn archetype:generate from the commandline generates no errors, so its something the plugin doesn't like...

_________________
Edward Thompson
Matthews, NC
 
 View user's profile Send private message  
Reply with quote Back to top
support-chakri
Registered Member
Registered Member
Joined: Apr 05, 2010
Posts: 68

Hi Edward Thompson,

Sorry for the inconvenience. I have escalated this to our Dev team member, they will get back to you on this.

Thanks,
Chakri Vedula.
 
 View user's profile Send private message  
Reply with quote Back to top
jdaggs
Registered Member
Registered Member
Joined: Aug 12, 2006
Posts: 6

FWIW, I am experiencing the same exact problem when trying to create a maven project with a custom archetype. Is there any update for this issue?
 
 View user's profile Send private message  
Reply with quote Back to top
Support-Brian
Moderator
Moderator
Joined: Aug 21, 2004
Posts: 2682

1) How are you specifying the custom archetype, I suppose you have added it using the "Add Archetype" dialog on page 2?

2) Are you using an existing workspace which you used with a prior version of MyEclipse? If so - just to test, can you try this in a brand new workspace?

3) Can you create a normal web project (and enable maven support on page 1 of the wizard) - Does project creation complete successfully? do you see any errors in the project?

_________________
Brian
MyEclipse Support
 
 View user's profile Send private message Visit poster's website  
Reply with quote Back to top
Mulder8472

Joined: Jul 21, 2009
Posts: 15

I am running:
Version: 8.6.1 Blue
Build id: 8.6.1-Blue-20101117

and I get the same error message. Has this been fixed, or at least been confirmed as a bug? is there a workaround or is my custom archetype flawed? Though, it works when use the command line: mvn archetype:generate -D...
 
 View user's profile Send private message  
Reply with quote Back to top
Mulder8472

Joined: Jul 21, 2009
Posts: 15

FYI, I upgraded to
MyEclipse Blue Edition

Version: 9.1 Blue
Build id: 9.1-Blue-20110701

and still get the same error.
 
 View user's profile Send private message  
Reply with quote Back to top
Mulder8472

Joined: Jul 21, 2009
Posts: 15

triple post... yeah/sorry

found this:
http://www.mygrid.org.uk/dev/wiki/display/developer/1.+Create+project+from+archetype

scroll down to "Failed to create project". Seems to be a bug with m2eclipse plugin 0.10.0 but has been fixed in 0.10.2. any chance maven4myeclipse is based on m2eclipse 0.10.0?
 
 View user's profile Send private message  
Reply with quote Back to top
support-swapna

Joined: Nov 11, 2010
Posts: 2743

Mulder8472 ,

Sorry that you are seeing this issue.

1) Are you adding the custom archetype using the 'Add Archetype' in dialog 2 ?

2) Can you please let us know if you have checked on the suggestions by Support-Brain?

I have also escalated this to a dev team member to investigate further. Sorry for the inconvenience caused.

_________________
Swapna
MyEclipse Support
 
 View user's profile Send private message  
Reply with quote Back to top
Mulder8472

Joined: Jul 21, 2009
Posts: 15

thx for your help

1) no, I am using a remote catalog. We use Archiva Maven Repository in our company whic also hosts the archetype catalog.

2) yes
 
 View user's profile Send private message  
Reply with quote Back to top
support-swapna

Joined: Nov 11, 2010
Posts: 2743

Mulder8472 ,

Thank you for the details.I could replicate the issue at my end. I will file a PR for the dev team to look into it.

_________________
Swapna
MyEclipse Support
 
 View user's profile Send private message  
Reply with quote Back to top
Mulder8472

Joined: Jul 21, 2009
Posts: 15

great news, thank you! how can I be informed when a fix is available? do you sue JIRA or similar?
 
 View user's profile Send private message  
Reply with quote Back to top
All times are GMT - 6 Hours
Post new topic   Reply to topic
® 2014 - Genuitec, LLC.