java.asciidoc 1.3 KB

1234567891011121314151617181920212223242526272829303132333435
  1. [float]
  2. [[breaking_80_java_changes]]
  3. === Java API changes
  4. //NOTE: The notable-breaking-changes tagged regions are re-used in the
  5. //Installation and Upgrade Guide
  6. //tag::notable-breaking-changes[]
  7. // end::notable-breaking-changes[]
  8. [float]
  9. ==== Changes to Fuzziness
  10. To create `Fuzziness` instances, use the `fromString` and `fromEdits` method
  11. instead of the `build` method that used to accept both Strings and numeric
  12. values. Several fuzziness setters on query builders (e.g.
  13. MatchQueryBuilder#fuzziness) now accept only a `Fuzziness`instance instead of
  14. an Object. You should preferably use the available constants (e.g.
  15. Fuzziness.ONE, Fuzziness.AUTO) or build your own instance using the above
  16. mentioned factory methods.
  17. Fuzziness used to be lenient when it comes to parsing arbitrary numeric values
  18. while silently truncating them to one of the three allowed edit distances 0, 1
  19. or 2. This leniency is now removed and the class will throw errors when trying
  20. to construct an instance with another value (e.g. floats like 1.3 used to get
  21. accepted but truncated to 1). You should use one of the allowed values.
  22. [float]
  23. ==== Changes to Repository
  24. Repository has no dependency on IndexShard anymore. The contract of restoreShard
  25. and snapshotShard has been reduced to Store and MappingService in order to improve
  26. testability.