Taking the resources out of my fat jar resolved this issue. I should add that as I'm running this pipeline in Spark I had to set the related HSQLDBs to read-only to permit simultaneous reads. Is there any reason they are not set to read-only to begin with?
Mike On Thu, Sep 28, 2017 at 6:27 PM, James Masanz <[email protected]> wrote: > > I would expect that if you copy the LVG resources out of your UberJar, it > should resolve the issue. > Modifying the lvg.properties file generally causes problems. > Following the hints in the 30/Jul/17 23:06 update to CTAKES-445 > <https://issues.apache.org/jira/browse/CTAKES-445> should work without > your having to modify the lvg.properties file. > > I haven't tested the patch to CTAKES-445 > <https://issues.apache.org/jira/browse/CTAKES-445> myself yet so I don't > know whether it takes care of the problem in this case. I do know that the > ctakes-lvg code does a change directory (cd) to where it expects the LVG > resources to be, or at least that's what it used to do when I last looked > at it. I suspect trying to cd into a jar is the problem you are seeing. > I'll have to revisit that when I look at that patch. > > -- James > > > > On Tue, Sep 26, 2017 at 5:53 PM, Michael Trepanier <[email protected]> > wrote: > >> I am attempting to run cTAKES from an executable UberJar. While the fast >> pipeline seems to run correctly (in terms of producing an output), when >> stepping through the LvgAnnotator related steps, cTAKES produces the below >> error. >> >> 26 Sep 2017 22:47:01 INFO LvgAnnotator - URL for lvg.properties >> =file:/home/mike/ctakes-assembly-4.0.jar!/org/apache/ctakes/lvg/data/config/lvg.properties >> 26 Sep 2017 22:47:01 INFO SentenceDetector - Sentence detector model file: >> org/apache/ctakes/core/sentdetect/sd-med-model.zip >> 26 Sep 2017 22:47:01 INFO TokenizerAnnotatorPTB - Initializing >> org.apache.ctakes.core.ae.TokenizerAnnotatorPTB >> 26 Sep 2017 22:47:01 INFO LvgCmdApiResourceImpl - Loading NLM Norm and Lvg >> with config file = >> jar:file:/home/mike/ctakes-assembly-4.0.jar!/org/apache/ctakes/lvg/data/config/lvg.properties >> 26 Sep 2017 22:47:01 INFO LvgCmdApiResourceImpl - config file absolute >> path = >> /home/mike/jar:file:/home/mike/ctakes-assembly-4.0.jar!/org/apache/ctakes/lvg/data/config/lvg.properties >> 26 Sep 2017 22:47:01 INFO LvgCmdApiResourceImpl - cwd = /home/mike >> 26 Sep 2017 22:47:01 INFO LvgCmdApiResourceImpl - cd >> jar:file:/home/mike/ctakes-assembly-4.0.jar!/org/apache/ctakes/lvg/ >> ** Configuration Error: >> jar:file:/home/mike/ctakes-assembly-4.0.jar!/org/apache/ctakes/lvg/data/config/lvg.properties >> (No such file or directory) >> ** Error: problem of opening/reading config file: >> 'jar:file:/home/mike/ctakes-assembly-4.0.jar!/org/apache/ctakes/lvg/data/config/lvg.properties'. >> Use -x option to specify the config file path. >> ** Configuration Error: >> jar:file:/home/mike/ctakes-assembly-4.0.jar!/org/apache/ctakes/lvg/data/config/lvg.properties >> (No such file or directory) >> ** Error: problem of opening/reading config file: >> 'jar:file:/home/mike/ctakes-assembly-4.0.jar!/org/apache/ctakes/lvg/data/config/lvg.properties'. >> Use -x option to specify the config file path. >> >> Would taking the additional cTAKES resources out of the UberJar resolve >> this issue? And if so, can I use the lvg.properties file to set where these >> resources should be? >> >> Note, as mentioned before, this error does not cause cTAKES to crash; I >> am just worried it may be impacting the output. As well, I have implemented >> the patch outlined at https://issues.apache.org/jira/browse/CTAKES-445 >> >> >> Regards, >> >> Mike >> >> -- >> [image: MetiStream Logo - 500] >> Mike Trepanier| Big Data Engineer | MetiStream, Inc. | >> [email protected] | 845 - 270 - 3129 <(845)%20270-3129> (m) | >> www.metistream.com >> > > -- [image: MetiStream Logo - 500] Mike Trepanier| Big Data Engineer | MetiStream, Inc. | [email protected] | 845 - 270 - 3129 (m) | www.metistream.com
