You are viewing a plain text version of this content. The canonical link for it is here.
Posted to xindice-dev@xml.apache.org by Gary Hallmark <Ga...@oracle.com> on 2002/01/08 22:52:27 UTC
APIExample.java not working in Xindice 1.0rc1 (DarkHorse)
Hi folks,
The first issue is that the line
DatabaseManager.getCollection("xmldb:dbxml:///db/root/ocs");
apparently should be changed to
DatabaseManager.getCollection("xmldb:xindice:///db/system");
in order to avoid an early demise due to a null pointer exception.
The next issue is that after the above change, the console output is
Database Name db
SysAccess
SysGroups
SysObjects
SysConfig
SysUsers
SysSymbols
Error creating document '<?xml version="1.0"?>
<test>Hello</test>'
Document Key: test
Retrieving Document using getResource
test
ERROR : org.xmldb.api.base.XMLDBException: Collection No IndexManager
org.xmldb.api.base.XMLDBException: Collection No IndexManager
org.xmldb.api.base.XMLDBException
org.apache.xindice.core.FaultCodes.createXMLDBException(java.lang.Exception)
FaultCodes.java:239
org.xmldb.api.base.Resource
org.apache.xindice.client.xmldb.CollectionImpl.getResource(java.lang.String)
CollectionImpl.java:404
void
org.apache.xindice.examples.APIExample.retrieveDocument(org.xmldb.api.base.Collection,
java.lang.String)
APIExample.java:157
void org.apache.xindice.examples.APIExample.main(java.lang.String[])
APIExample.java:99
I can keep plugging along, as its' a great way to learn the code, but you
folks probably know what's up right away...
Thanks!
Re: Initial DB config was Re: APIExample.java not working in Xindice 1.0rc1 (DarkHorse)
Posted by Kimbro Staken <ks...@dbxmlgroup.com>.
On Tuesday, January 8, 2002, at 05:38 PM, Tom Bradford wrote:
>
> It was an oversight... I forgot we even have examples :-)
> We should probably add a task to the example build or execution scripts
> to create the collections if needed.
>
More likely a step or two should be added to the install doc to create the
/db/root collection again. It could be good too as it will give people an
early indication of whether the server is setup right or not.
> --
> Tom Bradford - http://www.tbradford.org
> Developer - Apache Xindice (Native XML Database)
> Creator - Project Labrador (XML Object Broker)
>
>
Kimbro Staken
XML Database Software, Consulting and Writing
http://www.xmldatabases.org/
Re: Initial DB config was Re: APIExample.java not working in Xindice
1.0rc1 (DarkHorse)
Posted by Tom Bradford <br...@dbxmlgroup.com>.
Kimbro Staken wrote:
> In Xindice the database configuration was moved into the database and in
> the process the default collection configuration that is used by all the
> examples and documentation was eliminated. All the examples are now broken
> out of the box. Was this change intentional or is it a bug?
It was an oversight... I forgot we even have examples :-)
We should probably add a task to the example build or execution scripts
to create the collections if needed.
--
Tom Bradford - http://www.tbradford.org
Developer - Apache Xindice (Native XML Database)
Creator - Project Labrador (XML Object Broker)
Initial DB config was Re: APIExample.java not working in Xindice 1.0rc1 (DarkHorse)
Posted by Kimbro Staken <ks...@dbxmlgroup.com>.
Create a regular collection using the command line tools, don't use system.
In Xindice the database configuration was moved into the database and in
the process the default collection configuration that is used by all the
examples and documentation was eliminated. All the examples are now broken
out of the box. Was this change intentional or is it a bug?
On Tuesday, January 8, 2002, at 02:52 PM, Gary Hallmark wrote:
> Hi folks,
>
> The first issue is that the line
>
> DatabaseManager.getCollection("xmldb:dbxml:///db/root/ocs");
>
> apparently should be changed to
>
> DatabaseManager.getCollection("xmldb:xindice:///db/system");
>
> in order to avoid an early demise due to a null pointer exception.
>
> The next issue is that after the above change, the console output is
>
> Database Name db
>
> SysAccess
>
> SysGroups
>
> SysObjects
>
> SysConfig
>
> SysUsers
>
> SysSymbols
>
> Error creating document '<?xml version="1.0"?>
> <test>Hello</test>'
>
> Document Key: test
>
> Retrieving Document using getResource
>
> test
>
> ERROR : org.xmldb.api.base.XMLDBException: Collection No IndexManager
>
> org.xmldb.api.base.XMLDBException: Collection No IndexManager
>
> org.xmldb.api.base.XMLDBException
> org.apache.xindice.core.FaultCodes.createXMLDBException(java.lang.Exception)
>
> FaultCodes.java:239
>
> org.xmldb.api.base.Resource
> org.apache.xindice.client.xmldb.CollectionImpl.getResource(java.lang.String)
>
> CollectionImpl.java:404
>
> void
> org.apache.xindice.examples.APIExample.retrieveDocument(org.xmldb.api.base.
> Collection, java.lang.String)
>
> APIExample.java:157
>
> void org.apache.xindice.examples.APIExample.main(java.lang.String[])
>
> APIExample.java:99
>
> I can keep plugging along, as its' a great way to learn the code, but you
> folks probably know what's up right away...
>
> Thanks!
>
>
>
Kimbro Staken
XML Database Software, Consulting and Writing
http://www.xmldatabases.org/