[ https://issues.apache.org/jira/browse/SOLR-14971?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17230134#comment-17230134 ]
ASF subversion and git services commented on SOLR-14971: -------------------------------------------------------- Commit 8e9db02530d42a45c9ef89d93ea37f340c9a426c in lucene-solr's branch refs/heads/branch_8x from Jason Gerlowski [ https://gitbox.apache.org/repos/asf?p=lucene-solr.git;h=8e9db02 ] SOLR-14971: Handle atomic-removes on uncommitted docs (#2056) Docs fetched from the update log via RTG look different than docs fetched from commits in the index: the types of field-values may be different between the two, etc. This is a problem for atomic add/remove of field values, where matching existing values has historically been done by object equals() calls (via Collection operations). This relies on equality checks which don't have flexible enough semantics to match values across these different types. (For example, `new Long(1).equals(new Integer(1))` returns `false`). This was causing some add-distinct and remove operations on uncommitted values to silently fail to remove field values. This commit patches over this by converting between types in the more common cases before using the fallback behavior. > AtomicUpdate 'remove' fails on 'pints' fields > --------------------------------------------- > > Key: SOLR-14971 > URL: https://issues.apache.org/jira/browse/SOLR-14971 > Project: Solr > Issue Type: Bug > Security Level: Public(Default Security Level. Issues are Public) > Components: update > Affects Versions: 8.5.2 > Reporter: Jason Gerlowski > Assignee: Jason Gerlowski > Priority: Major > Attachments: reproduce.sh > > Time Spent: 1h > Remaining Estimate: 0h > > The "remove" atomic update action on multivalued int fields fails if the > document being changed is uncommitted. > At first glance this appears to be a type-related issue. > AtomicUpdateDocumentMerger attempts to handle multivalued int fields by > processing the List<Integer> type, but in uncommitted docs int fields are > still List<String> in the tlog. Conceptually this feels similar to > SOLR-13331. > It's likely this issue also affects other numeric and date fields. > Attached is a simple script to reproduce, meant to be run from the root of a > Solr install. -- This message was sent by Atlassian Jira (v8.3.4#803005) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org