public class SystemMetadataMap
extends java.lang.Object
implements com.hazelcast.core.MapStore<org.dataone.service.types.v1.Identifier,org.dataone.service.types.v2.SystemMetadata>, com.hazelcast.core.MapLoader<org.dataone.service.types.v1.Identifier,org.dataone.service.types.v2.SystemMetadata>
Constructor and Description |
---|
SystemMetadataMap() |
Modifier and Type | Method and Description |
---|---|
void |
delete(org.dataone.service.types.v1.Identifier arg0) |
void |
deleteAll(java.util.Collection<org.dataone.service.types.v1.Identifier> arg0) |
org.dataone.service.types.v2.SystemMetadata |
load(org.dataone.service.types.v1.Identifier pid) |
java.util.Map<org.dataone.service.types.v1.Identifier,org.dataone.service.types.v2.SystemMetadata> |
loadAll(java.util.Collection<org.dataone.service.types.v1.Identifier> keys) |
java.util.Set<org.dataone.service.types.v1.Identifier> |
loadAllKeys()
Returning null so that no entries are loaded on map initialization
|
void |
store(org.dataone.service.types.v1.Identifier pid,
org.dataone.service.types.v2.SystemMetadata sm) |
void |
storeAll(java.util.Map<org.dataone.service.types.v1.Identifier,org.dataone.service.types.v2.SystemMetadata> map) |
public void delete(org.dataone.service.types.v1.Identifier arg0)
delete
in interface com.hazelcast.core.MapStore<org.dataone.service.types.v1.Identifier,org.dataone.service.types.v2.SystemMetadata>
public void deleteAll(java.util.Collection<org.dataone.service.types.v1.Identifier> arg0)
deleteAll
in interface com.hazelcast.core.MapStore<org.dataone.service.types.v1.Identifier,org.dataone.service.types.v2.SystemMetadata>
public void store(org.dataone.service.types.v1.Identifier pid, org.dataone.service.types.v2.SystemMetadata sm)
store
in interface com.hazelcast.core.MapStore<org.dataone.service.types.v1.Identifier,org.dataone.service.types.v2.SystemMetadata>
public void storeAll(java.util.Map<org.dataone.service.types.v1.Identifier,org.dataone.service.types.v2.SystemMetadata> map)
storeAll
in interface com.hazelcast.core.MapStore<org.dataone.service.types.v1.Identifier,org.dataone.service.types.v2.SystemMetadata>
public org.dataone.service.types.v2.SystemMetadata load(org.dataone.service.types.v1.Identifier pid)
load
in interface com.hazelcast.core.MapLoader<org.dataone.service.types.v1.Identifier,org.dataone.service.types.v2.SystemMetadata>
public java.util.Map<org.dataone.service.types.v1.Identifier,org.dataone.service.types.v2.SystemMetadata> loadAll(java.util.Collection<org.dataone.service.types.v1.Identifier> keys)
loadAll
in interface com.hazelcast.core.MapLoader<org.dataone.service.types.v1.Identifier,org.dataone.service.types.v2.SystemMetadata>
public java.util.Set<org.dataone.service.types.v1.Identifier> loadAllKeys()
loadAllKeys
in interface com.hazelcast.core.MapLoader<org.dataone.service.types.v1.Identifier,org.dataone.service.types.v2.SystemMetadata>
As of 1.9.3 MapLoader has the new MapLoader.loadAllKeys API.
It is used for pre-populating the in-memory map when the map is first touched/used.
If MapLoader.loadAllKeys returns NULL then nothing will be loaded.
Your MapLoader.loadAllKeys implementation can return all or some of the keys.
You may select and return only the hot keys, for instance.
Also note that this is the fastest way of pre-populating the map as
Hazelcast will optimize the loading process by having each node loading owned portion of the entries.
Copyright © 2020 Regents of the University of California. All Rights Reserved.