From: Andrzej J. T. <an...@ch...> - 2011-04-28 04:44:45
|
When I try to create a collection that already exists using the eXist Ant task: <exist:create uri="${exist.url}/xmlrpc/db" collection="mycollection" user="${userid}" password="${password}"/> I get a NPE something like this: 28 Apr 2011 00:29:16,688 ["http-bio-/127.0.0.1-80"-exec-7] ERROR (XmlRpcErrorLogger.java [log]:36) - Failed to invoke method describeCollection in class org.exist.xmlrpc.RpcConnection: java.lang.NullPointerException or this: 28 Apr 2011 00:27:09,666 ["http-bio-/127.0.0.1-80"-exec-4] ERROR (XmlRpcErrorLogger.java [log]:36) - Failed to invoke method createCollection in class org.exist.xmlrpc.RpcConnection: java.lang.NullPointerException and further down in the stack trace, the culprit seems to be: Caused by: java.lang.NullPointerException at org.exist.security.UnixStylePermission.write(UnixStylePermission.java:448) at org.exist.collections.Collection.write(Collection.java:1514) at org.exist.storage.NativeBroker.saveCollection(NativeBroker.java:1268) at org.exist.xmlrpc.RpcConnection.createCollection(RpcConnection.java:175) which is this line in org.exist.security.UnixStylePermission.write(): ostream.writeInt(getOwner().getId()); so either the owner or the id is null. In the past, if you tried to create a collection that was already there, it was a no-op....which was convenient for when reloading stuff into the database using Ant, so I don't think this should be happening! Help please! PS...told ya security wasn't yet totally stable....figures I find all the edge-cases, eh? ;-) -- Andrzej Taramina Chaeron Corporation: Enterprise System Solutions http://www.chaeron.com |