You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-issues@jackrabbit.apache.org by "Jukka Zitting (JIRA)" <ji...@apache.org> on 2013/09/26 23:18:09 UTC

[jira] [Created] (OAK-1049) Blobs shouldn't be Comparable

Jukka Zitting created OAK-1049:
----------------------------------

             Summary: Blobs shouldn't be Comparable
                 Key: OAK-1049
                 URL: https://issues.apache.org/jira/browse/OAK-1049
             Project: Jackrabbit Oak
          Issue Type: Improvement
          Components: core
            Reporter: Jukka Zitting
            Assignee: Jukka Zitting


In OAK-350 Blobs were made Comparable to make them easier to compare in higher-level code.

Unfortunately the implementation is broken ({{compareTo}} is not transitive) and  potentially very slow for large binaries, which suggests that it shouldn't be exposed at least on the public API level.

Thus I suggest to drop the Comparable feature from Blobs and replace the few places where it is needed with {{equals()}} checks or explicit scanning of the streams.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira