mirror of
https://github.com/OpenHFT/Chronicle-Map.git
synced 2021-09-13 01:26:12 +00:00
HCOLL-184 stateless client now returns the server and client versions
This commit is contained in:
@@ -73,7 +73,7 @@ class VanillaChronicleMap<K, KI, MKI extends MetaBytesInterop<K, ? super KI>,
|
||||
static final int MAX_ENTRY_OVERSIZE_FACTOR = 64;
|
||||
private static final long serialVersionUID = 2L;
|
||||
final Class<K> kClass;
|
||||
final String mapVersion;
|
||||
final String dataFileVersion;
|
||||
final SizeMarshaller keySizeMarshaller;
|
||||
final BytesReader<K> originalKeyReader;
|
||||
final KI originalKeyInterop;
|
||||
@@ -122,7 +122,7 @@ class VanillaChronicleMap<K, KI, MKI extends MetaBytesInterop<K, ? super KI>,
|
||||
kClass = keyBuilder.eClass;
|
||||
keySizeMarshaller = keyBuilder.sizeMarshaller();
|
||||
originalKeyReader = keyBuilder.reader();
|
||||
mapVersion = BuildVersion.readVersion();
|
||||
dataFileVersion = BuildVersion.readVersion();
|
||||
|
||||
originalKeyInterop = (KI) keyBuilder.interop();
|
||||
|
||||
@@ -178,12 +178,20 @@ class VanillaChronicleMap<K, KI, MKI extends MetaBytesInterop<K, ? super KI>,
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the version of Chronicle Map this instance was built with
|
||||
* @return the version of Chronicle Map that was used to create the current data file
|
||||
*/
|
||||
String version() {
|
||||
return mapVersion;
|
||||
public String persistedDataVersion() {
|
||||
return dataFileVersion;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the version of chronicle map that is currently running
|
||||
*/
|
||||
public String applicationVersion() {
|
||||
return BuildVersion.readVersion();
|
||||
}
|
||||
|
||||
|
||||
final long segmentHash(long hash) {
|
||||
return hashSplitting.segmentHash(hash);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user