Bug Type (问题类型)
None
Before submit
Environment (环境信息)
- Server Version: 1.0.0 (Apache Release Version)
- Backend: RocksDB x nodes, HDD or SSD
- OS: xx CPUs, xx G RAM, Ubuntu 2x.x / CentOS 7.x
- Data Size: xx vertices, xx edges
Expected & Actual behavior (期望与实际表现)
Expected & Actual behavior (期望与实际表现)
HugeGraph automatically writes internal schema userdata Userdata.CREATE_TIME ("~create_time") as a java.util.Date when creating schema elements.
Expected
After a schema element is reloaded from backend storage, this value should still be a java.util.Date, consistent with existing schema tests that cast
schemaElement.userdata().get(Userdata.CREATE_TIME) to Date.
Actual
After a backend/store reload, schemaElement.userdata().get(Userdata.CREATE_TIME) can be returned as a String timestamp instead of java.util.Date.
This is exposed more clearly after PR because cross-JVM schema-cache-clear events cause remote server nodes to invalidate and reload schema from backend
storage. The publishing JVM may not observe the issue because it can keep using the in-memory schema object and, with the self-echo skip, does not reload its own
freshly-created schema.
Suspected cause
The schema userdata serialization path writes Date values as strings, but the schema deserialization path does not convert the internal ~create_time value back to
java.util.Date.
Scope
Out of scope for PR That PR only changes runtime schema-cache invalidation propagation. It does not change persisted schema data or fix schema userdata
serialization round-trips.
Minimal repro sketch
Start two HugeGraph server JVMs sharing the same graph / meta / backend.
On Server A, create a schema element (e.g. a property key or vertex label).
Ensure Server B reloads that schema from backend storage after a schema-cache-clear event.
On Server B, inspect schemaElement.userdata().get(Userdata.CREATE_TIME).
Expected type: java.util.Date — actual type: String.
Vertex/Edge example (问题点 / 边数据举例)
Schema [VertexLabel, EdgeLabel, IndexLabel] (元数据结构)
Bug Type (问题类型)
None
Before submit
Environment (环境信息)
Expected & Actual behavior (期望与实际表现)
Expected & Actual behavior (期望与实际表现)
HugeGraph automatically writes internal schema userdata Userdata.CREATE_TIME ("~create_time") as a java.util.Date when creating schema elements.
Expected
After a schema element is reloaded from backend storage, this value should still be a java.util.Date, consistent with existing schema tests that cast
schemaElement.userdata().get(Userdata.CREATE_TIME) to Date.
Actual
After a backend/store reload, schemaElement.userdata().get(Userdata.CREATE_TIME) can be returned as a String timestamp instead of java.util.Date.
This is exposed more clearly after PR because cross-JVM schema-cache-clear events cause remote server nodes to invalidate and reload schema from backend
storage. The publishing JVM may not observe the issue because it can keep using the in-memory schema object and, with the self-echo skip, does not reload its own
freshly-created schema.
Suspected cause
The schema userdata serialization path writes Date values as strings, but the schema deserialization path does not convert the internal ~create_time value back to
java.util.Date.
Scope
Out of scope for PR That PR only changes runtime schema-cache invalidation propagation. It does not change persisted schema data or fix schema userdata
serialization round-trips.
Minimal repro sketch
Start two HugeGraph server JVMs sharing the same graph / meta / backend.
On Server A, create a schema element (e.g. a property key or vertex label).
Ensure Server B reloads that schema from backend storage after a schema-cache-clear event.
On Server B, inspect schemaElement.userdata().get(Userdata.CREATE_TIME).
Expected type: java.util.Date — actual type: String.
Vertex/Edge example (问题点 / 边数据举例)
Schema [VertexLabel, EdgeLabel, IndexLabel] (元数据结构)