Interface TransientStore
-
- All Known Subinterfaces:
TransientStoreProvider
- All Known Implementing Classes:
AbstractTransientStore
,KeyValueBlobTransientStore
,MongoDBTransientStore
,RedisTransientStore
,SimpleTransientStore
public interface TransientStore
Service Interface for managing a transient store.Allows to store entries in 2 sub parts: a list of blobs stored on a file system along with a map of parameters.
- Since:
- 7.2
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
exists(String key)
Returnstrue
if an entry exists with the givenkey
.List<Blob>
getBlobs(String key)
Gets the blobs associated with the entry with the givenkey
.Serializable
getParameter(String key, String parameter)
Gets the value ofparameter
in the entry with the givenkey
.Map<String,Serializable>
getParameters(String key)
Gets values of the parameters in the entry with the givenkey
.long
getSize(String key)
Returns the size of the blobs associated with the entry with the givenkey
or-1
if entry does not exist.boolean
isCompleted(String key)
Returnstrue
if the entry with the givenkey
is ready.void
putBlobs(String key, List<Blob> blobs)
Associates the givenblobs
with the entry with the givenkey
.void
putParameter(String key, String parameter, Serializable value)
Setsparameter
tovalue
in the entry with the givenkey
.void
putParameters(String key, Map<String,Serializable> parameters)
Putsparameters
in the entry with the givenkey
.void
release(String key)
Informs the store that the entry with the givenkey
can be released if TTL or GC parameters require to do some cleanup.void
remove(String key)
Removes entry with the givenkey
.void
setCompleted(String key, boolean completed)
Marks the entry with the givenkey
as ready.
-
-
-
Method Detail
-
exists
boolean exists(String key)
Returnstrue
if an entry exists with the givenkey
.- Since:
- 7.10
-
putParameter
void putParameter(String key, String parameter, Serializable value)
Setsparameter
tovalue
in the entry with the givenkey
.If entry does not exist a new entry is created. If
parameter
already exists in the entry it is overwritten.- Since:
- 7.10
-
getParameter
Serializable getParameter(String key, String parameter)
Gets the value ofparameter
in the entry with the givenkey
.Returns
null
if entry or parameter does not exist.- Since:
- 7.10
-
putParameters
void putParameters(String key, Map<String,Serializable> parameters)
Putsparameters
in the entry with the givenkey
. Overwrites any existing parameter in the entry.If entry does not exist a new entry is created.
- Since:
- 7.10
-
getParameters
Map<String,Serializable> getParameters(String key)
Gets values of the parameters in the entry with the givenkey
.Returns
null
if entry does not exist.- Since:
- 7.10
-
putBlobs
void putBlobs(String key, List<Blob> blobs)
Associates the givenblobs
with the entry with the givenkey
.If entry does not exist a new entry is created.
- Since:
- 7.10
-
getBlobs
List<Blob> getBlobs(String key)
Gets the blobs associated with the entry with the givenkey
.Returns
null
if entry does not exist.- Since:
- 7.10
-
getSize
long getSize(String key)
Returns the size of the blobs associated with the entry with the givenkey
or-1
if entry does not exist.- Since:
- 7.10
-
isCompleted
boolean isCompleted(String key)
Returnstrue
if the entry with the givenkey
is ready.- Since:
- 7.10
-
setCompleted
void setCompleted(String key, boolean completed)
Marks the entry with the givenkey
as ready.If entry does not exist a new entry is created.
- Since:
- 7.10
-
remove
void remove(String key)
Removes entry with the givenkey
.Has no effect if entry does not exist.
-
release
void release(String key)
Informs the store that the entry with the givenkey
can be released if TTL or GC parameters require to do some cleanup.Has no effect if entry does not exist.
-
-