Remi.Masson.EXT | 1 Feb 2010 15:49
Picon

How to deploy Cocoon 2.2 ’s project on Weblogic 10.3?


Hello,


I use cocoon 2.2 on my current project.
But when I’m deploying the war file on weblogic 10.3, the server throws this error :
javax.servlet.ServletException: org.apache.cocoon.servlet.ParanoidCocoonServlet
cannot run in an undeployed WAR file
at org.apache.cocoon.servlet.ParanoidCocoonServlet.getContextDir(ParanoidCocoonServlet.java:154)
at org.apache.cocoon.servlet.ParanoidCocoonServlet.init(ParanoidCocoonServlet.java:91)

Anyone has already had this error? Any ideas?


BR

Rémi
Gary Browne | 2 Feb 2010 00:30
Picon
Favicon

2.2 installation help

Hello,

I'm having trouble installing Cocoon 2.2 using Maven. Please see attached install log.

Any advice would be much appreciated, I have spent hours on this!

Thanks
Gary

GARY BROWNE | Development Programmer 
Library IT Services | University Library
THE UNIVERSITY OF SYDNEY
Level 1, Fisher Library F03 | The University of Sydney | NSW | 2006
T +61 2 9351 5946  | F +61 2 9036 0000
E gary.browne <at> sydney.edu.au  | W http://sydney.edu.au 

Sent from my plain old desktop computer.

CRICOS 00026A
This email plus any attachments to it are confidential. Any unauthorised use is strictly prohibited. If
you receive this email in error, please delete it and any attachments.
Please think of our environment and only print this e-mail if necessary.

[root <at> blah anthologise]# mvn archetype:generate -DarchetypeCatalog=http://cocoon.apache.org

[INFO] Scanning for projects...
[INFO] Searching repository for plugin with prefix: 'archetype'.
[INFO] org.apache.maven.plugins: checking for updates from central
[WARNING] repository metadata for: 'org.apache.maven.plugins' could not be retrieved from
repository: central due to an error: Error transferring file: Connection timed out
[INFO] Repository 'central' will be blacklisted
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] The plugin 'org.apache.maven.plugins:maven-archetype-plugin' does not exist or no valid
version could be found
[INFO] ------------------------------------------------------------------------
[INFO] For more information, run Maven with the -e switch
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 3 minutes 21 seconds
[INFO] Finished at: Fri Oct 23 14:40:15 EST 2009
[INFO] Final Memory: 1M/3M
[INFO] ------------------------------------------



I then added settings.xml to /root/.m2 and it worked except:


Missing:
----------
1) org.apache.velocity:velocity:jar:1.5

  Try downloading the file manually from the project website.

  Then, install it using the command:
      mvn install:install-file -DgroupId=org.apache.velocity -DartifactId=velocity -Dversion=1.5
-Dpackaging=jar -Dfile=/path/to/file

  Alternatively, if you host your own repository you can deploy the file there:
      mvn deploy:deploy-file -DgroupId=org.apache.velocity -DartifactId=velocity -Dversion=1.5
-Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]

  Path to dependency:
        1) org.apache.maven.plugins:maven-archetype-plugin:maven-plugin:2.0-alpha-4
        2) org.apache.maven.archetype:archetype-common:jar:2.0-alpha-4
        3) org.apache.velocity:velocity:jar:1.5

2) dom4j:dom4j:jar:1.6.1

  Try downloading the file manually from the project website.

  Then, install it using the command:
      mvn install:install-file -DgroupId=dom4j -DartifactId=dom4j -Dversion=1.6.1 -Dpackaging=jar -Dfile=/path/to/file

  Alternatively, if you host your own repository you can deploy the file there:
      mvn deploy:deploy-file -DgroupId=dom4j -DartifactId=dom4j -Dversion=1.6.1 -Dpackaging=jar
-Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]

  Path to dependency:
        1) org.apache.maven.plugins:maven-archetype-plugin:maven-plugin:2.0-alpha-4
        2) org.apache.maven.archetype:archetype-common:jar:2.0-alpha-4
        3) dom4j:dom4j:jar:1.6.1

3) velocity:velocity-dep:jar:1.4

  Try downloading the file manually from the project website.

  Then, install it using the command:
      mvn install:install-file -DgroupId=velocity -DartifactId=velocity-dep -Dversion=1.4
-Dpackaging=jar -Dfile=/path/to/file

  Alternatively, if you host your own repository you can deploy the file there:
      mvn deploy:deploy-file -DgroupId=velocity -DartifactId=velocity-dep -Dversion=1.4
-Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]

  Path to dependency:
        1) org.apache.maven.plugins:maven-archetype-plugin:maven-plugin:2.0-alpha-4
        2) org.apache.maven.archetype:archetype-common:jar:2.0-alpha-4
        3) org.codehaus.plexus:plexus-velocity:jar:1.1.3
        4) velocity:velocity:jar:1.4
        5) velocity:velocity-dep:jar:1.4

----------
3 required artifacts are missing.

for artifact:
  org.apache.maven.plugins:maven-archetype-plugin:maven-plugin:2.0-alpha-4

from the specified remote repositories:
  central (http://repo1.maven.org/maven2),

  apache.snapshots (http://people.apache.org/repo/m2-snapshot-repository)




THIS WORKED, but then when running:

      mvn archetype:generate -DarchetypeCatalog=http://cocoon.apache.org

      
again, I get this new error:


[WARNING] Error reading archetype catalog http://cocoon.apache.org

java.lang.RuntimeException: java.lang.IllegalArgumentException: protocol = http host = null
        at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:919)

        at sun.net.www.protocol.http.HttpURLConnection.getHeaderField(HttpURLConnection.java:2019)

        at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:376)
        at org.apache.maven.wagon.providers.http.LightweightHttpWagon.fillInputData(LightweightHttpWagon.java:115)
        at org.apache.maven.wagon.StreamWagon.getInputStream(StreamWagon.java:116)
        at org.apache.maven.wagon.StreamWagon.getIfNewer(StreamWagon.java:88)
        at org.apache.maven.wagon.StreamWagon.get(StreamWagon.java:61)
        at org.apache.maven.archetype.source.RemoteCatalogArchetypeDataSource.getArchetypeCatalog(RemoteCatalogArchetypeDataSource.java:89)
        at org.apache.maven.archetype.DefaultArchetype.getRemoteCatalog(DefaultArchetype.java:197)
        at org.apache.maven.archetype.ui.DefaultArchetypeSelector.getArchetypesByCatalog(DefaultArchetypeSelector.java:283)
        at org.apache.maven.archetype.ui.DefaultArchetypeSelector.selectArchetype(DefaultArchetypeSelector.java:74)
        at org.apache.maven.archetype.mojos.CreateProjectFromArchetypeMojo.execute(CreateProjectFromArchetypeMojo.java:180)
        at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:284)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
        at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
        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:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        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)
Caused by: java.lang.IllegalArgumentException: protocol = http host = null
        at sun.net.spi.DefaultProxySelector.select(DefaultProxySelector.java:146)
        at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:775)

        at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:705)

        at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:949)

        at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:367)
        ... 28 more
[INFO] No archetype defined. Using maven-archetype-quickstart (org.apache.maven.archetypes:maven-archetype-quickstart:1.0)
Choose archetype:
Choose a number: :


and the command line is unresponsive.


Then tried:

mvn archetype:generate

and chose 34: cocoon-22-archetype-block from the list

Then I ran:

 mvn jetty:run


 [INFO] Compilation
failure
/usr/local/anthologise/anthologiser/src/main/java/au/edu/usyd/library/april-dev/MyBean.java:[17,33]
';' expected


SO: then I deleted the application directory and ran:

mvn archetype:generate

again, this time choosing:

        35: internal -> cocoon-22-archetype-webapp
        
[INFO] BUILD SUCCESSFUL


Then I changed to the application directory and ran:

mvn jetty:run

[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Webapp source directory
/usr/local/anthologise/anthologies/target/anthologies-1.0-SNAPSHOT does not exist


Then I changed the version of Jetty in pom.xml from 6.1.7 to 6.0.2 and ran:

mvn jetty:run

again. Same error:

[INFO] Webapp source directory
/usr/local/anthologise/anthologies/target/anthologies-1.0-SNAPSHOT does not exist


So I created the stinkin' directory:

      mkdir anthologies-1.0-SNAPSHOT


and ran:

mvn jetty:run

again.

[INFO] web.xml does not exist at location /usr/local/anthologise/anthologies/target/anthologies-1.0-SNAPSHOT/WEB-INF/web.xml


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe <at> cocoon.apache.org
For additional commands, e-mail: users-help <at> cocoon.apache.org
Stephen | 2 Feb 2010 17:08
Picon

Re: 2.2 installation help

I think you may need to update your pom.xml.

Where the getting started doc indicates you should use:

<version>1.0-SNAPSHOT</version>
you should really use:
<version>1.0.0</version>

See this thread from the Cocoon Users list archives for more info:
http://mail-archives.apache.org/mod_mbox/cocoon-users/200909.mbox/%3C6432F626-FAA6-4733-A8AD-F403F6BAE874 <at> virginia.edu%3E

Hope this helps!
Stephen


On Mon, Feb 1, 2010 at 3:30 PM, Gary Browne <gary.browne <at> sydney.edu.au> wrote:
Hello,

I'm having trouble installing Cocoon 2.2 using Maven. Please see attached install log.

Any advice would be much appreciated, I have spent hours on this!

Thanks
Gary


GARY BROWNE | Development Programmer
Library IT Services | University Library
THE UNIVERSITY OF SYDNEY
Level 1, Fisher Library F03 | The University of Sydney | NSW | 2006
T +61 2 9351 5946  | F +61 2 9036 0000
E gary.browne <at> sydney.edu.au  | W http://sydney.edu.au

Sent from my plain old desktop computer.

CRICOS 00026A
This email plus any attachments to it are confidential. Any unauthorised use is strictly prohibited. If you receive this email in error, please delete it and any attachments.
Please think of our environment and only print this e-mail if necessary.




---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe <at> cocoon.apache.org
For additional commands, e-mail: users-help <at> cocoon.apache.org

anandhthiyagarajan | 2 Feb 2010 18:39
Picon

Table Manipulation


Hi everybody

    I am stuck up with an issue in manipulating the table.

Consider the below XML and XSL

<root>
    <roadmap>
        <years>
            <year>2009</year>
            <quarters>
                <quarter>Q3</quarter>
                <requirements>
                    <requirement>Mp3Player</requirement>
                </requirements>
                <requirements>
                    <requirement>Mp3Player</requirement>
                </requirements>
                <requirements>
                    <requirement>DataCable</requirement>
                </requirements>
                <requirements>
                    <requirement>Mp3Player</requirement>
                </requirements>
                <requirements>
                    <requirement>Mp3Player</requirement>
                </requirements>
                <requirements>
                    <requirement>Bluetooth</requirement>
                </requirements>
            </quarters>
            <quarters>
                <quarter>Q4</quarter>
                <requirements>
                    <requirement>DataCable</requirement>
                </requirements>
                <requirements>
                    <requirement>MemoryCard</requirement>
                </requirements>
                <requirements>
                    <requirement>InbuiltCam</requirement>
                </requirements>
            </quarters>
        </years>
    </roadmap>
</root>

XSL:

<xsl:template match="root/roadmap">
    <fo:block space-before='2mm'>
      <fo:block font-size="10pt" color="black" font-weight="bold"
increment-by="1.1.1"  space-before="0.54in" space-after="2pt" >
        ROADMAP INFORMATION
      </fo:block>
      <fo:block space-before='2mm'>
      </fo:block>
      <fo:table  border-collapse="collapse"  font-size="9pt">
        <fo:table-column column-width="1in"/>
        <fo:table-column column-width="50%"/>
        <fo:table-column column-width="50%"/>
        <fo:table-column column-width="50%"/>
        <fo:table-column column-width="50%"/>
        <fo:table-header color="black" background-color="rgb(39,64,139)"
                         font-weight="bold">
          <fo:table-row>
            <fo:table-cell padding="2pt" border="1pt solid black"
text-align="center">
              <fo:block>YEAR</fo:block>
            </fo:table-cell>
            <fo:table-cell padding="2pt" border="1pt solid black"
text-align="center">
              <fo:block>Q1</fo:block>
            </fo:table-cell>
            <fo:table-cell padding="2pt" border="1pt solid black"
text-align="center">
              <fo:block>Q2</fo:block>
            </fo:table-cell>
            <fo:table-cell padding="2pt" border="1pt solid black"
text-align="center">
              <fo:block>Q3</fo:block>
            </fo:table-cell>
            <fo:table-cell padding="2pt" border="1pt solid black"
text-align="center">
              <fo:block>Q4</fo:block>
            </fo:table-cell>
          </fo:table-row>
        </fo:table-header>
        <fo:table-body>
          <xsl:for-each select="years">
            <fo:table-row>
              <fo:table-cell padding="2pt" border="1pt solid black"
background-color="rgb(255,255,255)" text-align="center">
                <fo:block><xsl:value-of select="year"/></fo:block>
              </fo:table-cell>
              <xsl:for-each select="quarters">
                <fo:table-cell padding="2pt" border="1pt solid black"
background-color="rgb(255,255,255)" text-align="center">
                  <fo:block><xsl:value-of select="."/></fo:block>
                </fo:table-cell>
                <fo:table-cell padding="2pt" border="1pt solid black"
background-color="rgb(255,255,255)" text-align="center">
                  <fo:block><xsl:value-of select="requirement"/></fo:block>
                </fo:table-cell>
                <fo:table-cell padding="2pt" border="1pt solid black"
background-color="rgb(255,255,255)" text-align="center">
                  <fo:block><xsl:value-of select="requirement"/></fo:block>
                </fo:table-cell>
                <fo:table-cell padding="2pt" border="1pt solid black"
background-color="rgb(255,255,255)" text-align="center">
                  <fo:block><xsl:value-of select="requirement"/></fo:block>
                </fo:table-cell>
              </xsl:for-each>
            </fo:table-row>
          </xsl:for-each>
        </fo:table-body>
      </fo:table>
    </fo:block>
  </xsl:template>

I am attaching a file with this which contain the required ouptut.

Table.doc

But i am not getting that output instead it throws a exception. Please let
me know if i am missing something.

The stack trace is as follows

java.lang.ArrayIndexOutOfBoundsException: -2

Cocoon stacktrace:

java.lang.ArrayIndexOutOfBoundsException: -2
context://prd-doc/doc2road.xsl - 7:18

Failed to process pipeline
context://prd-doc/doc2road.xsl - 7:18 [TransformerException]
context://prd-doc/sitemap.xmap - 63:46 <map:serialize type="fo2pdf">
context://prd-doc/sitemap.xmap - 62:51 <map:transform>
context://prd-doc/sitemap.xmap - 61:45 <map:generate>
context://sitemap.xmap - 1034:92 <map:mount> 

Any help would be greatly appreciated.

Thanks in Advance

Anandh
--

-- 
View this message in context: http://old.nabble.com/Table-Manipulation-tp27424395p27424395.html
Sent from the Cocoon - Users mailing list archive at Nabble.com.
Robby Pelssers | 2 Feb 2010 19:01

RE: Table Manipulation

It's probably better to ask this question on the proper mailing list... this is xslt related and more
specific xsl-fo.

Cheers,
Robby Pelssers

-----Original Message-----
From: anandhthiyagarajan [mailto:anandhthiyagarajan <at> gmail.com] 
Sent: Tuesday, February 02, 2010 6:40 PM
To: users <at> cocoon.apache.org
Subject: Table Manipulation


Hi everybody

    I am stuck up with an issue in manipulating the table.



Consider the below XML and XSL

<root>
    <roadmap>
        <years>
            <year>2009</year>
            <quarters>
                <quarter>Q3</quarter>
                <requirements>
                    <requirement>Mp3Player</requirement>
                </requirements>
                <requirements>
                    <requirement>Mp3Player</requirement>
                </requirements>
                <requirements>
                    <requirement>DataCable</requirement>
                </requirements>
                <requirements>
                    <requirement>Mp3Player</requirement>
                </requirements>
                <requirements>
                    <requirement>Mp3Player</requirement>
                </requirements>
                <requirements>
                    <requirement>Bluetooth</requirement>
                </requirements>
            </quarters>
            <quarters>
                <quarter>Q4</quarter>
                <requirements>
                    <requirement>DataCable</requirement>
                </requirements>
                <requirements>
                    <requirement>MemoryCard</requirement>
                </requirements>
                <requirements>
                    <requirement>InbuiltCam</requirement>
                </requirements>
            </quarters>
        </years>
    </roadmap>
</root>


XSL:

<xsl:template match="root/roadmap">
    <fo:block space-before='2mm'>
      <fo:block font-size="10pt" color="black" font-weight="bold"
increment-by="1.1.1"  space-before="0.54in" space-after="2pt" >
        ROADMAP INFORMATION
      </fo:block>
      <fo:block space-before='2mm'>
      </fo:block>
      <fo:table  border-collapse="collapse"  font-size="9pt">
        <fo:table-column column-width="1in"/>
        <fo:table-column column-width="50%"/>
        <fo:table-column column-width="50%"/>
        <fo:table-column column-width="50%"/>
        <fo:table-column column-width="50%"/>
        <fo:table-header color="black" background-color="rgb(39,64,139)"
                         font-weight="bold">
          <fo:table-row>
            <fo:table-cell padding="2pt" border="1pt solid black"
text-align="center">
              <fo:block>YEAR</fo:block>
            </fo:table-cell>
            <fo:table-cell padding="2pt" border="1pt solid black"
text-align="center">
              <fo:block>Q1</fo:block>
            </fo:table-cell>
            <fo:table-cell padding="2pt" border="1pt solid black"
text-align="center">
              <fo:block>Q2</fo:block>
            </fo:table-cell>
            <fo:table-cell padding="2pt" border="1pt solid black"
text-align="center">
              <fo:block>Q3</fo:block>
            </fo:table-cell>
            <fo:table-cell padding="2pt" border="1pt solid black"
text-align="center">
              <fo:block>Q4</fo:block>
            </fo:table-cell>
          </fo:table-row>
        </fo:table-header>
        <fo:table-body>
          <xsl:for-each select="years">
            <fo:table-row>
              <fo:table-cell padding="2pt" border="1pt solid black"
background-color="rgb(255,255,255)" text-align="center">
                <fo:block><xsl:value-of select="year"/></fo:block>
              </fo:table-cell>
              <xsl:for-each select="quarters">
                <fo:table-cell padding="2pt" border="1pt solid black"
background-color="rgb(255,255,255)" text-align="center">
                  <fo:block><xsl:value-of select="."/></fo:block>
                </fo:table-cell>
                <fo:table-cell padding="2pt" border="1pt solid black"
background-color="rgb(255,255,255)" text-align="center">
                  <fo:block><xsl:value-of select="requirement"/></fo:block>
                </fo:table-cell>
                <fo:table-cell padding="2pt" border="1pt solid black"
background-color="rgb(255,255,255)" text-align="center">
                  <fo:block><xsl:value-of select="requirement"/></fo:block>
                </fo:table-cell>
                <fo:table-cell padding="2pt" border="1pt solid black"
background-color="rgb(255,255,255)" text-align="center">
                  <fo:block><xsl:value-of select="requirement"/></fo:block>
                </fo:table-cell>
              </xsl:for-each>
            </fo:table-row>
          </xsl:for-each>
        </fo:table-body>
      </fo:table>
    </fo:block>
  </xsl:template>


I am attaching a file with this which contain the required ouptut.


Table.doc



But i am not getting that output instead it throws a exception. Please let
me know if i am missing something.

The stack trace is as follows

java.lang.ArrayIndexOutOfBoundsException: -2

Cocoon stacktrace:

java.lang.ArrayIndexOutOfBoundsException: -2
context://prd-doc/doc2road.xsl - 7:18

Failed to process pipeline
context://prd-doc/doc2road.xsl - 7:18 [TransformerException]
context://prd-doc/sitemap.xmap - 63:46 <map:serialize type="fo2pdf">
context://prd-doc/sitemap.xmap - 62:51 <map:transform>
context://prd-doc/sitemap.xmap - 61:45 <map:generate>
context://sitemap.xmap - 1034:92 <map:mount> 

Any help would be greatly appreciated.



Thanks in Advance

Anandh
-- 
View this message in context: http://old.nabble.com/Table-Manipulation-tp27424395p27424395.html

Sent from the Cocoon - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe <at> cocoon.apache.org
For additional commands, e-mail: users-help <at> cocoon.apache.org

Gabriel Gruber | 2 Feb 2010 19:44
Picon

HELP needed with latest Cocoon 2.2 (JNET / SSF)


Hello comunity,

I found a serious bug in JNET / servlet service framework in our cocoon 2.2 based application. After some time the following Exception pops up and the only way to resolve is to restart the web application...


java.lang.NullPointerException
                java.util.LinkedList.remove(LinkedList.java:646)
                java.util.LinkedList.remove(LinkedList.java:360)
                org.apache.cocoon.jnet.DynamicURLStreamHandlerFactory.pop(DynamicURLStreamHandlerFactory.java:30)
                org.apache.cocoon.jnet.URLHandlerFactoryCollector.popUrlHandlerFactories(URLHandlerFactoryCollector.java:57)
                org.apache.cocoon.jnet.URLHandlerFactoryCollector.installURLHandlers(URLHandlerFactoryCollector.java:39)
                sun.reflect.GeneratedMethodAccessor516.invoke(Unknown Source)
                sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                java.lang.reflect.Method.invoke(Method.java:585)
                org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethodWithGivenArgs(AbstractAspectJAdvice.java:627)
                org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethod(AbstractAspectJAdvice.java:616)
                org.springframework.aop.aspectj.AspectJAroundAdvice.invoke(AspectJAroundAdvice.java:64)
                org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
                org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:89)
                org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
                org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
                $Proxy34.service(Unknown Source)
                org.apache.cocoon.servletservice.ServletServiceContext$PathDispatcher.forward(ServletServiceContext.java:481)
                org.apache.cocoon.servletservice.ServletServiceContext$PathDispatcher.forward(ServletServiceContext.java:455)
                org.apache.cocoon.servletservice.spring.ServletFactoryBean$ServiceInterceptor.invoke(ServletFactoryBean.java:245)
                org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
                org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
                $Proxy94.service(Unknown Source)
                org.apache.cocoon.servletservice.DispatcherServlet.service(DispatcherServlet.java:106)
                javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
                org.apache.cocoon.servlet.multipart.MultipartFilter.doFilter(MultipartFilter.java:131)

Any Ideas?

I found a Jira Thread of another project using cocoon and having similar problems...
http://jira.dspace.org/jira/browse/DS-253?page=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel

cheers,

Gabriel
Jos Snellings | 3 Feb 2010 06:59
Picon

Re: HELP needed with latest Cocoon 2.2 (JNET / SSF)

Hi Gabriel,

Very strange to have that exception there!
When does it happen? Is it predictable?

Kind regards,
Jos

On Tue, 2010-02-02 at 19:44 +0100, Gabriel Gruber wrote:
> 
> Hello comunity, 
> 
> I found a serious bug in JNET / servlet service framework in our
> cocoon 2.2 based application. After some time the following Exception
> pops up and the only way to resolve is to restart the web
> application... 
> 
> 
> java.lang.NullPointerException
>                 java.util.LinkedList.remove(LinkedList.java:646)
>                 java.util.LinkedList.remove(LinkedList.java:360)
> 
> org.apache.cocoon.jnet.DynamicURLStreamHandlerFactory.pop(DynamicURLStreamHandlerFactory.java:30)
> 
> org.apache.cocoon.jnet.URLHandlerFactoryCollector.popUrlHandlerFactories(URLHandlerFactoryCollector.java:57)
> 
> org.apache.cocoon.jnet.URLHandlerFactoryCollector.installURLHandlers(URLHandlerFactoryCollector.java:39)
>                 sun.reflect.GeneratedMethodAccessor516.invoke(Unknown
> Source)
> 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>                 java.lang.reflect.Method.invoke(Method.java:585)
> 
> org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethodWithGivenArgs(AbstractAspectJAdvice.java:627)
> 
> org.springframework.aop.aspectj.AbstractAspectJAdvice.invokeAdviceMethod(AbstractAspectJAdvice.java:616)
> 
> org.springframework.aop.aspectj.AspectJAroundAdvice.invoke(AspectJAroundAdvice.java:64)
> 
> org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
> 
> org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:89)
> 
> org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
> 
> org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
>                 $Proxy34.service(Unknown Source)
>                 org.apache.cocoon.servletservice.ServletServiceContext
> $PathDispatcher.forward(ServletServiceContext.java:481)
>                 org.apache.cocoon.servletservice.ServletServiceContext
> $PathDispatcher.forward(ServletServiceContext.java:455)
> 
> org.apache.cocoon.servletservice.spring.ServletFactoryBean
> $ServiceInterceptor.invoke(ServletFactoryBean.java:245)
> 
> org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
> 
> org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
>                 $Proxy94.service(Unknown Source)
> 
> org.apache.cocoon.servletservice.DispatcherServlet.service(DispatcherServlet.java:106)
> 
> javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
> 
> org.apache.cocoon.servlet.multipart.MultipartFilter.doFilter(MultipartFilter.java:131)
> 
> Any Ideas? 
> 
> I found a Jira Thread of another project using cocoon and having
> similar problems... 
>
http://jira.dspace.org/jira/browse/DS-253?page=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel 
> 
> cheers, 
> 
> Gabriel
Aish | 3 Feb 2010 07:35
Favicon

Re: Table manipulation


Hi Anandh,

I did it using FOP 0.95. In your xsl code, number of <fo:table-column
column-width="1in"/> doesn't match(less than) the columns given under
for-each of quarters and hence the problem. You need to check empty
quarters. Also, attribute "increment-by" is removed as it doesn't support.
The code will be as below.

<xsl:template match="root/roadmap">
    <fo:block space-before='2mm'>
      <fo:block font-size="10pt" color="black" font-weight="bold"
space-before="0.54in" space-after="2pt" >
        ROADMAP INFORMATION
      </fo:block>
      <fo:block space-before='2mm'>
      </fo:block>
      <fo:table  border-collapse="collapse"  font-size="9pt">
        <fo:table-column column-width="1in"/>
        <fo:table-column column-width="1in"/>
        <fo:table-column column-width="1in"/>
        <fo:table-column column-width="1in"/>
        <fo:table-column column-width="1in"/>
        <fo:table-header color="black" background-color="rgb(39,64,139)"
font-weight="bold">
          <fo:table-row>
            <fo:table-cell padding="2pt" border="1pt solid black"
text-align="center">
              <fo:block>YEAR</fo:block>
            </fo:table-cell>
            <fo:table-cell padding="2pt" border="1pt solid black"
text-align="center">
              <fo:block>Q1</fo:block>
            </fo:table-cell>
            <fo:table-cell padding="2pt" border="1pt solid black"
text-align="center">
              <fo:block>Q2</fo:block>
            </fo:table-cell>
            <fo:table-cell padding="2pt" border="1pt solid black"
text-align="center">
              <fo:block>Q3</fo:block>
            </fo:table-cell>
            <fo:table-cell padding="2pt" border="1pt solid black"
text-align="center">
              <fo:block>Q4</fo:block>
            </fo:table-cell>
          </fo:table-row>
        </fo:table-header>
        <fo:table-body>
          <xsl:for-each select="years">
            <fo:table-row>
              <fo:table-cell padding="2pt" border="1pt solid black"
background-color="rgb(255,255,255)" text-align="center">
                <fo:block><xsl:value-of select="year"/></fo:block>
              </fo:table-cell>
	      <xsl:variable name="MyQuarter"><xsl:value-of
select="quarters[1]/quarter"/></xsl:variable>
	      <xsl:choose>
		<xsl:when test="$MyQuarter='Q1'">

		</xsl:when>
		<xsl:when test="$MyQuarter='Q2'">
			<fo:table-cell padding="2pt" border="1pt solid
black"><fo:block/></fo:table-cell>
		</xsl:when>	
		<xsl:when test="$MyQuarter='Q3'">
			<fo:table-cell padding="2pt" border="1pt solid black"
text-align="center"><fo:block/></fo:table-cell>
			<fo:table-cell padding="2pt" border="1pt solid black"
text-align="center"><fo:block/></fo:table-cell>
		</xsl:when>
		<xsl:when test="$MyQuarter='Q4'">
			<fo:table-cell padding="2pt" border="1pt solid black"
text-align="center"><fo:block/></fo:table-cell>
			<fo:table-cell padding="2pt" border="1pt solid black"
text-align="center"><fo:block/></fo:table-cell>
			<fo:table-cell padding="2pt" border="1pt solid black"
text-align="center"><fo:block/></fo:table-cell>
		</xsl:when>
		<xsl:when test="$MyQuarter='Q5'">
			<fo:table-cell padding="2pt" border="1pt solid black"
text-align="center"><fo:block/></fo:table-cell>
			<fo:table-cell padding="2pt" border="1pt solid black"
text-align="center"><fo:block/></fo:table-cell>
			<fo:table-cell padding="2pt" border="1pt solid black"
text-align="center"><fo:block/></fo:table-cell>
			<fo:table-cell padding="2pt" border="1pt solid black"
text-align="center"><fo:block/></fo:table-cell>
		</xsl:when>
	      </xsl:choose>
              <xsl:for-each select="quarters">
                <fo:table-cell padding="2pt" border="1pt solid black"
background-color="rgb(255,255,255)" text-align="center">
                  <fo:block><xsl:apply-templates
select="requirements"/></fo:block>
                </fo:table-cell>
              </xsl:for-each>
            </fo:table-row>
          </xsl:for-each>
        </fo:table-body>
      </fo:table>
    </fo:block>
  </xsl:template>

<xsl:template match="requirements">
	<xsl:apply-templates/>
</xsl:template>

<xsl:template match="requirement">
	<xsl:apply-templates/>
</xsl:template>

This code will produce your desired output with FOP 0.95. Hope this helps:-)

Regards
Aish

Jeroen Reijn wrote:
> 
> Hi Anandh,
> 
> first of all welcome! This email should go to the cocoon users 
> mailinglist (see my CC). Please reply only to that list.
> Could you please describe the stacktrace or error message, because that 
> would help us further.
> 
> Regards,
> 
> Jeroen
> 
> anandhthiyagarajan wrote:
>> Hi everybody
>> 
>>     I am stuck up with an issue in manipulating the table.
>> 
>> 
>> 
>> Consider the below XML and XSL
>> 
>> <root>
>>     <roadmap>
>>         <years>
>>             <year>2009</year>
>>             <quarters>
>>                 <quarter>Q3</quarter>
>>                 <requirements>
>>                     <requirement>Mp3Player</requirement>
>>                 </requirements>
>>                 <requirements>
>>                     <requirement>Mp3Player</requirement>
>>                 </requirements>
>>                 <requirements>
>>                     <requirement>DataCable</requirement>
>>                 </requirements>
>>                 <requirements>
>>                     <requirement>Mp3Player</requirement>
>>                 </requirements>
>>                 <requirements>
>>                     <requirement>Mp3Player</requirement>
>>                 </requirements>
>>                 <requirements>
>>                     <requirement>Bluetooth</requirement>
>>                 </requirements>
>>             </quarters>
>>             <quarters>
>>                 <quarter>Q4</quarter>
>>                 <requirements>
>>                     <requirement>DataCable</requirement>
>>                 </requirements>
>>                 <requirements>
>>                     <requirement>MemoryCard</requirement>
>>                 </requirements>
>>                 <requirements>
>>                     <requirement>InbuiltCam</requirement>
>>                 </requirements>
>>             </quarters>
>>         </years>
>>     </roadmap>
>> </root>
>> 
>> 
>> XSL:
>> 
>> <xsl:template match="root/roadmap">
>>     <fo:block space-before='2mm'>
>>       <fo:block font-size="10pt" color="black" font-weight="bold"
>> increment-by="1.1.1"  space-before="0.54in" space-after="2pt" >
>>         ROADMAP INFORMATION
>>       </fo:block>
>>       <fo:block space-before='2mm'>
>>       </fo:block>
>>       <fo:table  border-collapse="collapse"  font-size="9pt">
>>         <fo:table-column column-width="1in"/>
>>         <fo:table-column column-width="50%"/>
>>         <fo:table-column column-width="50%"/>
>>         <fo:table-column column-width="50%"/>
>>         <fo:table-column column-width="50%"/>
>>         <fo:table-header color="black" background-color="rgb(39,64,139)"
>>                          font-weight="bold">
>>           <fo:table-row>
>>             <fo:table-cell padding="2pt" border="1pt solid black"
>> text-align="center">
>>               <fo:block>YEAR</fo:block>
>>             </fo:table-cell>
>>             <fo:table-cell padding="2pt" border="1pt solid black"
>> text-align="center">
>>               <fo:block>Q1</fo:block>
>>             </fo:table-cell>
>>             <fo:table-cell padding="2pt" border="1pt solid black"
>> text-align="center">
>>               <fo:block>Q2</fo:block>
>>             </fo:table-cell>
>>             <fo:table-cell padding="2pt" border="1pt solid black"
>> text-align="center">
>>               <fo:block>Q3</fo:block>
>>             </fo:table-cell>
>>             <fo:table-cell padding="2pt" border="1pt solid black"
>> text-align="center">
>>               <fo:block>Q4</fo:block>
>>             </fo:table-cell>
>>           </fo:table-row>
>>         </fo:table-header>
>>         <fo:table-body>
>>           <xsl:for-each select="years">
>>             <fo:table-row>
>>               <fo:table-cell padding="2pt" border="1pt solid black"
>> background-color="rgb(255,255,255)" text-align="center">
>>                 <fo:block><xsl:value-of select="year"/></fo:block>
>>               </fo:table-cell>
>>               <xsl:for-each select="quarters">
>>                 <fo:table-cell padding="2pt" border="1pt solid black"
>> background-color="rgb(255,255,255)" text-align="center">
>>                   <fo:block><xsl:value-of select="."/></fo:block>
>>                 </fo:table-cell>
>>                 <fo:table-cell padding="2pt" border="1pt solid black"
>> background-color="rgb(255,255,255)" text-align="center">
>>                   <fo:block><xsl:value-of
>> select="requirement"/></fo:block>
>>                 </fo:table-cell>
>>                 <fo:table-cell padding="2pt" border="1pt solid black"
>> background-color="rgb(255,255,255)" text-align="center">
>>                   <fo:block><xsl:value-of
>> select="requirement"/></fo:block>
>>                 </fo:table-cell>
>>                 <fo:table-cell padding="2pt" border="1pt solid black"
>> background-color="rgb(255,255,255)" text-align="center">
>>                   <fo:block><xsl:value-of
>> select="requirement"/></fo:block>
>>                 </fo:table-cell>
>>               </xsl:for-each>
>>             </fo:table-row>
>>           </xsl:for-each>
>>         </fo:table-body>
>>       </fo:table>
>>     </fo:block>
>>   </xsl:template>
>> 
>> 
>> I am attaching a file with this which contain the required ouptut.
>> 
>> 
>> http://old.nabble.com/file/p27254530/Table.doc Table.doc 
>> 
>> 
>> 
>> But i am not getting that output instead it throws a exception. Please
>> let
>> me know if i am missing something.
>> 
>> Any help would be greatly appreciated.
>> 
>> 
>> 
>> Thanks in Advance
>> 
>> Anandh
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe <at> cocoon.apache.org
> For additional commands, e-mail: users-help <at> cocoon.apache.org
> 
> 
> 

--

-- 
View this message in context: http://old.nabble.com/Re%3A-Table-manipulation-tp27258569p27432098.html
Sent from the Cocoon - Users mailing list archive at Nabble.com.
Gabriel Gruber | 3 Feb 2010 07:46
Picon

Re: HELP needed with latest Cocoon 2.2 (JNET / SSF)


Hi Joe,

well, I don't have a replayable scenario yet (f.i. testcase), but it seems that the exception comes after heavy use of cocoon pages within our application.  
I suspect that cocoon:/ protocol usage AND/OR  inheritence of sitemap calling (we "extend" cocoon-forms block to override specific resources) might be the root of problem. But that is only a guess...

We are using latest trunk versions of servlet-service-framework and jnet subprojects.  I know that Grek made some changes in cocoon servlet service framework in summer 2009, which went into the 1.2 release, which we are using (since then no changes have been comitted).

The problems reported here (exact same problem we have)

http://jira.dspace.org/jira/browse/DS-253?page=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel
suspects that some classes within SSF are not threadsafe?


best regards,
Gabriel


Jos Snellings <Jos.Snellings <at> pandora.be> wrote on 03.02.2010 06:59:27:

> Hi Gabriel,
>
> Very strange to have that exception there!
> When does it happen? Is it predictable?
>
> Kind regards,
> Jos
>
> On Tue, 2010-02-02 at 19:44 +0100, Gabriel Gruber wrote:
> >
> > Hello comunity,
> >
> > I found a serious bug in JNET / servlet service framework in our
> > cocoon 2.2 based application. After some time the following Exception
> > pops up and the only way to resolve is to restart the web
> > application...
> >
> >
> > java.lang.NullPointerException
> >                 java.util.LinkedList.remove(LinkedList.java:646)
> >                 java.util.LinkedList.remove(LinkedList.java:360)
> >
> > org.apache.cocoon.jnet.DynamicURLStreamHandlerFactory.
> pop(DynamicURLStreamHandlerFactory.java:30)
> >
> > org.apache.cocoon.jnet.URLHandlerFactoryCollector.
> popUrlHandlerFactories(URLHandlerFactoryCollector.java:57)
> >
> > org.apache.cocoon.jnet.URLHandlerFactoryCollector.
> installURLHandlers(URLHandlerFactoryCollector.java:39)
> >                 sun.reflect.GeneratedMethodAccessor516.invoke(Unknown
> > Source)
> >
> > sun.reflect.DelegatingMethodAccessorImpl.
> invoke(DelegatingMethodAccessorImpl.java:25)
> >                 java.lang.reflect.Method.invoke(Method.java:585)
> >
> > org.springframework.aop.aspectj.AbstractAspectJAdvice.
> invokeAdviceMethodWithGivenArgs(AbstractAspectJAdvice.java:627)
> >
> > org.springframework.aop.aspectj.AbstractAspectJAdvice.
> invokeAdviceMethod(AbstractAspectJAdvice.java:616)
> >
> > org.springframework.aop.aspectj.AspectJAroundAdvice.
> invoke(AspectJAroundAdvice.java:64)
> >
> > org.springframework.aop.framework.ReflectiveMethodInvocation.
> proceed(ReflectiveMethodInvocation.java:171)
> >
> > org.springframework.aop.interceptor.ExposeInvocationInterceptor.
> invoke(ExposeInvocationInterceptor.java:89)
> >
> > org.springframework.aop.framework.ReflectiveMethodInvocation.
> proceed(ReflectiveMethodInvocation.java:171)
> >
> > org.springframework.aop.framework.JdkDynamicAopProxy.
> invoke(JdkDynamicAopProxy.java:204)
> >                 $Proxy34.service(Unknown Source)
> >                 org.apache.cocoon.servletservice.ServletServiceContext
> > $PathDispatcher.forward(ServletServiceContext.java:481)
> >                 org.apache.cocoon.servletservice.ServletServiceContext
> > $PathDispatcher.forward(ServletServiceContext.java:455)
> >
> > org.apache.cocoon.servletservice.spring.ServletFactoryBean
> > $ServiceInterceptor.invoke(ServletFactoryBean.java:245)
> >
> > org.springframework.aop.framework.ReflectiveMethodInvocation.
> proceed(ReflectiveMethodInvocation.java:171)
> >
> > org.springframework.aop.framework.JdkDynamicAopProxy.
> invoke(JdkDynamicAopProxy.java:204)
> >                 $Proxy94.service(Unknown Source)
> >
> > org.apache.cocoon.servletservice.DispatcherServlet.
> service(DispatcherServlet.java:106)
> >
> > javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
> >
> > org.apache.cocoon.servlet.multipart.MultipartFilter.
> doFilter(MultipartFilter.java:131)
> >
> > Any Ideas?
> >
> > I found a Jira Thread of another project using cocoon and having
> > similar problems...
> > http://jira.dspace.org/jira/browse/DS-253?page=com.atlassian.jira.
> plugin.system.issuetabpanels%3Acomment-tabpanel
> >
> > cheers,
> >
> > Gabriel
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe <at> cocoon.apache.org
> For additional commands, e-mail: users-help <at> cocoon.apache.org
>
koencl | 3 Feb 2010 21:05
Picon

Can Cocoon be a solution (or start) for me?


Today we are working in a custom J2EE web application framework (kind of
Struts alike framework). 
But we need a new kind of website.

The main requirement is that we need some flexible structure to setup the
web pages (kind of building blocks). And maybe in the future a new
requirement could be that our web administrator (non developer) can modify
the structure (not the whole structure, but playing a litlle bit with some
blocks) without need some developer doing the job...

So Maybe someone can told me if Cocoon can help me building up such a J2EE
website?

And maybe important is that some JSP pages tody can be re-used easily...

Thanks for all feedback
--

-- 
View this message in context: http://old.nabble.com/Can-Cocoon-be-a-solution-%28or-start%29-for-me--tp27442546p27442546.html
Sent from the Cocoon - Users mailing list archive at Nabble.com.

Gmane