Hippo Forge Import Tool archetype issue

classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|

Hippo Forge Import Tool archetype issue

Rob Velseboer
After creating the import project according to the "Getting Started" page ( http://import-tool.forge.onehippo.org/getting-started.html ) I get this error when I run mvn clean install:

java.lang.NullPointerException: id can not be null
        at org.apache.maven.wagon.repository.Repository.<init>(Repository.java:81)
        at org.apache.maven.artifact.repository.DefaultArtifactRepository.<init>(DefaultArtifactRepository.java:70)
        at org.apache.maven.artifact.repository.DefaultArtifactRepositoryFactory.createDeploymentArtifactRepository(DefaultArtifactRepositoryFactory.java:44)
        at org.apache.maven.project.ProjectUtils.buildDeploymentArtifactRepository(ProjectUtils.java:80)
        at org.apache.maven.project.DefaultMavenProjectBuilder.processProjectLogic(DefaultMavenProjectBuilder.java:1029)
        at org.apache.maven.project.DefaultMavenProjectBuilder.buildInternal(DefaultMavenProjectBuilder.java:880)
        at org.apache.maven.project.DefaultMavenProjectBuilder.buildFromSourceFileInternal(DefaultMavenProjectBuilder.java:508)
        at org.apache.maven.project.DefaultMavenProjectBuilder.build(DefaultMavenProjectBuilder.java:200)
        at org.apache.maven.DefaultMaven.getProject(DefaultMaven.java:604)
        at org.apache.maven.DefaultMaven.collectProjects(DefaultMaven.java:487)
        at org.apache.maven.DefaultMaven.getProjects(DefaultMaven.java:391)
        at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:272)
        at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
        at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
        at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:601)
        at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
        at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
        at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
        at org.codehaus.classworlds.Launcher.main(Launcher.java:375)

I asked a colleague to generate the archetype on his workstation and he got the exact same thing.

How do I resolve this?

I heard that I may have to change my maven settings (but why and how?)

Thanks!

Rob
Reply | Threaded
Open this post in threaded view
|

Re: Hippo Forge Import Tool archetype issue

marijan milicevic
Hi Rob,
please check :"Obtaining the tool via maven repository" part on [1]...interesting part is the maven repository setup.
cheers
marijan



[1]
http://import-tool.forge.onehippo.org/internals.html




On 09/26/2012 01:30 PM, Rob Velseboer wrote:
After creating the import project according to the "Getting Started" page (
http://import-tool.forge.onehippo.org/getting-started.html ) I get this
error when I run mvn clean install: 

java.lang.NullPointerException: id can not be null 
        at
org.apache.maven.wagon.repository.Repository.<init>(Repository.java:81) 
        at
org.apache.maven.artifact.repository.DefaultArtifactRepository.<init>(DefaultArtifactRepository.java:70) 
        at
org.apache.maven.artifact.repository.DefaultArtifactRepositoryFactory.createDeploymentArtifactRepository(DefaultArtifactRepositoryFactory.java:44) 
        at
org.apache.maven.project.ProjectUtils.buildDeploymentArtifactRepository(ProjectUtils.java:80) 
        at
org.apache.maven.project.DefaultMavenProjectBuilder.processProjectLogic(DefaultMavenProjectBuilder.java:1029) 
        at
org.apache.maven.project.DefaultMavenProjectBuilder.buildInternal(DefaultMavenProjectBuilder.java:880) 
        at
org.apache.maven.project.DefaultMavenProjectBuilder.buildFromSourceFileInternal(DefaultMavenProjectBuilder.java:508) 
        at
org.apache.maven.project.DefaultMavenProjectBuilder.build(DefaultMavenProjectBuilder.java:200) 
        at org.apache.maven.DefaultMaven.getProject(DefaultMaven.java:604) 
        at
org.apache.maven.DefaultMaven.collectProjects(DefaultMaven.java:487) 
        at org.apache.maven.DefaultMaven.getProjects(DefaultMaven.java:391) 
        at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:272) 
        at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138) 
        at org.apache.maven.cli.MavenCli.main(MavenCli.java:362) 
        at
org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60) 
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 
        at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) 
        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) 
        at java.lang.reflect.Method.invoke(Method.java:601) 
        at
org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315) 
        at org.codehaus.classworlds.Launcher.launch(Launcher.java:255) 
        at
org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430) 
        at org.codehaus.classworlds.Launcher.main(Launcher.java:375) 

I asked a colleague to generate the archetype on his workstation and he got
the exact same thing. 

How do I resolve this?

I heard that I may have to change my maven settings (but why and how?)

Thanks!

Rob



--
View this message in context: http://hippo.2275632.n2.nabble.com/Hippo-Forge-Import-Tool-archetype-issue-tp7579364.html
Sent from the Hippo CMS 7 mailing list archive at Nabble.com.
_______________________________________________
Hippo-cms7-user mailing list and forums
http://www.onehippo.org/cms7/support/forums.html


_______________________________________________
Hippo-cms7-user mailing list and forums
http://www.onehippo.org/cms7/support/forums.html
Reply | Threaded
Open this post in threaded view
|

Re: Hippo Forge Import Tool archetype issue

Rob Velseboer
Hi Marijan,

should I add this to the pom of the created import-tool archetype? I did that and it does not seem to make a difference.

I understand from the documentation that the import tool is supposed to be a separate web application, so I guess I should not include it in the scope of the regular cms/repository project? (based on the diagram on http://import-tool.forge.onehippo.org/appstructure.html)

Sorry, I just don't get it.

regards,

Rob
Reply | Threaded
Open this post in threaded view
|

Re: Hippo Forge Import Tool archetype issue

marijan milicevic
Hi Rob,
On 09/26/2012 03:02 PM, Rob Velseboer wrote:
Hi Marijan,

should I add this to the pom of the created import-tool archetype? I did
that and it does not seem to make a difference.

I understand from the documentation that the import tool is supposed to be a
separate web application, so I guess I should not include it in the scope of
the regular cms/repository project? (based on the diagram on
http://import-tool.forge.onehippo.org/appstructure.html) 

Sorry, I just don't get it. 

can you explain at which point are you getting above mentioned error?

please also see:
http://jira.codehaus.org/browse/WAGON-285

cheers
marijan






regards,

Rob




--
View this message in context: http://hippo.2275632.n2.nabble.com/Hippo-Forge-Import-Tool-archetype-issue-tp7579364p7579366.html
Sent from the Hippo CMS 7 mailing list archive at Nabble.com.
_______________________________________________
Hippo-cms7-user mailing list and forums
http://www.onehippo.org/cms7/support/forums.html


_______________________________________________
Hippo-cms7-user mailing list and forums
http://www.onehippo.org/cms7/support/forums.html
Reply | Threaded
Open this post in threaded view
|

Re: Hippo Forge Import Tool archetype issue

Rob Velseboer
Hi Marijan,

I get this error as soon as I do anything with mvn at the project root of the import tool. Even a simple 'mvn clean' will trigger this error.

I followed the steps in the "Getting started" page, creating the archetype (tried 1.04.01 as in the example, but also tried with 1.04.03). I answer the questions that are prompted and I get a resulting project folder which looks alright to me.  Inside that folder, I wanted to do a 'mvn clean install' but within one second it ends with this stacktrace.

I looked at the pom inside the created project and added the repository there (as you suggested) but this does not help either.

I googled the error earlier and found that jira ticket (WAGON-285) as well, but it did not help me because I simply do not understand what is wrong with the project (or my maven settings). Something with a missing id or url for  repository, but what repository? As I said the pom looks fine to me.

Thanks,

Rob
Reply | Threaded
Open this post in threaded view
|

Re: Hippo Forge Import Tool archetype issue

marijan milicevic
On 09/26/2012 04:42 PM, Rob Velseboer wrote:
Hi Marijan,

I get this error as soon as I do anything with mvn at the project root of
the import tool. Even a simple 'mvn clean' will trigger this error.

I followed the steps in the "Getting started" page, creating the archetype
(tried 1.04.01 as in the example, but also tried with 1.04.03). I answer the
questions that are prompted and I get a resulting project folder which looks
alright to me.  Inside that folder, I wanted to do a 'mvn clean install' but
within one second it ends with this stacktrace. 

I looked at the pom inside the created project and added the repository
there (as you suggested) but this does not help either.

I googled the error earlier and found that jira ticket (WAGON-285) as well,
but it did not help me because I simply do not understand what is wrong with
the project (or my maven settings). Something with a missing id or url for 
repository, but what repository? As I said the pom looks fine to me. 

"but what repository? "

maven repository...for example:

<repository>
  <id>hippo-forge</id>
  <name>Hippo Forge maven 2 repository.</name>
  <snapshots>
    <enabled>false</enabled>
  </snapshots>
  <releases>
    <updatePolicy>never</updatePolicy>
  </releases>
  <layout>default</layout>
</repository>
       


 
Check if your pom files  or ~.m2/settings.xml contain any repositories which are missing url or id values.

cheers,
marijan


Thanks,

Rob



--
View this message in context: http://hippo.2275632.n2.nabble.com/Hippo-Forge-Import-Tool-archetype-issue-tp7579364p7579371.html
Sent from the Hippo CMS 7 mailing list archive at Nabble.com.
_______________________________________________
Hippo-cms7-user mailing list and forums
http://www.onehippo.org/cms7/support/forums.html



_______________________________________________
Hippo-cms7-user mailing list and forums
http://www.onehippo.org/cms7/support/forums.html
Reply | Threaded
Open this post in threaded view
|

Re: Hippo Forge Import Tool archetype issue

Rob Velseboer
Hi,

found it!

I compared the import project with a regular hippo project and I found out that in the root pom the section

    <distributionManagement>
        <repository>
        </repository>
        <snapshotRepository>
        </snapshotRepository>
    </distributionManagement>

was different! I had been looking at the wrong repositories the whole time. After changing it to

    <distributionManagement>
        <repository>
            <id />
            <url />
        </repository>
        <snapshotRepository>
            <id />
            <url />
        </snapshotRepository>
    </distributionManagement>

the problem was gone.

Don't know if this can be changed in the archetype so future users will not encounter this issue?

Anyway, thanks for your assistance!

Rob
Reply | Threaded
Open this post in threaded view
|

Re: Hippo Forge Import Tool archetype issue

Mickaël Tricot
Hi,

An ever better "hack" is:

<distributionManagement>
  <repository>
    <id>-</id>
    <url>-</url>
  </repository>
  <snapshotRepository>
    <id>-</id>
    <url>-</url>
  </snapshotRepository>
</distributionManagement>

See https://issues.onehippo.com/browse/ARCHE-205

Cheers,
Mickaël

_______________________________________________
Hippo-cms7-user mailing list and forums
http://www.onehippo.org/cms7/support/forums.html
Reply | Threaded
Open this post in threaded view
|

Re: Hippo Forge Import Tool archetype issue

Woonsan Ko-3
Merci beaucoup!
I've created a JIRA issue for this:
https://issues.onehippo.com/browse/HIPPLUG-503

Cheers,

Woonsan

On 9/26/12 11:36 AM, Mickaël Tricot wrote:

> Hi,
>
> An ever better "hack" is:
>
> <distributionManagement>
>    <repository>
>      <id>-</id>
>      <url>-</url>
>    </repository>
>    <snapshotRepository>
>      <id>-</id>
>      <url>-</url>
>    </snapshotRepository>
> </distributionManagement>
>
> See https://issues.onehippo.com/browse/ARCHE-205
>
> Cheers,
> Mickaël
>
>
> _______________________________________________
> Hippo-cms7-user mailing list and forums
> http://www.onehippo.org/cms7/support/forums.html
>


--
[hidden email]     www.onehippo.com
Boston - 1 Broadway, Cambridge, MA 02142
Amsterdam - Oosteinde 11, 1017 WT Amsterdam
US +1 877 414 4776 (toll free)
Europe +31(0)20 522 4466
_______________________________________________
Hippo-cms7-user mailing list and forums
http://www.onehippo.org/cms7/support/forums.html