Hello,
I've created a new TDB2 dataset using Jena 3.7.0. I'm now trying to run the
tdbstats script on the command line (in Windows using the tdbstats.bat script).
When running this I get an exception "Unable to check TDB lock owner as the
lock file contains invalid data" (stack trace below signature).
This is a fresh TDB dataset with multiple named graphs, which I've deleted and
re-created but still get the same error.
There's no tb2.tdbstats script in the jena/bin directory despite references in
the documentation that TDB1 and TDB2 are incompatible and there being other
tdb2.* scripts.
Is the tdbstats script for TDB2 not implemented?
Also, is there a TDB API method to run tdbstats?
This is useful in my use case where a lot of TDB datasets are being created.
I've managed to piece together a method from the source code but would like to
validate it against the released tdbstats script.
It may also be useful for others to have access to this kind of method from the
TDB API as setting up the Jena scripts is quite convoluted on Windows.
Thanks,
Greg
org.apache.jena.tdb.base.file.FileException: Unable to check TDB lock owner as
the lock file contains invalid data
at
org.apache.jena.tdb.base.file.LocationLock.getOwner(LocationLock.java:111)
at
org.apache.jena.tdb.base.file.LocationLock.canObtain(LocationLock.java:130)
at
org.apache.jena.tdb.StoreConnection._makeAndCache(StoreConnection.java:259)
at org.apache.jena.tdb.StoreConnection.make(StoreConnection.java:231)
at org.apache.jena.tdb.StoreConnection.make(StoreConnection.java:237)
at
org.apache.jena.tdb.transaction.DatasetGraphTransaction.<init>(DatasetGraphTransaction.java:73)
at org.apache.jena.tdb.sys.TDBMaker._create(TDBMaker.java:55)
at
org.apache.jena.tdb.sys.TDBMaker.createDatasetGraphTransaction(TDBMaker.java:42)
at
org.apache.jena.tdb.TDBFactory._createDatasetGraph(TDBFactory.java:89)
at org.apache.jena.tdb.TDBFactory.createDatasetGraph(TDBFactory.java:71)
at org.apache.jena.tdb.TDBFactory.createDataset(TDBFactory.java:55)
at tdb.cmdline.ModTDBDataset.createDataset(ModTDBDataset.java:103)
at arq.cmdline.ModDataset.getDataset(ModDataset.java:36)
at tdb.cmdline.CmdTDB.getDataset(CmdTDB.java:80)
at tdb.cmdline.CmdTDB.getDatasetGraph(CmdTDB.java:71)
at tdb.cmdline.CmdTDB.getDatasetGraphTDB(CmdTDB.java:75)
at tdb.tdbstats.exec(tdbstats.java:98)
at jena.cmd.CmdMain.mainMethod(CmdMain.java:93)
at jena.cmd.CmdMain.mainRun(CmdMain.java:58)
at jena.cmd.CmdMain.mainRun(CmdMain.java:45)
at tdb.tdbstats.main(tdbstats.java:44)
Caused by: java.lang.NumberFormatException: For input string: "15304
"
at java.lang.NumberFormatException.forInputString(Unknown Source)
at java.lang.Integer.parseInt(Unknown Source)
at java.lang.Integer.parseInt(Unknown Source)
at
org.apache.jena.tdb.base.file.LocationLock.getOwner(LocationLock.java:106)
... 20 more