cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nina Juliadotter" <nvjul...@it.uts.edu.au>
Subject [Fwd: Re: Xindice 1.1b4 (dev-sorry), Cocoon 2.1.4 (dev - sorry), Tomcat 5.019]
Date Sat, 17 Apr 2004 05:48:20 GMT
Hi Mark,

You are so sweet for trying it out for me! And I am really happy to hear that the
configuration works and that I'm not insain.

I think I may know where the problem lies now. As I gave up Cocoon a bit and thought
I would write my own servlet to access the database, I used the source code on
http://xml.apache.org/xindice/guide-developer.html#Diving+in+With+an+Example+Program
and changed the details to work with my database. When I run it, it gives me

XML:DB Exception occured 1 A connection to the Database instance 'db' could not be
created. Error: Connection refused

so I think that maybe that's the error that Cocoon is getting as well, although it
doesn't report it. I mean, if I can't even connect to the database with a simple
command line java class, I can't really expect Cocoon to either. My only theory is
that my faculty has some unfriendly security settings, or something along those
lines.

So I guess I'm off to the xindice user group now...

Again, thanks for all your help. And if anyone happens to have come across the
Connection Refused error... ;-)

All the best,
Nina


> Nina,
>
> I tried reproducing your issue on Fedora Core 1.  I have the same lines as you do
in the main site map.
>
> Check to see if you have the following in your cocoon.xconf.  The lines are 382 -
394.
>
> <!--..... Start configuration from 'xmldb' -->
>
>
> <!-- xmldb pseudo protocol -->
> <component-instance
>   class="org.apache.cocoon.components.source.impl.XMLDBSourceFactory" name="xmldb">
> <!-- Xindice driver -->
>   <driver class="org.apache.xindice.client.xmldb.DatabaseImpl"
>     type="xindice"/>
> <!-- Xindice 1.1 Embedded driver -->
>   <driver class="org.apache.xindice.client.xmldb.embed.DatabaseImpl"
>     type="xindice-embed"/>
> <!-- Add here other XML:DB compliant databases drivers -->
> </component-instance>
>
> <!--..... End configuration from 'xmldb' -->
>
> I created a nina subdirectory in my Cocoon web application, and placed the
following site map in it:
>
> <?xml version="1.0" encoding="UTF-8"?>
>
> <map:sitemap xmlns:map="http://apache.org/cocoon/sitemap/1.0">
>
> <!-- ======================== Pipelines=========================== -->
>
>  <map:pipelines>
>
>   <map:pipeline>
>    <map:match pattern="remote/**">
>     <map:match type="request-parameter" pattern="xpath">
>      <map:generate src="xmldb:xindice://localhost:8080/db/{../1}#{1}"/>
<map:serialize type="xml"/>
>     </map:match>
>     <map:generate src="xmldb:xindice://localhost:8080/db/{1}"/>
>     <map:serialize type="xml"/>
>    </map:match>
>  </map:pipeline>
>
>  </map:pipelines>
> </map:sitemap>
>
> http://localhost:8080/cocoon/nina/remote/  gives me the following:
>
> <?xml version="1.0" encoding="ISO-8859-1"?>
> <xmldb:collections xmlns:xmldb="http://apache.org/cocoon/xmldb/1.0"
>   resources="0" collections="4"
>   base="xmldb:xindice://localhost:8080/db/">
>   <xmldb:collection xmlns:xmldb="http://apache.org/cocoon/xmldb/1.0"
>     name="testcol"/>
>   <xmldb:collection xmlns:xmldb="http://apache.org/cocoon/xmldb/1.0"
>     name="system"/>
>   <xmldb:collection xmlns:xmldb="http://apache.org/cocoon/xmldb/1.0"
>     name="addissue"/>
>   <xmldb:collection xmlns:xmldb="http://apache.org/cocoon/xmldb/1.0"
>     name="meta"/>
> </xmldb:collections>
>
> (cleaning up the saved file).  The addissue collection is one I use to play around
with.  It currently has 100 documents.
>
> Going after http://localhost:8080/cocoon/nina/remote/testcol/ gave me the following:
>
> <?xml version="1.0" encoding="ISO-8859-1"?>
> <xmldb:collections xmlns:xmldb="http://apache.org/cocoon/xmldb/1.0"
>   resources="0" collections="0"
>   base="xmldb:xindice://localhost:8080/db/testcol/"/>
>
> Going after http://localhost:8080/cocoon/nina/remote/addissue/ gave me the
following (I'm truncating the list).
>
> <?xml version="1.0" encoding="ISO-8859-1"?>
> <xmldb:collections xmlns:xmldb="http://apache.org/cocoon/xmldb/1.0"
>   resources="100" collections="0"
>   base="xmldb:xindice://localhost:8080/db/addissue/">
>   <xmldb:resource xmlns:xmldb="http://apache.org/cocoon/xmldb/1.0"
>     name="out00.xml"/>
>   <xmldb:resource xmlns:xmldb="http://apache.org/cocoon/xmldb/1.0"
>     name="out01.xml"/>
>   <xmldb:resource xmlns:xmldb="http://apache.org/cocoon/xmldb/1.0"
>     name="out02.xml"/>
>   <xmldb:resource xmlns:xmldb="http://apache.org/cocoon/xmldb/1.0"
>     name="out03.xml"/>
>
>   (etc)
>
> </xmldb:collections>
>
> I can then bring up a specific resource with
> http://localhost:8080/cocoon/nina/remote/addissue/<resource-name>
>
> Another thought - what browser are you using?  I am using Firefox 0.8 on both the
Windows/2000 and Fedora Core 1 systems.  Could this be a browser artifact?
>
> Other than that, and making sure you built Cocoon with all of the block enabled
(the xmldb block should work), I can't think of anything off-hand.
>
> I hope this helps
>
> /mde/
> just my two cents . . . .
>


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


Mime
View raw message