Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make mappings immutable. #15313

Merged
merged 1 commit into from
Dec 15, 2015
Merged

Commits on Dec 15, 2015

  1. Make mappings immutable.

    Today mappings are mutable because of two APIs:
     - Mapper.merge, which expects changes to be performed in-place
     - IncludeInAll, which allows to change whether values should be put in the
       `_all` field in place.
    
    This commit changes both APIs to return a modified copy instead of modifying in
    place so that mappings can be immutable. For now, only the type-level object is
    immutable, but in the future we can imagine making them immutable at the
    index-level so that mapping updates could be completely atomic at the index
    level.
    
    Close elastic#9365
    jpountz committed Dec 15, 2015
    Configuration menu
    Copy the full SHA
    50eeafa View commit details
    Browse the repository at this point in the history