feliperazeek / playframework-elasticsearch

Integrate Elastic Search in a Play! Framework Application. This module uses JPA events to notify Elastic Search of events of their own. It embeds a running Elastic Search instance for Rapid Development.
http://geeks.aretotally.in/play-framework-module-elastic-search-distributed-searching-with-json-http-rest-or-java
84 stars 43 forks source link

Allow user to override mapper factory (fix for #53) #54

Closed bgooren closed 12 years ago

bgooren commented 12 years ago

Hi Felipe,

Was just browsing the issue list, saw this issue and figured it was a quick fix.

Regards,

Sebastian

isamaru commented 12 years ago

I think you may have introduced a possible bug there: mappers cache is not reset when you change the factory, so it could keep giving you old instances. I think you should add mappers.clear() to the method setMapperFactory();

bgooren commented 12 years ago

That's true; My assumption was that you'll only change the mapper factory while the app is starting, so before any mappers are loaded.