You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@stanbol.apache.org by "Rupert Westenthaler (JIRA)" <ji...@apache.org> on 2012/05/10 16:49:48 UTC
[jira] [Created] (STANBOL-610) Indexing Directory parameter does
not work for the genericrdf Indexing Tool
Rupert Westenthaler created STANBOL-610:
-------------------------------------------
Summary: Indexing Directory parameter does not work for the genericrdf Indexing Tool
Key: STANBOL-610
URL: https://issues.apache.org/jira/browse/STANBOL-610
Project: Stanbol
Issue Type: Bug
Reporter: Rupert Westenthaler
Assignee: Rupert Westenthaler
Priority: Minor
Fix For: 0.10.0-incubating
If a custom indexing directory is parsed
e.g.
java -Xmx1024m -jar bin/org.apache.stanbol.entityhub.indexing.genericrdf-0.9.0-incubating-SNAPSHOT-jar-with-dependencies.jar
index ./data
The call results in an Error like this:
15:49:02,094 [main] INFO config.IndexingConfig - Indexing directory:
/home/seralf/Scrivania/indici/prova/indexing
15:49:02,096 [main] INFO config.IndexingConfig - No 'indexing.properties'
found via classpath. Loading Resource viathe classpath is deactivated.
15:49:02,096 [main] INFO config.IndexingConfig - Classpath Indexing Root
null
15:49:02,096 [main] INFO config.IndexingConfig - request for Resource
indexing.properties (folder: prova/indexing/config)
15:49:02,096 [main] INFO config.IndexingConfig - > rquested Resource not
found
Exception in thread "main" java.lang.IllegalArgumentException: Unable to
find configuration file 'indexing.properties'!
at org.apache.stanbol.entityhub.indexing.core.config.IndexingConfig.loadConfig(IndexingConfig.java:592)
at org.apache.stanbol.entityhub.indexing.core.config.IndexingConfig.<init>(IndexingConfig.java:278)
at org.apache.stanbol.entityhub.indexing.core.IndexerFactory.create(IndexerFactory.java:80)
at org.apache.stanbol.entityhub.indexing.Main.main(Main.java:64)
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Resolved] (STANBOL-610) Indexing Directory parameter does
not work for the genericrdf Indexing Tool
Posted by "Rupert Westenthaler (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/STANBOL-610?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Rupert Westenthaler resolved STANBOL-610.
-----------------------------------------
Resolution: Fixed
fixed with #1337129
> Indexing Directory parameter does not work for the genericrdf Indexing Tool
> ---------------------------------------------------------------------------
>
> Key: STANBOL-610
> URL: https://issues.apache.org/jira/browse/STANBOL-610
> Project: Stanbol
> Issue Type: Bug
> Reporter: Rupert Westenthaler
> Assignee: Rupert Westenthaler
> Priority: Minor
> Fix For: 0.10.0-incubating
>
>
> If a custom indexing directory is parsed
> e.g.
> java -Xmx1024m -jar bin/org.apache.stanbol.entityhub.indexing.genericrdf-0.9.0-incubating-SNAPSHOT-jar-with-dependencies.jar
> index ./data
> The call results in an Error like this:
> 15:49:02,094 [main] INFO config.IndexingConfig - Indexing directory:
> /home/seralf/Scrivania/indici/prova/indexing
> 15:49:02,096 [main] INFO config.IndexingConfig - No 'indexing.properties'
> found via classpath. Loading Resource viathe classpath is deactivated.
> 15:49:02,096 [main] INFO config.IndexingConfig - Classpath Indexing Root
> null
> 15:49:02,096 [main] INFO config.IndexingConfig - request for Resource
> indexing.properties (folder: prova/indexing/config)
> 15:49:02,096 [main] INFO config.IndexingConfig - > rquested Resource not
> found
> Exception in thread "main" java.lang.IllegalArgumentException: Unable to
> find configuration file 'indexing.properties'!
> at org.apache.stanbol.entityhub.indexing.core.config.IndexingConfig.loadConfig(IndexingConfig.java:592)
> at org.apache.stanbol.entityhub.indexing.core.config.IndexingConfig.<init>(IndexingConfig.java:278)
> at org.apache.stanbol.entityhub.indexing.core.IndexerFactory.create(IndexerFactory.java:80)
> at org.apache.stanbol.entityhub.indexing.Main.main(Main.java:64)
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (STANBOL-610) Indexing Directory parameter does
not work for the genericrdf Indexing Tool
Posted by "Rupert Westenthaler (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/STANBOL-610?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13273059#comment-13273059 ]
Rupert Westenthaler commented on STANBOL-610:
---------------------------------------------
The problem is that the full path is used to lookup resources within the CLASSPATH. So if the user parses a directory those resource can no longer be loaded via the classpath.
Even worse during initialization the "indexing.properties" file is loaded via the CLASSPATH to obtain the base URL from the JAR file containing the default configuration. This is done regardless if the configured folder already consists a full configuration or not and also is actual cause for the reported error.
I am currently working on a fix for this problem. However this will break several unit tests as they relay on the reported misbehavior. So fixing this will also require to change the tests accordingly.
> Indexing Directory parameter does not work for the genericrdf Indexing Tool
> ---------------------------------------------------------------------------
>
> Key: STANBOL-610
> URL: https://issues.apache.org/jira/browse/STANBOL-610
> Project: Stanbol
> Issue Type: Bug
> Reporter: Rupert Westenthaler
> Assignee: Rupert Westenthaler
> Priority: Minor
> Fix For: 0.10.0-incubating
>
>
> If a custom indexing directory is parsed
> e.g.
> java -Xmx1024m -jar bin/org.apache.stanbol.entityhub.indexing.genericrdf-0.9.0-incubating-SNAPSHOT-jar-with-dependencies.jar
> index ./data
> The call results in an Error like this:
> 15:49:02,094 [main] INFO config.IndexingConfig - Indexing directory:
> /home/seralf/Scrivania/indici/prova/indexing
> 15:49:02,096 [main] INFO config.IndexingConfig - No 'indexing.properties'
> found via classpath. Loading Resource viathe classpath is deactivated.
> 15:49:02,096 [main] INFO config.IndexingConfig - Classpath Indexing Root
> null
> 15:49:02,096 [main] INFO config.IndexingConfig - request for Resource
> indexing.properties (folder: prova/indexing/config)
> 15:49:02,096 [main] INFO config.IndexingConfig - > rquested Resource not
> found
> Exception in thread "main" java.lang.IllegalArgumentException: Unable to
> find configuration file 'indexing.properties'!
> at org.apache.stanbol.entityhub.indexing.core.config.IndexingConfig.loadConfig(IndexingConfig.java:592)
> at org.apache.stanbol.entityhub.indexing.core.config.IndexingConfig.<init>(IndexingConfig.java:278)
> at org.apache.stanbol.entityhub.indexing.core.IndexerFactory.create(IndexerFactory.java:80)
> at org.apache.stanbol.entityhub.indexing.Main.main(Main.java:64)
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (STANBOL-610) Indexing Directory parameter does
not work for the genericrdf Indexing Tool
Posted by "Fabian Christ (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/STANBOL-610?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Fabian Christ updated STANBOL-610:
----------------------------------
Component/s: Entity Hub
> Indexing Directory parameter does not work for the genericrdf Indexing Tool
> ---------------------------------------------------------------------------
>
> Key: STANBOL-610
> URL: https://issues.apache.org/jira/browse/STANBOL-610
> Project: Stanbol
> Issue Type: Bug
> Components: Entity Hub
> Affects Versions: 0.9.0-incubating
> Reporter: Rupert Westenthaler
> Assignee: Rupert Westenthaler
> Priority: Minor
>
> If a custom indexing directory is parsed
> e.g.
> java -Xmx1024m -jar bin/org.apache.stanbol.entityhub.indexing.genericrdf-0.9.0-incubating-SNAPSHOT-jar-with-dependencies.jar
> index ./data
> The call results in an Error like this:
> 15:49:02,094 [main] INFO config.IndexingConfig - Indexing directory:
> /home/seralf/Scrivania/indici/prova/indexing
> 15:49:02,096 [main] INFO config.IndexingConfig - No 'indexing.properties'
> found via classpath. Loading Resource viathe classpath is deactivated.
> 15:49:02,096 [main] INFO config.IndexingConfig - Classpath Indexing Root
> null
> 15:49:02,096 [main] INFO config.IndexingConfig - request for Resource
> indexing.properties (folder: prova/indexing/config)
> 15:49:02,096 [main] INFO config.IndexingConfig - > rquested Resource not
> found
> Exception in thread "main" java.lang.IllegalArgumentException: Unable to
> find configuration file 'indexing.properties'!
> at org.apache.stanbol.entityhub.indexing.core.config.IndexingConfig.loadConfig(IndexingConfig.java:592)
> at org.apache.stanbol.entityhub.indexing.core.config.IndexingConfig.<init>(IndexingConfig.java:278)
> at org.apache.stanbol.entityhub.indexing.core.IndexerFactory.create(IndexerFactory.java:80)
> at org.apache.stanbol.entityhub.indexing.Main.main(Main.java:64)
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Issue Comment Edited] (STANBOL-610) Indexing Directory
parameter does not work for the genericrdf Indexing Tool
Posted by "Rupert Westenthaler (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/STANBOL-610?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13273059#comment-13273059 ]
Rupert Westenthaler edited comment on STANBOL-610 at 5/11/12 5:47 AM:
----------------------------------------------------------------------
The problem is that the parsed path is also used to look up resources within the CLASSPATH. But in the CLASSPATH resources need to be looked up with no prefix! Because of that loading missing resources via the CLASSPATH fails as soon as a custom directory is parsed as 2nd parameter for the Indexing Tool.
Even worse during initialization the "indexing.properties" file is loaded via the CLASSPATH to obtain the base URL from the JAR file containing the default configuration. This is done regardless if the configured folder already consists a full configuration or not and also is actual cause for the reported error.
I am currently working on a fix for this problem. However this will break several unit tests as they relay on the reported misbehavior - in the test the different test resources are actually copied to the classpath under the full relative folder including the custom prefix. So fixing this will also require to change the tests accordingly.
was (Author: rwesten):
The problem is that the full path is used to lookup resources within the CLASSPATH. So if the user parses a directory those resource can no longer be loaded via the classpath.
Even worse during initialization the "indexing.properties" file is loaded via the CLASSPATH to obtain the base URL from the JAR file containing the default configuration. This is done regardless if the configured folder already consists a full configuration or not and also is actual cause for the reported error.
I am currently working on a fix for this problem. However this will break several unit tests as they relay on the reported misbehavior. So fixing this will also require to change the tests accordingly.
> Indexing Directory parameter does not work for the genericrdf Indexing Tool
> ---------------------------------------------------------------------------
>
> Key: STANBOL-610
> URL: https://issues.apache.org/jira/browse/STANBOL-610
> Project: Stanbol
> Issue Type: Bug
> Reporter: Rupert Westenthaler
> Assignee: Rupert Westenthaler
> Priority: Minor
> Fix For: 0.10.0-incubating
>
>
> If a custom indexing directory is parsed
> e.g.
> java -Xmx1024m -jar bin/org.apache.stanbol.entityhub.indexing.genericrdf-0.9.0-incubating-SNAPSHOT-jar-with-dependencies.jar
> index ./data
> The call results in an Error like this:
> 15:49:02,094 [main] INFO config.IndexingConfig - Indexing directory:
> /home/seralf/Scrivania/indici/prova/indexing
> 15:49:02,096 [main] INFO config.IndexingConfig - No 'indexing.properties'
> found via classpath. Loading Resource viathe classpath is deactivated.
> 15:49:02,096 [main] INFO config.IndexingConfig - Classpath Indexing Root
> null
> 15:49:02,096 [main] INFO config.IndexingConfig - request for Resource
> indexing.properties (folder: prova/indexing/config)
> 15:49:02,096 [main] INFO config.IndexingConfig - > rquested Resource not
> found
> Exception in thread "main" java.lang.IllegalArgumentException: Unable to
> find configuration file 'indexing.properties'!
> at org.apache.stanbol.entityhub.indexing.core.config.IndexingConfig.loadConfig(IndexingConfig.java:592)
> at org.apache.stanbol.entityhub.indexing.core.config.IndexingConfig.<init>(IndexingConfig.java:278)
> at org.apache.stanbol.entityhub.indexing.core.IndexerFactory.create(IndexerFactory.java:80)
> at org.apache.stanbol.entityhub.indexing.Main.main(Main.java:64)
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (STANBOL-610) Indexing Directory parameter does
not work for the genericrdf Indexing Tool
Posted by "Rupert Westenthaler (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/STANBOL-610?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13273190#comment-13273190 ]
Rupert Westenthaler commented on STANBOL-610:
---------------------------------------------
To fix this bug, while keeping the UnitTest working I had to implement a new Feature (kept protected for now) that allows to set the CLASSPATH offset for initializing resources.
This is used by the unit tests to load the different test configurations. However this would also allow to include different default configurations within the genericrdf indexing tool.
This might be interesting as it could allow to merge all the different indexing tool configurations into a single module and therefore remove the
* entityhub/indexing/dbpedia
* entityhub/indexing/dblp
module
In addition it would male it much easier to provide additional configurations e.g. for indexing vCard files, other data sets like musicbrainz ...
However all this is not really related to this issue. So I will rather create an own issue for that.
> Indexing Directory parameter does not work for the genericrdf Indexing Tool
> ---------------------------------------------------------------------------
>
> Key: STANBOL-610
> URL: https://issues.apache.org/jira/browse/STANBOL-610
> Project: Stanbol
> Issue Type: Bug
> Reporter: Rupert Westenthaler
> Assignee: Rupert Westenthaler
> Priority: Minor
> Fix For: 0.10.0-incubating
>
>
> If a custom indexing directory is parsed
> e.g.
> java -Xmx1024m -jar bin/org.apache.stanbol.entityhub.indexing.genericrdf-0.9.0-incubating-SNAPSHOT-jar-with-dependencies.jar
> index ./data
> The call results in an Error like this:
> 15:49:02,094 [main] INFO config.IndexingConfig - Indexing directory:
> /home/seralf/Scrivania/indici/prova/indexing
> 15:49:02,096 [main] INFO config.IndexingConfig - No 'indexing.properties'
> found via classpath. Loading Resource viathe classpath is deactivated.
> 15:49:02,096 [main] INFO config.IndexingConfig - Classpath Indexing Root
> null
> 15:49:02,096 [main] INFO config.IndexingConfig - request for Resource
> indexing.properties (folder: prova/indexing/config)
> 15:49:02,096 [main] INFO config.IndexingConfig - > rquested Resource not
> found
> Exception in thread "main" java.lang.IllegalArgumentException: Unable to
> find configuration file 'indexing.properties'!
> at org.apache.stanbol.entityhub.indexing.core.config.IndexingConfig.loadConfig(IndexingConfig.java:592)
> at org.apache.stanbol.entityhub.indexing.core.config.IndexingConfig.<init>(IndexingConfig.java:278)
> at org.apache.stanbol.entityhub.indexing.core.IndexerFactory.create(IndexerFactory.java:80)
> at org.apache.stanbol.entityhub.indexing.Main.main(Main.java:64)
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira