Hi Jakob,
Yes, there is currently a limitation in the LVG component to have
their jar unpacked and added to the classpath.
I think there is an outstanding Jira to enable it read it from a jar
like the rest of the jars.  (There are some limitations such as
hsql/lucene not being able to read directly from a jar hence it's been
outstanding.)
--Pei

On Fri, Aug 28, 2015 at 4:26 AM, Jakob Rogstadius
<[email protected]> wrote:
> Hi,
>
> On line 579 in org.apache.ctakes.lvg.ae.LvgAnnotator there is the following 
> resource import:
>           ExternalResourceFactory.createExternalResourceDescription(
>               LvgCmdApiResourceImpl.class,
>               new File(LvgCmdApiResourceImpl.class.getResource(
>                   
> "/org/apache/ctakes/lvg/data/config/lvg.properties").toURI()))
>           );
>
> The .getResource() call breaks when the package is imported as a jar (from 
> Maven central), with an error stating that the "URI is not hierarchical". 
> According to:
> http://stackoverflow.com/questions/18055189/why-my-uri-is-not-hierarchical
> the call should instead use .getResourceAsStream().
>
> Is this a bug, or am I doing something wrong? I'm not very familiar with how 
> Java handles resources in general.
>
> Jakob

Reply via email to