You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Vadim Gritsenko <va...@reverycodes.com> on 2008/11/04 18:18:10 UTC

Cocoon 3 trunk

Hi All,

Trying out cocoon 3 trunk, found following issues:

* Demo starts on port 8888, not the 8190 as stated in README;

* Demo's not working. http://localhost:8888/ results in error:
   404 Resource Not Available (Cocoon 3 Integration Tests)

* Project generated by mvn idea:idea is not correct - paths to modules  
is incorrect


Any ideas how to get a working sample?

Vadim

[cocoon3] Added a root POM

Posted by Reinhard Pötz <re...@apache.org>.
Reinhard Pötz wrote:
> Vadim Gritsenko wrote:
>> On Nov 5, 2008, at 2:55 AM, Reinhard Pötz wrote:
>>
>>> Steven Dolg wrote:
>>>> If everything fails moving the pom might be an option. Would that
>>>> produce a valid project file with your setup?
>>> If that solves the problem with IDEA, we can (re)introduce the root pom.
>>> Actually I also have problems with creating releases because the Maven
>>> release plugin doesn't support flat scenarios (although recommended by
>>> Maven AFAIU).
>>>
>>> Vadim, you can use cocoon3/trunk/release.pom.xml and rename it to
>>> pom.xml. Then go to parent/pom.xml and remove the <modules> section from
>>> there. Then invoke all mvn commands from cocoon3/trunk instead of
>>> cocoon3/trunk/parent.
>> Works beautifully!
>>
>> Why not to have pom in root of the project? It seems to be the most
>> obvious thing to do, to run mvn from root of the project.
> 
> Because if you have one Eclipse project for one Maven module, then you
> can't create a project for the root pom anymore. But if that solves your
> problem (and because of the release plugin quirks) I think we should
> reintroduce the root pom.

I added a minimal root POM but left as many settings as possible in the
parent POM. HTH

-- 
Reinhard Pötz                           Managing Director, {Indoqa} GmbH
                         http://www.indoqa.com/en/people/reinhard.poetz/

Member of the Apache Software Foundation
Apache Cocoon Committer, PMC member                  reinhard@apache.org
________________________________________________________________________

Re: Cocoon 3 trunk

Posted by Reinhard Pötz <re...@apache.org>.
Vadim Gritsenko wrote:
> On Nov 5, 2008, at 2:55 AM, Reinhard Pötz wrote:
> 
>> Steven Dolg wrote:
>>> If everything fails moving the pom might be an option. Would that
>>> produce a valid project file with your setup?
>>
>> If that solves the problem with IDEA, we can (re)introduce the root pom.
>> Actually I also have problems with creating releases because the Maven
>> release plugin doesn't support flat scenarios (although recommended by
>> Maven AFAIU).
>>
>> Vadim, you can use cocoon3/trunk/release.pom.xml and rename it to
>> pom.xml. Then go to parent/pom.xml and remove the <modules> section from
>> there. Then invoke all mvn commands from cocoon3/trunk instead of
>> cocoon3/trunk/parent.
> 
> Works beautifully!
> 
> Why not to have pom in root of the project? It seems to be the most
> obvious thing to do, to run mvn from root of the project.

Because if you have one Eclipse project for one Maven module, then you
can't create a project for the root pom anymore. But if that solves your
problem (and because of the release plugin quirks) I think we should
reintroduce the root pom.

-- 
Reinhard Pötz                           Managing Director, {Indoqa} GmbH
                         http://www.indoqa.com/en/people/reinhard.poetz/

Member of the Apache Software Foundation
Apache Cocoon Committer, PMC member                  reinhard@apache.org
________________________________________________________________________

Re: Cocoon 3 trunk

Posted by Vadim Gritsenko <va...@reverycodes.com>.
On Nov 5, 2008, at 2:55 AM, Reinhard Pötz wrote:

> Steven Dolg wrote:
>> If everything fails moving the pom might be an option. Would that
>> produce a valid project file with your setup?
>
> If that solves the problem with IDEA, we can (re)introduce the root  
> pom.
> Actually I also have problems with creating releases because the Maven
> release plugin doesn't support flat scenarios (although recommended by
> Maven AFAIU).
>
> Vadim, you can use cocoon3/trunk/release.pom.xml and rename it to
> pom.xml. Then go to parent/pom.xml and remove the <modules> section  
> from
> there. Then invoke all mvn commands from cocoon3/trunk instead of
> cocoon3/trunk/parent.

Works beautifully!

Why not to have pom in root of the project? It seems to be the most  
obvious thing to do, to run mvn from root of the project.

Vadim

Re: Cocoon 3 trunk

Posted by Reinhard Pötz <re...@apache.org>.
Steven Dolg wrote:
> Vadim Gritsenko schrieb:
>> On Nov 4, 2008, at 3:13 PM, Steven Dolg wrote:
>>
>>> Hi Vadim,
>>>
>>> the port stated in the README is unfortunately wrong.
>>>
>>> However the demo is working correctly for me
>>
>> After a bit of poking around I figured out it was caused by a firefox
>> cache (it cached a redirect). After clearing the cache I can see
>> "Cocoon 3 Samples and Integration Tests: Overview" page.
>>
>>
>>> as well as the generated project for IDEA (I tried IDEA 7.0.4 with a
>>> JDK 1.6.0_06).
>>
>> It is not possible to generate a project file from cocoon-3 root
>> directory itself, and so the next closest thing which I found is to do
>> it in the ./parent directory. So, when running mvn idea:idea command
>> there, it creates incorrect cocoon-parent.ipr file:
>>
>>     <modules>
>>       <!-- module filepath="$$PROJECT_DIR$$/${pom.artifactId}.iml"/ -->
>>       <module filepath="$PROJECT_DIR$/cocoon-parent.iml"/>
>>       <module
>> filepath="$PROJECT_DIR$//Users/vgritsenko/Projects/Apache/cocoon-3/cocoon-all/cocoon-all.iml"/>
>>
>>       <module
>> filepath="$PROJECT_DIR$//Users/vgritsenko/Projects/Apache/cocoon-3/cocoon-controller/cocoon-controller.iml"/>
>>
>>
>> So it seems like idea plugin appends absolute file paths to the
>> $PROJECT_DIR$. I had to manually edit file so that it loads in IDEA.
>> It now reads:
>>
>>     <modules>
>>       <!-- module filepath="$$PROJECT_DIR$$/${pom.artifactId}.iml"/ -->
>>       <module filepath="$PROJECT_DIR$/cocoon-parent.iml"/>
>>       <module filepath="$PROJECT_DIR$/../cocoon-all/cocoon-all.iml"/>
>>       <module
>> filepath="$PROJECT_DIR$/../cocoon-controller/cocoon-controller.iml"/>
>>
>>
>> Short of hacking maven plugin, I think easiest way to fix that would
>> be to add a pom to cocoon-3 directory. WDYT?
> That is strange.
> When I generate the IDEA project files from the parent directory I get
> the following modules section:
> <component name="ProjectModuleManager">
>    <modules>
>      <!-- module filepath="$$PROJECT_DIR$$/${pom.artifactId}.iml"/ -->
>      <module filepath="$PROJECT_DIR$/cocoon-parent.iml"/>
>      <module filepath="$PROJECT_DIR$/../cocoon-all/cocoon-all.iml"/>
>      <module
> filepath="$PROJECT_DIR$/../cocoon-controller/cocoon-controller.iml"/>
>      <module
> filepath="$PROJECT_DIR$/../cocoon-optional/cocoon-optional.iml"/>
>      <module
> filepath="$PROJECT_DIR$/../cocoon-pipeline/cocoon-pipeline.iml"/>
>      <module filepath="$PROJECT_DIR$/../cocoon-rest/cocoon-rest.iml"/>
>      <module filepath="$PROJECT_DIR$/../cocoon-sample/cocoon-sample.iml"/>
>      <module
> filepath="$PROJECT_DIR$/../cocoon-servlet/cocoon-servlet.iml"/>
>      <module
> filepath="$PROJECT_DIR$/../cocoon-sitemap/cocoon-sitemap.iml"/>
>      <module
> filepath="$PROJECT_DIR$/../cocoon-stringtemplate/cocoon-stringtemplate.iml"/>
> 
>    </modules>
>  </component>
> After opening IDEA changes all that into absolute paths - but I guess
> this is all right (I have absolutely no experience with IDEA).
> 
> So the only thing I can image are different Maven and/or different
> idea-plugin versions.
> Mine are Maven 2.0.9 and maven-idea-plugin 2.2.
> 
> 
> If everything fails moving the pom might be an option. Would that
> produce a valid project file with your setup?

If that solves the problem with IDEA, we can (re)introduce the root pom.
Actually I also have problems with creating releases because the Maven
release plugin doesn't support flat scenarios (although recommended by
Maven AFAIU).

Vadim, you can use cocoon3/trunk/release.pom.xml and rename it to
pom.xml. Then go to parent/pom.xml and remove the <modules> section from
there. Then invoke all mvn commands from cocoon3/trunk instead of
cocoon3/trunk/parent.

HTH

Please let us know if that works for you! Thanks.

-- 
Reinhard Pötz                           Managing Director, {Indoqa} GmbH
                         http://www.indoqa.com/en/people/reinhard.poetz/

Member of the Apache Software Foundation
Apache Cocoon Committer, PMC member                  reinhard@apache.org
________________________________________________________________________

[cocoon3] Creating idea configuration

Posted by Reinhard Pötz <re...@apache.org>.
Vadim Gritsenko wrote:
> On Nov 5, 2008, at 12:11 PM, Steven Dolg wrote:
> 
>> Vadim Gritsenko schrieb:
>>> On Nov 5, 2008, at 1:18 AM, Steven Dolg wrote:
>>>> So the only thing I can image are different Maven and/or different
>>>> idea-plugin versions.
>>>> Mine are Maven 2.0.9 and maven-idea-plugin 2.2.
>>>
>>> I have 2.0 and 2.1 in
>>> ~/.m2/repository/org/apache/maven/plugins/maven-idea-plugin. Is that
>>> the right way to check the version? :)
>> I also looked for a more "sophisticated" way to determine that - but
>> was forced to look into my local repository. ;-)
>> Perhaps we should define it in the pom...
> 
> I found no way to update it... mvn --check-plugin-updates idea:idea does
> not do it...

I set the version of the maven-idea-plugin to 2.2 in the root POM. I
hope that this solves your problem.

-- 
Reinhard Pötz                           Managing Director, {Indoqa} GmbH
                         http://www.indoqa.com/en/people/reinhard.poetz/

Member of the Apache Software Foundation
Apache Cocoon Committer, PMC member                  reinhard@apache.org
________________________________________________________________________

Re: Cocoon 3 trunk

Posted by Vadim Gritsenko <va...@reverycodes.com>.
On Nov 5, 2008, at 12:11 PM, Steven Dolg wrote:

> Vadim Gritsenko schrieb:
>> On Nov 5, 2008, at 1:18 AM, Steven Dolg wrote:
>>> So the only thing I can image are different Maven and/or different  
>>> idea-plugin versions.
>>> Mine are Maven 2.0.9 and maven-idea-plugin 2.2.
>>
>> I have 2.0 and 2.1 in ~/.m2/repository/org/apache/maven/plugins/ 
>> maven-idea-plugin. Is that the right way to check the version? :)
> I also looked for a more "sophisticated" way to determine that - but  
> was forced to look into my local repository. ;-)
> Perhaps we should define it in the pom...

I found no way to update it... mvn --check-plugin-updates idea:idea  
does not do it...

Vadim

Re: Cocoon 3 trunk

Posted by Steven Dolg <st...@indoqa.com>.
Vadim Gritsenko schrieb:
> On Nov 5, 2008, at 1:18 AM, Steven Dolg wrote:
>> So the only thing I can image are different Maven and/or different 
>> idea-plugin versions.
>> Mine are Maven 2.0.9 and maven-idea-plugin 2.2.
>
> I have 2.0 and 2.1 in 
> ~/.m2/repository/org/apache/maven/plugins/maven-idea-plugin. Is that 
> the right way to check the version? :)
I also looked for a more "sophisticated" way to determine that - but was 
forced to look into my local repository. ;-)
Perhaps we should define it in the pom...
>
> Maven is 2.0.9 (I think older versions are prohibited anyway)
>
> Vadim
>


Re: Cocoon 3 trunk

Posted by Vadim Gritsenko <va...@reverycodes.com>.
On Nov 5, 2008, at 1:18 AM, Steven Dolg wrote:
> So the only thing I can image are different Maven and/or different  
> idea-plugin versions.
> Mine are Maven 2.0.9 and maven-idea-plugin 2.2.

I have 2.0 and 2.1 in ~/.m2/repository/org/apache/maven/plugins/maven- 
idea-plugin. Is that the right way to check the version? :)

Maven is 2.0.9 (I think older versions are prohibited anyway)

Vadim

Re: Cocoon 3 trunk

Posted by Steven Dolg <st...@indoqa.com>.
Vadim Gritsenko schrieb:
> On Nov 4, 2008, at 3:13 PM, Steven Dolg wrote:
>
>> Hi Vadim,
>>
>> the port stated in the README is unfortunately wrong.
>>
>> However the demo is working correctly for me
>
> After a bit of poking around I figured out it was caused by a firefox 
> cache (it cached a redirect). After clearing the cache I can see 
> "Cocoon 3 Samples and Integration Tests: Overview" page.
>
>
>> as well as the generated project for IDEA (I tried IDEA 7.0.4 with a 
>> JDK 1.6.0_06).
>
> It is not possible to generate a project file from cocoon-3 root 
> directory itself, and so the next closest thing which I found is to do 
> it in the ./parent directory. So, when running mvn idea:idea command 
> there, it creates incorrect cocoon-parent.ipr file:
>
>     <modules>
>       <!-- module filepath="$$PROJECT_DIR$$/${pom.artifactId}.iml"/ -->
>       <module filepath="$PROJECT_DIR$/cocoon-parent.iml"/>
>       <module 
> filepath="$PROJECT_DIR$//Users/vgritsenko/Projects/Apache/cocoon-3/cocoon-all/cocoon-all.iml"/> 
>
>       <module 
> filepath="$PROJECT_DIR$//Users/vgritsenko/Projects/Apache/cocoon-3/cocoon-controller/cocoon-controller.iml"/> 
>
>
> So it seems like idea plugin appends absolute file paths to the 
> $PROJECT_DIR$. I had to manually edit file so that it loads in IDEA. 
> It now reads:
>
>     <modules>
>       <!-- module filepath="$$PROJECT_DIR$$/${pom.artifactId}.iml"/ -->
>       <module filepath="$PROJECT_DIR$/cocoon-parent.iml"/>
>       <module filepath="$PROJECT_DIR$/../cocoon-all/cocoon-all.iml"/>
>       <module 
> filepath="$PROJECT_DIR$/../cocoon-controller/cocoon-controller.iml"/>
>
>
> Short of hacking maven plugin, I think easiest way to fix that would 
> be to add a pom to cocoon-3 directory. WDYT?
That is strange.
When I generate the IDEA project files from the parent directory I get 
the following modules section:
<component name="ProjectModuleManager">
    <modules>
      <!-- module filepath="$$PROJECT_DIR$$/${pom.artifactId}.iml"/ --> 
      <module filepath="$PROJECT_DIR$/cocoon-parent.iml"/>
      <module filepath="$PROJECT_DIR$/../cocoon-all/cocoon-all.iml"/>
      <module 
filepath="$PROJECT_DIR$/../cocoon-controller/cocoon-controller.iml"/>
      <module 
filepath="$PROJECT_DIR$/../cocoon-optional/cocoon-optional.iml"/>
      <module 
filepath="$PROJECT_DIR$/../cocoon-pipeline/cocoon-pipeline.iml"/>
      <module filepath="$PROJECT_DIR$/../cocoon-rest/cocoon-rest.iml"/>
      <module filepath="$PROJECT_DIR$/../cocoon-sample/cocoon-sample.iml"/>
      <module 
filepath="$PROJECT_DIR$/../cocoon-servlet/cocoon-servlet.iml"/>
      <module 
filepath="$PROJECT_DIR$/../cocoon-sitemap/cocoon-sitemap.iml"/>
      <module 
filepath="$PROJECT_DIR$/../cocoon-stringtemplate/cocoon-stringtemplate.iml"/>
    </modules>
  </component> 

After opening IDEA changes all that into absolute paths - but I guess 
this is all right (I have absolutely no experience with IDEA).

So the only thing I can image are different Maven and/or different 
idea-plugin versions.
Mine are Maven 2.0.9 and maven-idea-plugin 2.2.


If everything fails moving the pom might be an option. Would that 
produce a valid project file with your setup?

Steven

>
>
>> Could you provide me with more specific error messages - if available 
>> - in order to sort this out?
>
> Hope above helps,
>
> Thanks,
> Vadim
>
>
>> Steven
>>
>> Vadim Gritsenko schrieb:
>>> Hi All,
>>>
>>> Trying out cocoon 3 trunk, found following issues:
>>>
>>> * Demo starts on port 8888, not the 8190 as stated in README;
>>>
>>> * Demo's not working. http://localhost:8888/ results in error:
>>>  404 Resource Not Available (Cocoon 3 Integration Tests)
>>>
>>> * Project generated by mvn idea:idea is not correct - paths to 
>>> modules is incorrect
>>>
>>>
>>> Any ideas how to get a working sample?
>>>
>>> Vadim
>


Re: Cocoon 3 trunk

Posted by Vadim Gritsenko <va...@reverycodes.com>.
On Nov 4, 2008, at 3:13 PM, Steven Dolg wrote:

> Hi Vadim,
>
> the port stated in the README is unfortunately wrong.
>
> However the demo is working correctly for me

After a bit of poking around I figured out it was caused by a firefox  
cache (it cached a redirect). After clearing the cache I can see  
"Cocoon 3 Samples and Integration Tests: Overview" page.


> as well as the generated project for IDEA (I tried IDEA 7.0.4 with a  
> JDK 1.6.0_06).

It is not possible to generate a project file from cocoon-3 root  
directory itself, and so the next closest thing which I found is to do  
it in the ./parent directory. So, when running mvn idea:idea command  
there, it creates incorrect cocoon-parent.ipr file:

     <modules>
       <!-- module filepath="$$PROJECT_DIR$$/${pom.artifactId}.iml"/ -->
       <module filepath="$PROJECT_DIR$/cocoon-parent.iml"/>
       <module filepath="$PROJECT_DIR$//Users/vgritsenko/Projects/ 
Apache/cocoon-3/cocoon-all/cocoon-all.iml"/>
       <module filepath="$PROJECT_DIR$//Users/vgritsenko/Projects/ 
Apache/cocoon-3/cocoon-controller/cocoon-controller.iml"/>

So it seems like idea plugin appends absolute file paths to the  
$PROJECT_DIR$. I had to manually edit file so that it loads in IDEA.  
It now reads:

     <modules>
       <!-- module filepath="$$PROJECT_DIR$$/${pom.artifactId}.iml"/ -->
       <module filepath="$PROJECT_DIR$/cocoon-parent.iml"/>
       <module filepath="$PROJECT_DIR$/../cocoon-all/cocoon-all.iml"/>
       <module filepath="$PROJECT_DIR$/../cocoon-controller/cocoon- 
controller.iml"/>


Short of hacking maven plugin, I think easiest way to fix that would  
be to add a pom to cocoon-3 directory. WDYT?


> Could you provide me with more specific error messages - if  
> available - in order to sort this out?

Hope above helps,

Thanks,
Vadim


> Steven
>
> Vadim Gritsenko schrieb:
>> Hi All,
>>
>> Trying out cocoon 3 trunk, found following issues:
>>
>> * Demo starts on port 8888, not the 8190 as stated in README;
>>
>> * Demo's not working. http://localhost:8888/ results in error:
>>  404 Resource Not Available (Cocoon 3 Integration Tests)
>>
>> * Project generated by mvn idea:idea is not correct - paths to  
>> modules is incorrect
>>
>>
>> Any ideas how to get a working sample?
>>
>> Vadim


Re: Cocoon 3 trunk

Posted by Steven Dolg <st...@indoqa.com>.
Hi Vadim,

the port stated in the README is unfortunately wrong.

However the demo is working correctly for me as well as the generated 
project for IDEA (I tried IDEA 7.0.4 with a JDK 1.6.0_06).
Could you provide me with more specific error messages - if available - 
in order to sort this out?


Steven

Vadim Gritsenko schrieb:
> Hi All,
>
> Trying out cocoon 3 trunk, found following issues:
>
> * Demo starts on port 8888, not the 8190 as stated in README;
>
> * Demo's not working. http://localhost:8888/ results in error:
>   404 Resource Not Available (Cocoon 3 Integration Tests)
>
> * Project generated by mvn idea:idea is not correct - paths to modules 
> is incorrect
>
>
> Any ideas how to get a working sample?
>
> Vadim
>