Remove hand-coded XContent duplicate checks#34588
Remove hand-coded XContent duplicate checks#34588danielmitterdorfer merged 4 commits intoelastic:masterfrom
Conversation
With this commit we cleanup hand-coded duplicate checks in XContent parsing. They were necessary previously but since we reconfigured the underlying parser in elastic#22073 and elastic#22225, these checks are obsolete and were also ineffective unless an undocumented system property has been set. As we also remove this escape hatch, we can remove the additional checks as well. Closes elastic#22253
|
Pinging @elastic/es-core-infra |
|
Note to reviewers: I intentionally kept tests so we check that duplicates are indeed detected. |
I don't think we need to do this. This effectively amounts to unit tests of Jackson now that we defer to its behavior. I think a single test that each of the XContent parsers reject duplicates is sufficient, but we don't need to go to the individual uses of XContent parsers to test for duplicates. |
Fine for me. Then I'll remove these tests soon. For reference, the test that covers this is |
|
@elasticmachine test this please |
With this commit we cleanup hand-coded duplicate checks in XContent parsing. They were necessary previously but since we reconfigured the underlying parser in #22073 and #22225, these checks are obsolete and were also ineffective unless an undocumented system property has been set. As we also remove this escape hatch, we can remove the additional checks as well. Closes #22253 Relates #34588
The setting es.xcontent.strict_duplicate_detection was removed in 7.0 (see elastic#34588). It was an undocumented setting, but enough users relied on it that its absence is causing problems during upgrades. This commit adds a message to the deprecation log if this setting is present at startup.
#63500) * Add deprecation warning for removed setting The setting es.xcontent.strict_duplicate_detection was removed in 7.0 (see #34588). It was an undocumented setting, but enough users relied on it that its absence is causing problems during upgrades. This commit adds a message to the deprecation log if this setting is present at startup. * Spotless formatting * Avoid forbidden API * Reset between custom config tests * Spotless apply * Access system properties consistently * Revert changes to ConfigurationTests setup Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
With this commit we cleanup hand-coded duplicate checks in XContent
parsing. They were necessary previously but since we reconfigured the
underlying parser in #22073 and #22225, these checks are obsolete and
were also ineffective unless an undocumented system property has been
set. As we also remove this escape hatch, we can remove the additional
checks as well.
Closes #22253