mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

boli
18.18.2006 a38a5a4e58ecd155b6a09732822f245e6cef9580
Added FIXME tags to the previous commit (revision 179) to make sure we address the potential performance issues in the fix.

Fix for issue 573
1 files modified
4 ■■■■ changed files
opendj-sdk/opends/src/server/org/opends/server/backends/jeb/JebFormat.java 4 ●●●● patch | view | raw | blame | history
opendj-sdk/opends/src/server/org/opends/server/backends/jeb/JebFormat.java
@@ -94,6 +94,8 @@
  {
    assert debugEnter(CLASS_NAME, "decodeDatabaseEntry", String.valueOf(bytes));
    // FIXME: This array copy could be very costly on performance. We need to
    // FIXME: find a faster way to implement this versioning feature.
    // Remove version number from the encoded bytes
    byte[] encodedBytes = new byte[bytes.length - 1];
    System.arraycopy(bytes, 1, encodedBytes, 0, encodedBytes.length);
@@ -304,6 +306,8 @@
    byte[] asn1Sequence =
        new ASN1Sequence(TAG_DATABASE_ENTRY, elements).encode();
    // FIXME: This array copy could be very costly on performance. We need to
    // FIXME: find a faster way to implement this versioning feature.
    // Prefix version number to the encoded bytes
    byte[] encodedBytes = new byte[asn1Sequence.length + 1];
    encodedBytes[0] = FORMAT_VERSION;