You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ignite.apache.org by ag...@apache.org on 2017/08/18 11:29:46 UTC
ignite git commit: IGNITE-5941 Fixed binary data format compatibility
Repository: ignite
Updated Branches:
refs/heads/master 9ca9bf618 -> dd89aabe3
IGNITE-5941 Fixed binary data format compatibility
Project: http://git-wip-us.apache.org/repos/asf/ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/dd89aabe
Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/dd89aabe
Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/dd89aabe
Branch: refs/heads/master
Commit: dd89aabe3fcfcaffc5b2d7dbed0aefb1c54c5549
Parents: 9ca9bf6
Author: Ilya Lantukh <il...@gridgain.com>
Authored: Fri Aug 18 14:27:40 2017 +0300
Committer: Alexey Goncharuk <al...@gmail.com>
Committed: Fri Aug 18 14:28:55 2017 +0300
----------------------------------------------------------------------
.../processors/cache/persistence/MetadataStorage.java | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ignite/blob/dd89aabe/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/MetadataStorage.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/MetadataStorage.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/MetadataStorage.java
index 498ecdd..359e54e 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/MetadataStorage.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/MetadataStorage.java
@@ -41,6 +41,9 @@ public class MetadataStorage implements MetaStore {
/** Max index name length (bytes num) */
public static final int MAX_IDX_NAME_LEN = 255;
+ /** Reserved size for index name. Needed for backward compatibility. */
+ public static final int RESERVED_IDX_NAME_LEN = 768;
+
/** Bytes in byte. */
private static final int BYTE_LEN = 1;
@@ -344,7 +347,7 @@ public class MetadataStorage implements MetaStore {
*/
private MetaStoreInnerIO(final int ver) {
// name bytes and 1 byte for length, 8 bytes pageId
- super(T_METASTORE_INNER, ver, false, MAX_IDX_NAME_LEN + 1 + 8);
+ super(T_METASTORE_INNER, ver, false, RESERVED_IDX_NAME_LEN + 1 + 8);
}
/** {@inheritDoc} */
@@ -385,7 +388,7 @@ public class MetadataStorage implements MetaStore {
*/
private MetaStoreLeafIO(final int ver) {
// 4 byte cache ID, UTF-16 symbols and 1 byte for length, 8 bytes pageId
- super(T_METASTORE_LEAF, ver, MAX_IDX_NAME_LEN + 1 + 8);
+ super(T_METASTORE_LEAF, ver, RESERVED_IDX_NAME_LEN + 1 + 8);
}
/** {@inheritDoc} */