Node join serialization defaults
package org.apache.ignite.internal.processors.cache;
+import java.io.IOException;
+import java.io.ObjectInputStream;
import java.io.Serializable;
import java.util.Map;
import org.apache.ignite.internal.util.tostring.GridToStringInclude;
@@ -99,21 +101,21 @@ public class CacheJoinNodeDiscoveryData implements Serializable {
/** */
@GridToStringInclude
- private final StoredCacheData cacheData;
+ private StoredCacheData cacheData;
/** */
@GridToStringInclude
- private final CacheType cacheType;
+ private CacheType cacheType;
/** */
@GridToStringInclude
- private final boolean sql;
+ private boolean sql;
/** Flags added for future usage. */
- private final long flags;
+ private long flags;
/** Statically configured flag */
- private final boolean staticallyConfigured;
+ private boolean staticallyConfigured;
/**
* @param cacheData Cache data.
@@ -159,6 +161,20 @@ public class CacheJoinNodeDiscoveryData implements Serializable {
return staticallyConfigured;
}
+ /**
+ * @param ois ObjectInputStream.
+ */
+ private void readObject(ObjectInputStream ois)
+ throws IOException, ClassNotFoundException {
+ ObjectInputStream.GetField gf = ois.readFields();
+
+ cacheData = (StoredCacheData)gf.get("cacheData", null);
+ cacheType = (CacheType)gf.get("cacheType", null);
+ sql = gf.get("sql", false);
+ flags = gf.get("flags", 0L);
+ staticallyConfigured = gf.get("staticallyConfigured", true);
+ }
+
/** {@inheritDoc} */
@Override public String toString() {
return S.toString(CacheInfo.class, this);
