RE: C2: Connection Pool

2001-08-13 Thread HALLOWELL,KARL (HP-Cupertino,ex1)

Try looking at the login_xsp.java file created by cocoon. It should be
located inside the working directory for your application server. For
tomcat, that would be somewhere inside $TOMCAT_HOME/work/localhost%2Fcocoon
(for stuff in the cocoon directory).  It's possible that the problem isn't
the connection pool code, but a nearby typo.


Karl Hallowell [EMAIL PROTECTED]

 -Original Message-
 From: Martin Benda [mailto:[EMAIL PROTECTED]]
 Sent: Thursday, August 09, 2001 8:36 AM
 To: [EMAIL PROTECTED]
 Subject: C2: Connection Pool
 
 
 How to access the connection pool out of java? When I try to
 access my connection pool with the help of esql it works fine, but
 when I try to access the pool out of java I always get an exception.
 
 xsp:logic
   private DataSourceComponent datasource;
 
   public void compose(ComponentManager manager) {
ComponentSelector selector =
 (ComponentSelector)manager.lookup(Roles.DB_CONNECTION);
this.datasource =
 (DataSourceComponent)selector.select([DBpoolName]);
   }
 
   Connection con;
 
   try {
 con = datasource.getConnection();
   ...
 /xsp:logic
 
 I try to access the connection poll like discribed on the 
 website of C2, but
 I always get an
 expception
 org.apache.cocoon.components.language.LanguageException: 
 Error compiling
 login_xsp:
 Line 192, column 35:  '}' expected.
 Line 194, column 4:  Statement expected.
 Line 206, column 4:  Type expected.
 
 How can I access the pool the right way?
 
 I am using Cocoon2b2 and tomcat 3.2.3
 
 thanks,
 Martin
 
 
 -
 Please check that your question has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faqs.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 

-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




[C2] When are subsitemaps reloaded?

2001-07-20 Thread HALLOWELL,KARL (HP-Cupertino,ex1)

I have a subsitemap with the check-reload parameter set to yes. I made a
change in my subsitemap (fixed a type) and reloaded a relevant link. The old
error (due to the typo) reappeared. I then restarted cocoon. Error
disappears. Usually, my changes in my subsitemap are reloaded. Is there some
lag between when a subsitemap is changed and when that subsitemap is
reloaded? Thank you.


Karl Hallowell [EMAIL PROTECTED]

 

-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




RE: [c2] class loading problem with a jdbc driver

2001-07-20 Thread HALLOWELL,KARL (HP-Cupertino,ex1)

I found that renaming the oracle library so that it ends in .jar instead
of .zip did the trick. ;-) It works well! Thank you for the excellent
advice!


Karl Hallowell [EMAIL PROTECTED]

 -Original Message-
 From: giacomo [mailto:[EMAIL PROTECTED]]
 Sent: Thursday, July 19, 2001 2:50 PM
 To: [EMAIL PROTECTED]
 Subject: Re: [c2] class loading problem with a jdbc driver
 
 
 On Thu, 19 Jul 2001, HALLOWELL,KARL (HP-Cupertino,ex1) wrote:
 
  I'm having trouble specifying the classpath for a jdbc 
 driver. Here's the
  entry in my web.xml file for loading the jdbc driver:
 
  init-param
param-nameload-class/param-name
param-value
  !-- For Oracle Driver: --
oracle.jdbc.driver.OracleDriver
 
  !-- For Database Driver: --
  org.hsqldb.jdbcDriver
/param-value
  /init-param
 
 
  I get the following exception first thing (no previous 
 entries in the log
  file) when I start cocoon. Immediately after the (long) load class
  exception, the log file prints out the full classpath 
 including the jdbc
  driver (it's
  
 /opt/jakarta-tomcat-4.0-b5/webapps/cocoon/WEB-INF/lib/classes
 12.zip). Why
  isn't the class being found (it gets found later when I 
 load relevant
  esql-based xsp pages)? What am I doing wrong?
 
 IIRC Tomcat 4 is not loading zip files from the lib 
 directory. I had to
 unzip and jar it as classes.jar to get it working under TC4.
 
 Giacomo
 
 
 
  Karl Hallowell [EMAIL PROTECTED]
 
   
 
 
  DEBUG   46  [cocoon  ] (HttpProcessor[8080][4]): Trying 
 to load class:
  oracl
  e.jdbc.driver.OracleDriver
  WARN94  [cocoon  ] (HttpProcessor[8080][4]): Could 
 not force-load
  class:
   oracle.jdbc.driver.OracleDriver
  java.lang.ClassNotFoundException: oracle.jdbc.driver.OracleDriver
  at 
 java.net.URLClassLoader$1.run(URLClassLoader.java, Compiled Code)
  at 
 java.security.AccessController.doPrivileged(Native Method)
  at 
 java.net.URLClassLoader.findClass(URLClassLoader.java, Compiled
  Code)
  at 
 java.lang.ClassLoader.loadClass(ClassLoader.java, Compiled Code)
  at 
 java.lang.ClassLoader.loadClass(ClassLoader.java, Compiled Code)
  at 
 org.apache.cocoon.util.ClassUtils.loadClass(ClassUtils.java:46)
  at
  
 org.apache.cocoon.servlet.CocoonServlet.forceLoad(CocoonServlet.java:
  399)
  at
  org.apache.cocoon.servlet.CocoonServlet.init(CocoonServlet.java:119)
  at
  
 org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java, C
  ompiled Code)
  at
  
 org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.jav
  a:602)
  at
  
 org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV
  alve.java:231)
  at
  
 org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
  .java, Compiled Code)
  at
  
 org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
  a, Compiled Code)
  at 
 org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java,
  Com
  piled Code)
  at
  
 org.apache.catalina.core.StandardContextValve.invoke(StandardContextV
  alve.java:225)
  at
  
 org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
  .java, Compiled Code)
  at
  
 org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
  a, Compiled Code)
  at 
 org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java,
  Com
  piled Code)
  at
  
 org.apache.catalina.core.StandardContext.invoke(StandardContext.java:
  2252)
  at
  
 org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j
  ava:164)
  at
  
 org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
  .java, Compiled Code)
  at
  
 org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:
  446)
  at
  
 org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
  .java, Compiled Code)
  at
  
 org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
  a, Compiled Code)
  at 
 org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java,
  Com
  piled Code)
  at
  
 org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal
  ve.java:163)
  at
  
 org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
  .java, Compiled Code)
  at
  
 org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
  a, Compiled Code)
  at 
 org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java,
  Com
  piled Code)
  at
  
 org.apache.catalina.connector.http.HttpProcessor.process(HttpProcesso
  r.java:875)
  at
  
 org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.ja
  va, Compiled Code)
  at java.lang.Thread.run(Thread.java, Compiled Code)
  DEBUG   332 [cocoon  ] (HttpProcessor[8080

[C2] How can I load logicsheets?

2001-07-20 Thread HALLOWELL,KARL (HP-Cupertino,ex1)

I know how to load built-in logicsheets (specify them in the cocoon.xconf
file and put an entry in the xsp:page tag), but apparently the old way of
applying a logicsheet via a cocoon processor command is obselete (it
generates an exception). I.e., the following no longer works (I've tried
both inside and outside the xsp:page tag, same exception):

?xml-logicsheet href=logicsheet.greeting.xsl?

What is the current mechanism for applying logicsheets for XSP pages without
making an entry in cocoon.xconf? My apologies if this has been discussed
before. My searches on the mailing lists were quite inconclusive.


Karl Hallowell [EMAIL PROTECTED]

PS, here's the exception.

--

A Servlet Exception Has Occurred
Exception Report:
javax.servlet.ServletException: Servlet execution threw an exception
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
FilterChain.java, Compiled Code)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java, Compiled Code)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
va, Compiled Code)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java,
Compiled Code)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java,
Compiled Code)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java,
Compiled Code)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
va, Compiled Code)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java,
Compiled Code)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java,
Compiled Code)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java,
Compiled Code)
at
org.apache.catalina.core.StandardContext.invoke(StandardContext.java,
Compiled Code)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java,
Compiled Code)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java,
Compiled Code)
at
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java,
Compiled Code)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java,
Compiled Code)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java,
Compiled Code)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java,
Compiled Code)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java
, Compiled Code)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java,
Compiled Code)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java,
Compiled Code)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java,
Compiled Code)
at
org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java,
Compiled Code)
at
org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java,
Compiled Code)
at java.lang.Thread.run(Thread.java, Compiled Code)

Root Cause:
java.lang.IllegalAccessError: try to access method
org/apache/cocoon/components/language/markup/AbstractMarkupLanguage.addLogic
sheetToList(Lorg/apache/cocoon/components/language/markup/AbstractMarkupLang
uage$LanguageDescriptor;Ljava/lang/String;Lorg/apache/cocoon/environment/Sou
rceRes
at
org.apache.cocoon.components.language.markup.xsp.XSPMarkupLanguage$XSPTransf
ormerChainBuilderFilter.processingInstruction(XSPMarkupLanguage.java:355)
at
org.xml.sax.helpers.XMLFilterImpl.processingInstruction(XMLFilterImpl.java,
Compiled Code)
at
org.apache.cocoon.components.language.markup.xsp.XSPMarkupLanguage$PreProces
sFilter.processingInstruction(XSPMarkupLanguage.java, Compiled Code)
at
org.apache.xerces.parsers.SAXParser.processingInstruction(SAXParser.java,
Compiled Code)
at
org.apache.xerces.validators.common.XMLValidator.callProcessingInstruction(X
MLValidator.java, Compiled Code)
at
org.apache.xerces.framework.XMLDocumentScanner.scanPI(XMLDocumentScanner.jav
a, Compiled Code)
at
org.apache.xerces.framework.XMLDocumentScanner$ContentDispatcher.dispatch(XM
LDocumentScanner.java, Compiled Code)
at
org.apache.xerces.framework.XMLDocumentScanner.parseSome(XMLDocumentScanner.
java, Compiled Code)
at org.apache.xerces.framework.XMLParser.parse(XMLParser.java,
Compiled Code)
at org.xml.sax.helpers.XMLFilterImpl.parse(XMLFilterImpl.java,
Compiled Code)
at org.xml.sax.helpers.XMLFilterImpl.parse(XMLFilterImpl.java,
Compiled Code)
at
org.apache.cocoon.components.language.markup.LogicsheetCodeGenerator.generat
eCode(LogicsheetCodeGenerator.java, Compiled Code)
at
org.apache.cocoon.components.language.markup.AbstractMarkupLanguage.generate

[c2] class loading problem with a jdbc driver

2001-07-19 Thread HALLOWELL,KARL (HP-Cupertino,ex1)

I'm having trouble specifying the classpath for a jdbc driver. Here's the
entry in my web.xml file for loading the jdbc driver:

init-param
  param-nameload-class/param-name
  param-value
!-- For Oracle Driver: --
  oracle.jdbc.driver.OracleDriver

!-- For Database Driver: --
org.hsqldb.jdbcDriver
  /param-value
/init-param


I get the following exception first thing (no previous entries in the log
file) when I start cocoon. Immediately after the (long) load class
exception, the log file prints out the full classpath including the jdbc
driver (it's
/opt/jakarta-tomcat-4.0-b5/webapps/cocoon/WEB-INF/lib/classes12.zip). Why
isn't the class being found (it gets found later when I load relevant
esql-based xsp pages)? What am I doing wrong?


Karl Hallowell [EMAIL PROTECTED]

 


DEBUG   46  [cocoon  ] (HttpProcessor[8080][4]): Trying to load class:
oracl
e.jdbc.driver.OracleDriver
WARN94  [cocoon  ] (HttpProcessor[8080][4]): Could not force-load
class:
 oracle.jdbc.driver.OracleDriver
java.lang.ClassNotFoundException: oracle.jdbc.driver.OracleDriver
at java.net.URLClassLoader$1.run(URLClassLoader.java, Compiled Code)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java, Compiled
Code)
at java.lang.ClassLoader.loadClass(ClassLoader.java, Compiled Code)
at java.lang.ClassLoader.loadClass(ClassLoader.java, Compiled Code)
at org.apache.cocoon.util.ClassUtils.loadClass(ClassUtils.java:46)
at
org.apache.cocoon.servlet.CocoonServlet.forceLoad(CocoonServlet.java:
399)
at
org.apache.cocoon.servlet.CocoonServlet.init(CocoonServlet.java:119)
at
org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java, C
ompiled Code)
at
org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.jav
a:602)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV
alve.java:231)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
.java, Compiled Code)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
a, Compiled Code)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java,
Com
piled Code)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextV
alve.java:225)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
.java, Compiled Code)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
a, Compiled Code)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java,
Com
piled Code)
at
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:
2252)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j
ava:164)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
.java, Compiled Code)
at
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:
446)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
.java, Compiled Code)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
a, Compiled Code)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java,
Com
piled Code)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal
ve.java:163)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
.java, Compiled Code)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
a, Compiled Code)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java,
Com
piled Code)
at
org.apache.catalina.connector.http.HttpProcessor.process(HttpProcesso
r.java:875)
at
org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.ja
va, Compiled Code)
at java.lang.Thread.run(Thread.java, Compiled Code)
DEBUG   332 [cocoon  ] (HttpProcessor[8080][4]): Trying to load class:
org.h
sqldb.jdbcDriver
DEBUG   563 [cocoon  ] (HttpProcessor[8080][4]): extraClassPath is not
absol
ute:
/opt/jakarta-tomcat-4.0-b5/bin/./../webapps/cocoon/WEB-INF/lib/classes12.zi
p
DEBUG   564 [cocoon  ] (HttpProcessor[8080][4]): Using configuration
file: /
cocoon.xconf
INFO566 [cocoon  ] (HttpProcessor[8080][4]): Reloading from:
jndi:/local
host/cocoon/cocoon.xconf
DEBUG   1147[cocoon  ] (HttpProcessor[8080][4]): New Cocoon object.
DEBUG   1148[cocoon  ] (HttpProcessor[8080][4]): Using parser:
org.apache.co
coon.components.parser.JaxpParser
DEBUG   1261[cocoon  ] (HttpProcessor[8080][4]): Attempting to get
Handler f
or: org.apache.cocoon.components.parser.Parser
DEBUG   1522[cocoon  ] (HttpProcessor[8080][4]): Handler type =
org.apache.a
valon.excalibur.component.DefaultComponentHandler
DEBUG   1523[cocoon  ] (HttpProcessor[8080][4]): 

RE: [c2] class loading problem with a jdbc driver

2001-07-19 Thread HALLOWELL,KARL (HP-Cupertino,ex1)

Seems to be worked out. I had to place my oracle jar in the ext directory of
JRE. A big thank you to the Cocoon 2 bug fixers for solving this problem!


Karl Hallowell [EMAIL PROTECTED]

 -Original Message-
 From: HALLOWELL,KARL (HP-Cupertino,ex1) [mailto:[EMAIL PROTECTED]]
 
 I'm having trouble specifying the classpath for a jdbc 
 driver. Here's the
 entry in my web.xml file for loading the jdbc driver:
 
 init-param
   param-nameload-class/param-name
   param-value
 !-- For Oracle Driver: --
   oracle.jdbc.driver.OracleDriver
 
 !-- For Database Driver: --
 org.hsqldb.jdbcDriver
   /param-value
 /init-param
 
 
 I get the following exception first thing (no previous 
 entries in the log
 file) when I start cocoon. Immediately after the (long) load class
 exception, the log file prints out the full classpath 
 including the jdbc
 driver (it's
 /opt/jakarta-tomcat-4.0-b5/webapps/cocoon/WEB-INF/lib/classes
 12.zip). Why
 isn't the class being found (it gets found later when I load relevant
 esql-based xsp pages)? What am I doing wrong?
 
 
 Karl Hallowell [EMAIL PROTECTED]
 
  
 
 
 DEBUG   46  [cocoon  ] (HttpProcessor[8080][4]): Trying 
 to load class:
 oracl
 e.jdbc.driver.OracleDriver
 WARN94  [cocoon  ] (HttpProcessor[8080][4]): Could 
 not force-load
 class:
  oracle.jdbc.driver.OracleDriver
 java.lang.ClassNotFoundException: oracle.jdbc.driver.OracleDriver
 at java.net.URLClassLoader$1.run(URLClassLoader.java, 
 Compiled Code)
 at java.security.AccessController.doPrivileged(Native Method)
 at 
 java.net.URLClassLoader.findClass(URLClassLoader.java, Compiled
 Code)
 at java.lang.ClassLoader.loadClass(ClassLoader.java, 
 Compiled Code)
 at java.lang.ClassLoader.loadClass(ClassLoader.java, 
 Compiled Code)
 at 
 org.apache.cocoon.util.ClassUtils.loadClass(ClassUtils.java:46)
 at
 org.apache.cocoon.servlet.CocoonServlet.forceLoad(CocoonServlet.java:
 399)
 at
 org.apache.cocoon.servlet.CocoonServlet.init(CocoonServlet.java:119)
 at
 org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java, C
 ompiled Code)
 at
 org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.jav
 a:602)
 at
 org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV
 alve.java:231)
 at
 org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
 .java, Compiled Code)
 at
 org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
 a, Compiled Code)
 at 
 org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java,
 Com
 piled Code)
 at
 org.apache.catalina.core.StandardContextValve.invoke(StandardContextV
 alve.java:225)
 at
 org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
 .java, Compiled Code)
 at
 org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
 a, Compiled Code)
 at 
 org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java,
 Com
 piled Code)
 at
 org.apache.catalina.core.StandardContext.invoke(StandardContext.java:
 2252)
 at
 org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j
 ava:164)
 at
 org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
 .java, Compiled Code)
 at
 org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:
 446)
 at
 org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
 .java, Compiled Code)
 at
 org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
 a, Compiled Code)
 at 
 org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java,
 Com
 piled Code)
 at
 org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal
 ve.java:163)
 at
 org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline
 .java, Compiled Code)
 at
 org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
 a, Compiled Code)
 at 
 org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java,
 Com
 piled Code)
 at
 org.apache.catalina.connector.http.HttpProcessor.process(HttpProcesso
 r.java:875)
 at
 org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.ja
 va, Compiled Code)
 at java.lang.Thread.run(Thread.java, Compiled Code)
 DEBUG   332 [cocoon  ] (HttpProcessor[8080][4]): Trying 
 to load class:
 org.h
 sqldb.jdbcDriver
 DEBUG   563 [cocoon  ] (HttpProcessor[8080][4]): 
 extraClassPath is not
 absol
 ute:
 /opt/jakarta-tomcat-4.0-b5/bin/./../webapps/cocoon/WEB-INF/lib
 /classes12.zi
 p
 DEBUG   564 [cocoon  ] (HttpProcessor[8080][4]): Using 
 configuration
 file: /
 cocoon.xconf
 INFO566 [cocoon  ] (HttpProcessor[8080][4]): Reloading from:
 jndi:/local
 host/cocoon/cocoon.xconf
 DEBUG   1147[cocoon

Q on session validation example

2001-07-17 Thread HALLOWELL,KARL (HP-Cupertino,ex1)

I have a question about Martin Man's session validation example (e.g.,
http://localhost/cocoon/protected/login). Namely, the session validator is
called every time that a match (map:match that is) is done in the sitemap.
I.e., if I surf to protected/protected it first checks with the session
validator action to see if I've logged in. I continue only if my request has
the appropriate session parameter/cookie. At the time, the author, Martin
noted that he didn't like having to put the action in every match entry in
the sitemap that he wanted to protect against unauthorized logins. My
question is whether this can be done. I.e., can I route everything though
say URL match protected/**, do the session check in that map:match, set
some sitemap parameter, and then redirect to another URL (say
rootname/{1}).

The idea is that the session validation appears only once in the sitemap,
but is checked for a variety of URLs. Is there anything wrong with my idea?
Are there simple ways this session validation can be bypassed?


Karl Hallowell [EMAIL PROTECTED]

PS, this probably is directly relevant to the huge discussion on URL
redirection since session checking (and redirecting to login windows) is
probably the most important function that requires redirection.

-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




RE: [c2] Selectors and Matchers vs components in sitemaps

2001-07-12 Thread HALLOWELL,KARL (HP-Cupertino,ex1)

My apologies. This was meant to be a Cocoon 2 question.


Karl Hallowell [EMAIL PROTECTED]


 -Original Message-
 From: HALLOWELL,KARL (HP-Cupertino,ex1) [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, July 11, 2001 3:26 PM
 To: [EMAIL PROTECTED]
 Subject: Selectors and Matchers vs components in sitemaps
 
 
 I noticed that the packages org.apache.cocoon.selection and
 org.apache.cocoon.matching contain a number of code 
 factories (writes a
 StringBuffer of java code) while none of the other packages 
 (in cocoon) do.
 Does this mean that if I write a selector or matcher that I 
 actually should
 write a CodeFactory object? Didn't spot anything about this 
 subject on the
 mailing lists. Thank you.
 
 
 
 Karl Hallowell [EMAIL PROTECTED]
 
  
 
 -
 Please check that your question has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faqs.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 

-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Selectors and Matchers vs components in sitemaps

2001-07-11 Thread HALLOWELL,KARL (HP-Cupertino,ex1)

I noticed that the packages org.apache.cocoon.selection and
org.apache.cocoon.matching contain a number of code factories (writes a
StringBuffer of java code) while none of the other packages (in cocoon) do.
Does this mean that if I write a selector or matcher that I actually should
write a CodeFactory object? Didn't spot anything about this subject on the
mailing lists. Thank you.



Karl Hallowell [EMAIL PROTECTED]

 

-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




RE: [C2.0b1] Resource Not Found

2001-07-06 Thread HALLOWELL,KARL (HP-Cupertino,ex1)

IMHO, it looks like a javascript problem here. Both Netscape and IE have
their problems with javascript. The Resource Not Found error is something
I've seen in Netscape browsers before when they open javascript
that-Netscape-wasn't-meant-to-view. I'm not familiar with how Cocoon 2 does
browser version detection (is that in a FAQ somewhere?).


Karl Hallowell [EMAIL PROTECTED]

 -Original Message-
 From: Drasko Kokic [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, July 04, 2001 2:23 PM
 To: [EMAIL PROTECTED]
 Subject: [C2.0b1] Resource Not Found
 
 
 I am having this problem now already one week and have
 no idea what is causing it:
 
 The page in question is available at the following
 URL:
 
 http://kodra.loop.de/KontoCheck/LOOP
 
 and produces strange Resource Not Found error
 WITHOUT any trace in the log file (it all looks OK)
 What is even stranger is that it happens only with
 Netscape browser.  IE is more or less okay with it.
 
 For comparison look at the following URL:
 
 http://kodra.loop.de/PEPSi/demo
 
 (this is the C1.8.2 implementation of the same
 prototype)
 
 Does anybody have any idea what could be a problem? 
 How to find out which resource is not found?!
 
 TIA
 Drasko
 
 __
 Do You Yahoo!?
 Get personalized email addresses from Yahoo! Mail
 http://personal.mail.yahoo.com/
 
 -
 Please check that your question has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faqs.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 

-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




RE: again mySQL, jdbc and ESQL

2001-07-05 Thread HALLOWELL,KARL (HP-Cupertino,ex1)

Is your site map set up correctly? I.e., you can treat an xsp page as an XML
document and then apply esql.xsl (the logicsheet) as a regular XSL
stylesheet. The result is that you will get ESQL code embedded in the xsp
page which sounds like what is happening. Make sure that you have the
correct type set for your map:generate (type=serverpages). The esql.xsl
should *not* be present in a map:transform. I.e., this works for me:

   map:match pattern=ktest/testquery
map:generate type=serverpages src=c2-test/sql-code/testquery.xsp/
map:transform src=stylesheets/simple-samples2html.xsl
map:parameter name=view-source value=c2-test/{1}.xsp/
/map:transform
map:serialize/
   /map:match



Karl Hallowell [EMAIL PROTECTED]

 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]]
 Sent: Thursday, July 05, 2001 10:14 AM
 To: [EMAIL PROTECTED]
 Subject: again mySQL, jdbc and ESQL
 
 
 The XSP uri you are using is old. The new URI is
 http://apache.org/xsp
 Try
 xsp:page
language=java
 xmlns:xsp=http://apache.org/xsp;
 xmlns:esql=http://apache.org/cocoon/SQL/v2;
 
 Marco
 
 
 Thank you Marco, but I continue to receive
 ESQL code directly in HTML file.
 I'm very stuck!
 Another idea?
 
 Regards, ciao
 Francesco
 
 
 - Original Message -
 From: [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Wednesday, July 04, 2001 7:51 PM
 Subject: mySQL, jdbc and ESQL
 
 
  Hi,
  I'm trying to setup a pooled connection for mySQL.
 
  My packets: JDK 1.3.1, Tomcat 4 beta5, Cocoon 2 beta1, 
 mySQL 3.23.38,
  mm.mysql 2.0.6.1 on Linux Red Hat 6.2.
 
  I've created a db named test with user fku
  and table utenti.
  Then I've added these lines to cocoon.xconf
  --
  datasources
  jdbc name=personnel
pool-controller min=5 max=10/
dburljdbc:mysql://localhost/test/dburl
userfku/user
password/password
  /jdbc
/datasources
  --
 
  --
  init-param
param-nameload-class/param-name
param-value
org.gjt.mm.mysql.Driver
/param-value
  /init-param
  --
 
  I've put mm.mysql-2.0.6.1.jar in TOMCAT_HOME/lib and 
 CLASSPATH contains
 the
  path to mm.mysql's dir /opt/mm.mysql-2.0.6.1.
 
  This is my XML code:
  --
  xsp:page
  laguage=java
  xmlns:xsp=http://www.apache.org/1999/XSP/Core;
  xmlns:esql=http://apache.org/cocoon/SQL/v2;
  
  ...
  esql:connection
  esql:driverorg.gjt.mm.mysql.Driver/esql:driver
  esql:dburljdbc:mysql://localhost/test/esql:dburl
  esql:usernamefku/esql:username
  esql:password/esql:password
  esql:execute-query
  esql:queryselect * from prova/esql:query
 
  esql:results
  ROWSET
   esql:row-results
ROW
 esql:get-columns/
/ROW
   /esql:row-results
  /ROWSET
  /esql:results
 
  /esql:connection
  --
 
  Please, see the mySQL's localhost.log:
  --
  /opt/mysql/libexec/mysqld, Version: 3.23.38-log, started with:
  Tcp port: 3306  Unix socket: /tmp/mysql.sock
  Time Id CommandArgument
  010703 15:35:08   1 Connect fku@localhost as anonymous on
1 Init DB test
  010703 15:35:16   1 Query   SHOW VARIABLES
  010703 15:35:42   2 Connect fku@localhost as anonymous on
2 Init DB test
2 Query   SHOW VARIABLES
3 Connect fku@localhost as anonymous on
3 Init DB test
3 Query   SHOW VARIABLES
  010703 15:35:43   4 Connect fku@localhost as anonymous on
4 Query   SHOW VARIABLES
  010703 15:35:44   5 Connect fku@localhost as anonymous on
5 Init DB test
5 Query   SHOW VARIABLES
  --
 
  And, finally, cocoon.log:
  --
  ...
  2001-07-03 15:28:52 DEBUG   1539[cocoon  ] 
 (HttpProcessor[8080][4]):
  Trying
  to load class: org.gjt.mm.mysql.Driver
  ...
  2001-07-03 15:35:42 DEBUG   41112   [cocoon  ] (Thread-7): 
 JdbcConnection
 object created
 
  2001-07-03 15:35:42 DEBUG   41155   [cocoon  ] (Thread-7): 
 JdbcConnection
 object created
 
  2001-07-03 15:35:43 DEBUG   41206   [cocoon  ] (Thread-7): 
 JdbcConnection
 object created
 
  2001-07-03 15:35:44 DEBUG   41311   [cocoon  ] (Thread-7): 
 JdbcConnection
 object created
 
  2001-07-03 15:35:45 DEBUG   41396   [cocoon  ] (Thread-7): 
 JdbcConnection
 object created
  ...
  --
 
  But I receive ESQL code in final HTML directly, without any query
  execution, so my HTML document contains these lines:
  --
  org.gjt.mm.mysql.Driver jdbc:mysql://localhost/test fku
  select * from prova
  --
 
  

RE: C2: ESQL-Syntax

2001-06-20 Thread HALLOWELL,KARL (HP-Cupertino,ex1)

Look at the xsl stylesheet for ESQL. That's the specification. ;-) You can
find it in
$COCOON_HOME/src/org/apache/cocoon/components/language/markup/xsp/java/esql.
xsl.


Karl Hallowell [EMAIL PROTECTED]

 -Original Message-
 From: Daniel Pfuhl [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, June 20, 2001 6:17 AM
 To: [EMAIL PROTECTED]
 Subject: Re: C2: ESQL-Syntax
 
 
 Hello again,
 
 is there anywhere a specification for
 the ESQL syntax? I looked for it on
 xml.apache.org but didn't find something...
 
 daniel
 
 
 --- Aurelien DEHAY [EMAIL PROTECTED] schrieb: 
 Daniel Pfuhl [EMAIL PROTECTED] writes:
  
   Hello,
   
   Can anybody tell me what the meaning of
   esql:get-xml column=test/ is?
   I understand 
   esql:get-string column=test/ !
   Is get-xml returning xml? What type 
   do I have to assign to my databasecolumn?
  
  Text for postgreSQL for example, but the string must
  be a valid XML
  tree. e.g:
  
  contentstring content and ememphasised
  text/em/content
  
  -- 
  Aurélien
  
 
 -
  Please check that your question has not already been
  answered in the
  FAQ before posting.
  http://xml.apache.org/cocoon/faqs.html
  
  To unsubscribe, e-mail:
  [EMAIL PROTECTED]
  For additional commands, e-mail:
  [EMAIL PROTECTED]
  
 
 
 =
 
 Daniel Pfuhl
 mailto:[EMAIL PROTECTED]
 
 __
 Do You Yahoo!?
 Gesendet von Yahoo! Mail - http://mail.yahoo.de
 
 -
 Please check that your question has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faqs.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 

-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




RE: [C2] pooling setup question

2001-06-14 Thread HALLOWELL,KARL (HP-Cupertino,ex1)

I went ahead and reported this as a bug (#2190). It's probably something
simple like the Cocoon 1 relatives of this bug (e.g., make sure you change
the right cocoon.properties file).

Karl Hallowell [EMAIL PROTECTED]

 -Original Message-
 From: Gary Clark [mailto:[EMAIL PROTECTED]]
 
 I did, but that may be the problem.  It seems to be an issue with
 Avalon/Excalibur, but I don't know enough to even get started 
 with them.
 This is another good place in C2 for some extra documentation 
 (hint, hint
 ;-).

-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




RE: [C2] Newbie question

2001-06-08 Thread HALLOWELL,KARL (HP-Cupertino,ex1)

I'm not sure what you are asking. Cocoon will always look for those jars in
that directory. If you wish to install cocoon in a directory other than
/cocoon, then you should change the configuration information when you first
build cocoon. I'm not sure but I think that particular parameter is in
build.xml.


Karl Hallowell [EMAIL PROTECTED]

 -Original Message-
 From: Aleksey Globets [mailto:[EMAIL PROTECTED]]
 Sent: Friday, June 08, 2001 11:14 AM
 To: [EMAIL PROTECTED]
 Subject: [C2] Newbie question
 
 
 Hi,
 
 I just install C2. It works fine. But if I plan to use cocoon 
 from other
 directory then /cocoon then do I need to copy all JARs from
 /cocoon/WEB-INF/lib directory to a new one?
 
 Best,
 
 Aleksey Globets
 
 
 -
 Please check that your question has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faqs.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 

-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




RE: [C2] Connection pool problem with SQL

2001-06-05 Thread HALLOWELL,KARL (HP-Cupertino,ex1)

Ok, my esql problems went away with a cvs update of the cocoon 2 source
tree. Still getting the same ProcessingException with the simple SQL
example. I've made sure that my xerces 1.4 jar appears ahead of the xalan
jar.


Karl Hallowell [EMAIL PROTECTED]


 -Original Message-
 
 This is a pretty urgent problem for me (and it's conceivable 
 that this is a
 bug in soon-to-be beta code). I cannot run the SQL examples 
 in cocoon 2. I'm
 using Tomcat 4.0b5, Cocoon 2a7, and Oracle 8i. Here's the 
 problem. When I

snip

 Here's some of my configuration information.
 
 from web.xml:
 
 ---
   param-nameload-class/param-name
   param-value
 !-- For IBM WebSphere: --
 com.ibm.servlet.classloader.Handler
 
 !-- For Database Driver: --
 oracle.jdbc.driver.OracleDriver
   /param-value
 /init-param
 ---
 
 from cocoon.xconf
 
 ---
   datasources
 jdbc name=personnel
   !--
   If you have an Oracle database, and are using the the
   pool-controller below, you should add the attribute
   oradb and set it to true.
 
   pool-controller min=5 max=10 oradb=true/
 
   That way the test to see if the server has disconnected
   the JdbcConnection will function properly.
   --
   pool-controller min=5 max=10 oradb=true/
   !--
   If you need to ensure an autocommit is set to true or
   false, then create the auto-commit element below.
 
   auto-commitfalse/auto-commit
 
   The default is true.
   --
   dburljdbc:oracle:thin:@xxx.yyy.hp.com:1521:ORCL/dburl
   userscott/user
   passwordtiger/password
 /jdbc
   /datasources
 ---
 
 The database URL appears to be correct. I've telneted to the 
 host and port
 in question. The URL was copied in mass from a program where 
 it was working.
 I've verified the tables and data exist by looking in the 
 database via a
 shell. The oracle driver is copied into 
 $TOMCAT_HOME/webapps/cocoon/lib and
 appears to be just fine.
 
 I've mentioned that I can't get some of the other SQL 
 examples to run. The
 simple SQL returns the exception 
 org.apache.cocoon.ProcessingException:
 Failed to execute 
 pipeline.:org.apache.cocoon.ProcessingException: Failed to
 execute pipeline.:java.lang.NullPointerException. I seem to 
 recall that
 this error appeared before in a sitemap. And the stack trace 
 starts with:
 
 ---
 org.apache.cocoon.ProcessingException: Failed to execute
 pipeline.:java.lang.NullPointerException
   at
 org.apache.cocoon.components.pipeline.CachingEventPipeline.pro
 cess(CachingEv
 entPipeline.java, Compiled Code)
   at
 org.apache.cocoon.components.pipeline.CachingStreamPipeline.pr
 ocess(CachingS
 treamPipeline.java, Compiled Code)
   at org.apache.cocoon.www.sitemap_xmap.process(sitemap_xmap.java,
 Compiled Code)
   at org.apache.cocoon.www.sitemap_xmap.process(sitemap_xmap.java,
 Compiled Code)
   at 
 org.apache.cocoon.sitemap.Handler.process(Handler.java, Compiled
 Code)
 ---
 
 What am I missing? Do you need to see my sitemap (or other 
 config files)?
 Thank you very much!

-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]