avanco commented on a change in pull request #385:
URL: https://github.com/apache/opennlp/pull/385#discussion_r541297605
##########
File path:
opennlp-morfologik-addon/src/main/java/opennlp/morfologik/lemmatizer/MorfologikLemmatizer.java
##########
@@ -47,7 +47,7 @@ public MorfologikLemmatizer(Dictionary dictionary) throws
IllegalArgumentExcepti
dictLookup = new DictionaryLookup(dictionary);
}
- private List<String> lemmatize(String word, String postag) {
+ private synchronized List<String> lemmatize(String word, String postag) {
Review comment:
Yes, I tried locking only around `dictLookup`, but the List returned by
`lookup` method (morfologik code) returns a reference for an object that is
created only once, maybe for performance reasons, I don't know :(
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]