I'm seeing strange exceptions being thrown, seemingly undeterministically by HFST optimized lookup java code.
I suspect this may be a thread-safety issue with HFST optimized lookup.
For example the following exception gets thrown by HFST when I run our application:
java.lang.ArrayIndexOutOfBoundsException: Array index out of range: 1
java.lang.ArrayIndexOutOfBoundsException: Array index out of range: 1
at java.util.Vector.get(Vector.java:748) ~[na:1.8.0_45]
at net.sf.hfst.UnweightedTransducer.findIndex(Unknown Source) ~[meta-assembly-0.1-SNAPSHOT.jar:0.1-SNAPSHOT]
at net.sf.hfst.UnweightedTransducer.getAnalyses(Unknown Source) ~[meta-assembly-0.1-SNAPSHOT.jar:0.1-SNAPSHOT]
at net.sf.hfst.UnweightedTransducer.tryEpsilonTransitions(Unknown Source) ~[meta-assembly-0.1-SNAPSHOT.jar:0.1-SNAPSHOT]
at net.sf.hfst.UnweightedTransducer.tryEpsilonIndices(Unknown Source) ~[meta-assembly-0.1-SNAPSHOT.jar:0.1-SNAPSHOT]
at net.sf.hfst.UnweightedTransducer.getAnalyses(Unknown Source) ~[meta-assembly-0.1-SNAPSHOT.jar:0.1-SNAPSHOT]
at net.sf.hfst.UnweightedTransducer.findTransitions(Unknown Source) ~[meta-assembly-0.1-SNAPSHOT.jar:0.1-SNAPSHOT]
at net.sf.hfst.UnweightedTransducer.findIndex(Unknown Source) ~[meta-assembly-0.1-SNAPSHOT.jar:0.1-SNAPSHOT]
at net.sf.hfst.UnweightedTransducer.getAnalyses(Unknown Source) ~[meta-assembly-0.1-SNAPSHOT.jar:0.1-SNAPSHOT]
at net.sf.hfst.UnweightedTransducer.analyze(Unknown Source) ~[meta-assembly-0.1-SNAPSHOT.jar:0.1-SNAPSHOT]
...
please note that a HFST OL Java fork that claims to be thread-safe already exists: https://github.com/jiemakel/seco-hfst
perhaps, license permitting, this code could be merged with the HFST code base.
Last edit: Marko Asplund 2015-08-12