public class PgxSession extends PgxManagedObject
ServerInstance
. Every session gets a workspace assigned on the server, which can be used to read graph data, create transient data or custom algorithms for the sake of graph analysis. Once a session gets destroyed, all data in the session workspace gets freed.Modifier and Type | Field and Description |
---|---|
static long |
LATEST_SNAPSHOT
the timestamp of the most recent snapshot: used to easily move to the newest snapshot as a second argument of
setSnapshot(PgxGraph, long) ;} |
Modifier and Type | Method and Description |
---|---|
PgxFuture<oracle.pgx.api.CompiledProgram> |
compileProgramCodeAsync(java.lang.String code)
Compiles a Green-Marl program for parallel execution with all optimizations enabled.
|
PgxFuture<oracle.pgx.api.CompiledProgram> |
compileProgramCodeAsync(java.lang.String code, boolean overwrite)
Compiles a Green-Marl program for parallel execution with all optimizations enabled.
|
PgxFuture<oracle.pgx.api.CompiledProgram> |
compileProgramCodeAsync(java.lang.String code, boolean overwrite, boolean parallel, java.util.List<oracle.pgx.api.GmCompilerOptimization> disabledOptimizations, boolean verbose)
Compiles a Green-Marl program.
|
Analyst |
createAnalyst()
Creates a new analyst.
|
GraphBuilder<java.lang.Integer> |
createGraphBuilder()
Creates a graph builder with integer vertex IDs using
IdGenerationStrategy.AUTO_GENERATED for edge ID generation strategy |
GraphBuilder<java.lang.Integer> |
createGraphBuilder(IdGenerationStrategy vertexIdGenerationStrategy, IdGenerationStrategy edgeIdGenerationStrategy)
Creates a graph builder with integer vertex IDs and Ids Mode
|
<ID extends java.lang.Comparable<ID>> |
createGraphBuilder(IdType idType)
Creates a graph builder with the given vertex ID type using
IdGenerationStrategy.AUTO_GENERATED for edge ID generation strategy |
<ID extends java.lang.Comparable<ID>> |
createGraphBuilder(IdType idType, IdGenerationStrategy vertexIdGenerationStrategy, IdGenerationStrategy edgeIdGenerationStrategy)
Creates a graph builder with the given vertex ID type and Ids Mode
|
PgxGraphFromFramesCreator |
createGraphFromFrames(java.lang.String graphName)
Creates a graph from frames creator with which it is possible to specify the different vertex and edge tables of a graph from frames.
|
PgxGraph |
createGraphFromFrames(java.lang.String graphName, PgxFrame vertexFrame, PgxFrame edgeFrame)
Creates an homogeneous graph from the specified frames that represent the vertices and edges of the graph.
|
PgxFuture<PgxGraph> |
createGraphFromFramesAsync(java.lang.String graphName, PgxFrame vertexFrame, PgxFrame edgeFrame)
Creates an homogeneous graph from the specified frames that represent the vertices and edges of the graph.
|
<K,V> PgxMap<K,V> |
createMap(PropertyType keyType, PropertyType valueType)
Blocking version of
createMapAsync(PropertyType, PropertyType) . |
<K,V> PgxMap<K,V> |
createMap(PropertyType keyType, PropertyType valueType, java.lang.String name)
Blocking version of
createMapAsync(PropertyType, PropertyType, String) . |
<K,V> PgxFuture<PgxMap<K,V>> |
createMapAsync(PropertyType keyType, PropertyType valueType)
Convenience method around
createMapAsync(PropertyType, PropertyType, String) passing name as null . |
<K,V> PgxFuture<PgxMap<K,V>> |
createMapAsync(PropertyType keyType, PropertyType valueType, java.lang.String name)
Creates a map.
|
<T> ScalarSequence<T> |
createSequence(PropertyType contentType)
Blocking version of
createSequenceAsync(PropertyType) . |
<T> ScalarSequence<T> |
createSequence(PropertyType contentType, java.lang.String name)
Blocking version of
createSequenceAsync(PropertyType, String) . |
<T> PgxFuture<ScalarSequence<T>> |
createSequenceAsync(PropertyType contentType)
Convenience method around
createSequenceAsync(PropertyType, String) passing name as null . |
<T> PgxFuture<ScalarSequence<T>> |
createSequenceAsync(PropertyType contentType, java.lang.String name)
Creates a sequence of scalars.
|
<T> ScalarSet<T> |
createSet(PropertyType contentType)
Blocking version of
createSetAsync(PropertyType) . |
<T> ScalarSet<T> |
createSet(PropertyType contentType, java.lang.String name)
Blocking version of
createSetAsync(PropertyType, String) . |
<T> PgxFuture<ScalarSet<T>> |
createSetAsync(PropertyType contentType)
Convenience method around
createSetAsync(PropertyType, String) passing name as null . |
<T> PgxFuture<ScalarSet<T>> |
createSetAsync(PropertyType contentType, java.lang.String name)
Creates a set of scalars.
|
PgxFuture<GraphConfig> |
describeGraphAsync(oracle.pgx.loaders.location.GraphLocation location)
Describes the graph contained in a given graph location
|
GraphConfig |
describeGraphFile(java.lang.String path)
Blocking version of
describeGraphFileAsync(String) . |
GraphConfig |
describeGraphFile(java.lang.String path, Format format)
Blocking version of
describeGraphFileAsync(String, Format) . |
PgxFuture<GraphConfig> |
describeGraphFileAsync(java.lang.String path)
Describes the graph contained in the file at the given path.
|
PgxFuture<GraphConfig> |
describeGraphFileAsync(java.lang.String path, Format format)
Describes the graph contained in the file at the given path.
|
GraphConfig |
describeGraphFiles(java.util.List<java.lang.String> filePaths)
Blocking version of
describeGraphFilesAsync(List) . |
GraphConfig |
describeGraphFiles(java.util.List<java.lang.String> filePaths, Format format)
Blocking version of
describeGraphFilesAsync(List, Format) . |
GraphConfig |
describeGraphFiles(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths)
Blocking version of
describeGraphFilesAsync(List, List) . |
GraphConfig |
describeGraphFiles(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths, Format format)
Blocking version of
describeGraphFilesAsync(List, List, Format) . |
GraphConfig |
describeGraphFiles(java.lang.String vertexFilePath, java.lang.String edgeFilePath)
Blocking version of
describeGraphFilesAsync(String, String) . |
GraphConfig |
describeGraphFiles(java.lang.String vertexFilePath, java.lang.String edgeFilePath, Format format)
Blocking version of
describeGraphFilesAsync(String, String, Format) . |
PgxFuture<GraphConfig> |
describeGraphFilesAsync(java.util.List<java.lang.String> filePaths)
Describes the graph contained in the files at the given paths.
|
PgxFuture<GraphConfig> |
describeGraphFilesAsync(java.util.List<java.lang.String> filePaths, Format format)
Describes the graph contained in the files at the given paths.
|
PgxFuture<GraphConfig> |
describeGraphFilesAsync(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths)
Describes the graph contained in the files at the given paths.
|
PgxFuture<GraphConfig> |
describeGraphFilesAsync(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths, Format format)
Describes the graph contained in the files at the given paths.
|
PgxFuture<GraphConfig> |
describeGraphFilesAsync(java.lang.String vertexFilePath, java.lang.String edgeFilePath)
Describes the graph contained in the files at the given paths.
|
PgxFuture<GraphConfig> |
describeGraphFilesAsync(java.lang.String vertexFilePath, java.lang.String edgeFilePath, Format format)
Describes the graph contained in the files at the given paths.
|
PgxFuture<java.lang.Void> |
destroyAsync()
Destroys the active session.
|
PgqlResultSet |
executePgql(java.lang.String pgqlString)
Blocking version of
executePgql(String) . |
PgxFuture<PgqlResultSet> |
executePgqlAsync(java.lang.String pgqlString)
Submits any query with a ON-clause.
|
Operation |
explainPgql(java.lang.String pgqlString)
Blocking version of
explainPgql(String) . |
PgxFuture<Operation> |
explainPgqlAsync(java.lang.String pgqlString)
Explain the execution plan of a pattern matching query.
|
java.util.Set<java.lang.String> |
getAvailableCompiledProgramIds()
Blocking version of
getAvailableCompiledProgramIdsAsync() . |
PgxFuture<java.util.Set<java.lang.String>> |
getAvailableCompiledProgramIdsAsync()
Gets the set of available compiled program IDs.
|
java.util.Deque<GraphMetaData> |
getAvailableSnapshots(PgxGraph snapshot)
Blocking version of
getAvailableSnapshotsAsync(PgxGraph) . |
PgxFuture<java.util.Deque<GraphMetaData>> |
getAvailableSnapshotsAsync(PgxGraph graph)
Gets a list of the
GraphMetaData information of available in-memory snapshots of graph . |
oracle.pgx.api.CompiledProgram |
getCompiledProgram(java.lang.String id)
Blocking version of
getCompiledProgramAsync(String) . |
PgxFuture<oracle.pgx.api.CompiledProgram> |
getCompiledProgramAsync(java.lang.String id)
Gets a compiled program by ID.
|
ExecutionEnvironment |
getExecutionEnvironment()
Gets the execution environment for this session.
|
PgxGraph |
getGraph(Namespace namespace, java.lang.String name)
Blocking version of
getGraphAsync(String) . |
PgxGraph |
getGraph(java.lang.String name)
Blocking version of
getGraphAsync(String) . |
PgxFuture<PgxGraph> |
getGraphAsync(Namespace namespace, java.lang.String name)
References a graph with name
name within the given namespace: - if namespace is Namespace.PRIVATE , than the search occurs on already referenced snapshots of the graph with name name and the most recent snapshot is returned - if namespace is Namespace.PUBLIC , then the search occurs on published graphs and the most recent snapshot of the published graph with name name is returned - if namespace is null , then the PRIVATE namespace is searched first and, if no snapshot is found, the PUBLIC namespace is then searched, according to the shadowing rules |
PgxFuture<PgxGraph> |
getGraphAsync(java.lang.String name)
References a graph with name
name loaded inside PGX. |
java.util.Map<java.lang.String,PgxGraph> |
getGraphs()
Deprecated.
|
java.util.List<java.lang.String> |
getGraphs(Namespace namespace)
Blocking version of
getGraphsAsync(Namespace) . |
PgxFuture<java.util.List<java.lang.String>> |
getGraphsAsync(Namespace namespace)
Returns a collection of graph names accessible under the given namespace.
|
java.lang.String |
getId()
Gets the session ID.
|
java.lang.Long |
getIdleTimeout()
Gets the idle timeout of this session.
|
java.lang.String |
getName()
Alias for
getId() |
PgqlResultSet |
getPgqlResultSet(java.lang.String id)
Blocking version of
getPgqlResultSetAsync(String) . |
PgxFuture<PgqlResultSet> |
getPgqlResultSetAsync(java.lang.String id)
Gets a PGQL result set by ID.
|
ServerInstance |
getServerInstance()
Gets the server instance.
|
SessionContext |
getSessionContext()
Gets the context describing the session
|
java.lang.String |
getSource()
Gets the source.
|
java.lang.Long |
getTaskTimeout()
Gets the task timeout of this session.
|
PgxPreparedStatement |
preparePgql(java.lang.String pgqlString)
Blocking version of
preparePgqlAsync(String) . |
PgxFuture<PgxPreparedStatement> |
preparePgqlAsync(java.lang.String pgqlString)
Prepares a pattern matching query with a ON-clause.
|
PgqlResultSet |
queryPgql(java.lang.String pgqlString)
Blocking version of
queryPgql(String) . |
PgxFuture<PgqlResultSet> |
queryPgqlAsync(java.lang.String pgqlString)
Submits a pattern matching query with a ON-clause.
|
PgxGenericFrameReader |
readFrame()
Creates a new frame reader with which it is possible to parameterize the loading of the row frame
|
PgxGraph |
readGraphAsOf(GraphConfig config, GraphMetaData metaData)
Blocking version of
readGraphAsOfAsync(GraphConfig, GraphMetaData) . |
PgxGraph |
readGraphAsOf(GraphConfig config, GraphMetaData metaData, java.lang.String newGraphName)
Blocking version of
readGraphAsOfAsync(GraphConfig, GraphMetaData, String) . |
PgxGraph |
readGraphAsOf(GraphConfig config, long creationTimestamp)
Blocking version of
readGraphAsOfAsync(GraphConfig, long) . |
PgxGraph |
readGraphAsOf(GraphConfig config, long creationTimestamp, java.lang.String newGraphName)
Blocking version of
readGraphAsOfAsync(GraphConfig, long, String) . |
PgxFuture<PgxGraph> |
readGraphAsOfAsync(GraphConfig config, GraphMetaData metaData)
Reads a graph and its properties of a specific version (metaData) into memory.
|
PgxFuture<PgxGraph> |
readGraphAsOfAsync(GraphConfig config, GraphMetaData metaData, java.lang.String newGraphName)
Reads a graph and its properties of a specific version (metaData) into memory.
|
PgxFuture<PgxGraph> |
readGraphAsOfAsync(GraphConfig config, long creationTimestamp)
Reads a graph and its properties of a specific version (creationTimestamp) into memory.
|
PgxFuture<PgxGraph> |
readGraphAsOfAsync(GraphConfig config, long creationTimestamp, java.lang.String newGraphName)
Reads a graph and its properties of a specific version (creationTimestamp) into memory.
|
PgxGraph |
readGraphFile(java.lang.String path)
Blocking version of
readGraphFileAsync(String) . |
PgxGraph |
readGraphFile(java.lang.String path, Format format)
Blocking version of
readGraphFileAsync(String, Format) . |
PgxGraph |
readGraphFile(java.lang.String path, Format format, java.lang.String newGraphName)
Blocking version of
readGraphFileAsync(String, Format, String) . |
PgxGraph |
readGraphFile(java.lang.String path, java.lang.String newGraphName)
Blocking version of
readGraphFileAsync(String, String) . |
PgxFuture<PgxGraph> |
readGraphFileAsync(java.lang.String path)
Loads the graph contained in the file at the given path.
|
PgxFuture<PgxGraph> |
readGraphFileAsync(java.lang.String path, Format format)
Loads the graph contained in the file at the given path.
|
PgxFuture<PgxGraph> |
readGraphFileAsync(java.lang.String path, Format format, java.lang.String newGraphName)
Loads the graph contained in the files at the given path.
|
PgxFuture<PgxGraph> |
readGraphFileAsync(java.lang.String path, java.lang.String newGraphName)
Loads the graph contained in the file at the given path.
|
PgxGraph |
readGraphFiles(java.util.List<java.lang.String> filePaths)
Blocking version of
readGraphFilesAsync(List) . |
PgxGraph |
readGraphFiles(java.util.List<java.lang.String> filePaths, Format format)
Blocking version of
readGraphFilesAsync(List, Format) . |
PgxGraph |
readGraphFiles(java.util.List<java.lang.String> filePaths, Format format, java.lang.String newGraphName)
Blocking version of
readGraphFilesAsync(List, String) . |
PgxGraph |
readGraphFiles(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths)
Blocking version of
readGraphFilesAsync(List, List) . |
PgxGraph |
readGraphFiles(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths, Format format)
Blocking version of
readGraphFilesAsync(List, List, Format) . |
PgxGraph |
readGraphFiles(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths, Format format, java.lang.String newGraphName)
Blocking version of
readGraphFilesAsync(List, List, Format, String) . |
PgxGraph |
readGraphFiles(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths, java.lang.String newGraphName)
Blocking version of
readGraphFilesAsync(List, List, String) . |
PgxGraph |
readGraphFiles(java.util.List<java.lang.String> filePaths, java.lang.String newGraphName)
Blocking version of
readGraphFilesAsync(List, String) . |
PgxGraph |
readGraphFiles(java.lang.String vertexFilePath, java.lang.String edgeFilePath)
Blocking version of
readGraphFilesAsync(String, String) . |
PgxGraph |
readGraphFiles(java.lang.String vertexFilePath, java.lang.String edgeFilePath, Format format)
Blocking version of
readGraphFilesAsync(String, String, Format) . |
PgxGraph |
readGraphFiles(java.lang.String vertexFilePath, java.lang.String edgeFilePath, Format format, java.lang.String newGraphName)
Blocking version of
readGraphFilesAsync(String, String, Format, String) . |
PgxGraph |
readGraphFiles(java.lang.String vertexFilePath, java.lang.String edgeFilePath, java.lang.String newGraphName)
Blocking version of
readGraphFilesAsync(String, String, String) . |
PgxFuture<PgxGraph> |
readGraphFilesAsync(java.util.List<java.lang.String> filePaths)
Loads the graph contained in the files at the given paths.
|
PgxFuture<PgxGraph> |
readGraphFilesAsync(java.util.List<java.lang.String> filePaths, Format format)
Loads the graph contained in the files at the given paths.
|
PgxFuture<PgxGraph> |
readGraphFilesAsync(java.util.List<java.lang.String> filePaths, Format format, java.lang.String newGraphName)
Loads the graph contained in the files at the given paths.
|
PgxFuture<PgxGraph> |
readGraphFilesAsync(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths)
Loads the graph contained in the files at the given paths.
|
PgxFuture<PgxGraph> |
readGraphFilesAsync(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths, Format format)
Loads the graph contained in the files at the given paths.
|
PgxFuture<PgxGraph> |
readGraphFilesAsync(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths, Format format, java.lang.String newGraphName)
Loads the graph contained in the files at the given paths.
|
PgxFuture<PgxGraph> |
readGraphFilesAsync(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths, java.lang.String newGraphName)
Loads the graph contained in the files at the given paths.
|
PgxFuture<PgxGraph> |
readGraphFilesAsync(java.util.List<java.lang.String> filePaths, java.lang.String newGraphName)
Loads the graph contained in the files at the given paths.
|
PgxFuture<PgxGraph> |
readGraphFilesAsync(java.lang.String vertexFilePath, java.lang.String edgeFilePath)
Loads the graph contained in the files at the given paths.
|
PgxFuture<PgxGraph> |
readGraphFilesAsync(java.lang.String vertexFilePath, java.lang.String edgeFilePath, Format format)
Loads the graph contained in the files at the given paths.
|
PgxFuture<PgxGraph> |
readGraphFilesAsync(java.lang.String vertexFilePath, java.lang.String edgeFilePath, Format format, java.lang.String newGraphName)
Loads the graph contained in the files at the given paths.
|
PgxFuture<PgxGraph> |
readGraphFilesAsync(java.lang.String vertexFilePath, java.lang.String edgeFilePath, java.lang.String newGraphName)
Loads the graph contained in the files at the given paths.
|
PgxGraph |
readGraphWithProperties(GraphConfig config)
Blocking version of
readGraphWithPropertiesAsync(GraphConfig) . |
PgxGraph |
readGraphWithProperties(GraphConfig config, boolean updateIfNotFresh)
Blocking version of
readGraphWithPropertiesAsync(GraphConfig, boolean) . |
PgxGraph |
readGraphWithProperties(GraphConfig config, boolean updateIfNotFresh, java.lang.String newGraphName)
Blocking version of
readGraphWithPropertiesAsync(GraphConfig, boolean, String) . |
PgxGraph |
readGraphWithProperties(GraphConfig config, long maxAge, java.util.concurrent.TimeUnit maxAgeTimeUnit)
Blocking version of
readGraphWithPropertiesAsync(GraphConfig, long, TimeUnit) . |
PgxGraph |
readGraphWithProperties(GraphConfig config, long maxAge, java.util.concurrent.TimeUnit maxAgeTimeUnit, boolean blockIfFull, java.lang.String newGraphName)
Blocking version of
readGraphWithPropertiesAsync(GraphConfig, long, TimeUnit, boolean, String) . |
PgxGraph |
readGraphWithProperties(GraphConfig config, java.lang.String newGraphName)
Blocking version of
readGraphWithPropertiesAsync(GraphConfig, String) . |
PgxGraph |
readGraphWithProperties(java.lang.String path)
Blocking version of
readGraphWithPropertiesAsync(String) . |
PgxGraph |
readGraphWithProperties(java.lang.String path, java.lang.String newGraphName)
Blocking version of
readGraphWithPropertiesAsync(String, String) . |
PgxFuture<PgxGraph> |
readGraphWithPropertiesAsync(GraphConfig config)
Reads a graph and its properties, specified in the graph config, into memory.
|
PgxFuture<PgxGraph> |
readGraphWithPropertiesAsync(GraphConfig config, boolean updateIfNotFresh)
Reads a graph and its properties, specified in the graph config, into memory.
|
PgxFuture<PgxGraph> |
readGraphWithPropertiesAsync(GraphConfig config, boolean updateIfNotFresh, java.lang.String newGraphName)
Reads a graph and its properties, specified in the graph config, into memory.
|
PgxFuture<PgxGraph> |
readGraphWithPropertiesAsync(GraphConfig config, long maxAge, java.util.concurrent.TimeUnit maxAgeTimeUnit)
Reads a graph and its properties, specified in the graph config, into memory.
|
PgxFuture<PgxGraph> |
readGraphWithPropertiesAsync(GraphConfig config, long maxAge, java.util.concurrent.TimeUnit maxAgeTimeUnit, boolean blockIfFull, java.lang.String newGraphName)
Reads a graph and its properties, specified in the graph config, into memory.
|
PgxFuture<PgxGraph> |
readGraphWithPropertiesAsync(GraphConfig config, java.lang.String newGraphName)
Reads a graph and its properties, specified a graph config, into memory.
|
PgxFuture<PgxGraph> |
readGraphWithPropertiesAsync(java.lang.String path)
Reads a graph and its properties, specified by a path to a graph config, into memory.
|
PgxFuture<PgxGraph> |
readGraphWithPropertiesAsync(java.lang.String path, java.lang.String newGraphName)
Reads a graph and its properties, specified by a path to a graph config, into memory.
|
void |
registerKeystore(java.lang.String keystorePath, char[] keystorePassword)
Register the keystore to read needed secrets.
|
java.util.List<?> |
runConcurrently(java.util.List<java.util.function.Supplier<PgxFuture<?>>> asyncRequest)
Blocking version of
#runConcurrentlyAsync(List<Supplier>) . |
PgxFuture<java.util.List<?>> |
runConcurrentlyAsync(java.util.List<java.util.function.Supplier<PgxFuture<?>>> asyncRequestsSuppliers)
Submits lists of supplied functions to run concurrently in the server
|
void |
setSnapshot(PgxGraph graph, GraphMetaData metaData)
Blocking version of
setSnapshotAsync(PgxGraph, GraphMetaData) . |
void |
setSnapshot(PgxGraph graph, GraphMetaData metaData, boolean forceDeleteProperties)
Blocking version of
setSnapshotAsync(PgxGraph, GraphMetaData, boolean) . |
void |
setSnapshot(PgxGraph graph, long creationTimestamp)
Blocking version of
setSnapshotAsync(PgxGraph, long) . |
void |
setSnapshot(PgxGraph graph, long creationTimestamp, boolean forceDeleteProperties)
Blocking version of
setSnapshotAsync(PgxGraph, long, boolean) . |
PgxFuture<java.lang.Void> |
setSnapshotAsync(PgxGraph graph, GraphMetaData metaData)
Sets a graph to a specific snapshot.
|
PgxFuture<java.lang.Void> |
setSnapshotAsync(PgxGraph graph, GraphMetaData metaData, boolean forceDeleteTransientProperties)
Sets a graph to a specific snapshot.
|
PgxFuture<java.lang.Void> |
setSnapshotAsync(PgxGraph graph, long creationTimestamp)
Sets a graph to a specific snapshot.
|
PgxFuture<java.lang.Void> |
setSnapshotAsync(PgxGraph graph, long creationTimestamp, boolean forceDeleteTransientProperties)
Sets a graph to a specific snapshot.
|
java.lang.String |
toString() |
equals, hashCode
close, destroy
public static final long LATEST_SNAPSHOT
setSnapshot(PgxGraph, long)
;}public PgxFuture<oracle.pgx.api.CompiledProgram> compileProgramCodeAsync(java.lang.String code)
code
- the Green-Marl code to compilepublic PgxFuture<oracle.pgx.api.CompiledProgram> compileProgramCodeAsync(java.lang.String code, boolean overwrite)
code
- the Green-Marl code to compileoverwrite
- if the procedure in the given code already exists, overwrite if true
, throw an exception otherwisepublic PgxFuture<oracle.pgx.api.CompiledProgram> compileProgramCodeAsync(java.lang.String code, boolean overwrite, boolean parallel, java.util.List<oracle.pgx.api.GmCompilerOptimization> disabledOptimizations, boolean verbose)
code
- the Green-Marl code to compileparallel
- if false
, the compiled program will be optimized for sequential executiondisabledOptimizations
- list of compiler optimizations to disableverbose
- if true
, the compiler will output compilation stagespublic Analyst createAnalyst()
Analyst
gives access to all built-in algorithms.public GraphBuilder<java.lang.Integer> createGraphBuilder()
IdGenerationStrategy.AUTO_GENERATED
for edge ID generation strategycreateGraphBuilder(IdType)
public GraphBuilder<java.lang.Integer> createGraphBuilder(IdGenerationStrategy vertexIdGenerationStrategy, IdGenerationStrategy edgeIdGenerationStrategy)
vertexIdGenerationStrategy
- the vertices Id generation strategy to be usededgeIdGenerationStrategy
- the edges Id generation strategy to be usedcreateGraphBuilder(IdType)
public <ID extends java.lang.Comparable<ID>> GraphBuilder<ID> createGraphBuilder(IdType idType)
IdGenerationStrategy.AUTO_GENERATED
for edge ID generation strategyID
- the type of the vertex IDidType
- the vertex ID typepublic <ID extends java.lang.Comparable<ID>> GraphBuilder<ID> createGraphBuilder(IdType idType, IdGenerationStrategy vertexIdGenerationStrategy, IdGenerationStrategy edgeIdGenerationStrategy)
ID
- the type of the vertex IDidType
- the vertex ID typevertexIdGenerationStrategy
- the vertices Id generation strategy to be usededgeIdGenerationStrategy
- the edges Id generation strategy to be usedpublic PgxGraphFromFramesCreator createGraphFromFrames(java.lang.String graphName)
graphName
- the name of the graph to createpublic PgxGraph createGraphFromFrames(java.lang.String graphName, PgxFrame vertexFrame, PgxFrame edgeFrame) throws java.lang.InterruptedException, java.util.concurrent.ExecutionException
graphName
- the name of the graph to createvertexFrame
- the frame that contains the vertices of the graphedgeFrame
- the frame that contains the edges of the graphjava.lang.InterruptedException
java.util.concurrent.ExecutionException
public PgxFuture<PgxGraph> createGraphFromFramesAsync(java.lang.String graphName, PgxFrame vertexFrame, PgxFrame edgeFrame)
graphName
- the name of the graph to createvertexFrame
- the frame that contains the vertices of the graphedgeFrame
- the frame that contains the edges of the graphpublic <K,V> PgxMap<K,V> createMap(PropertyType keyType, PropertyType valueType)
createMapAsync(PropertyType, PropertyType)
. Calls createMapAsync(PropertyType, PropertyType)
and waits for the returned PgxFuture
to complete.public <K,V> PgxMap<K,V> createMap(PropertyType keyType, PropertyType valueType, java.lang.String name)
createMapAsync(PropertyType, PropertyType, String)
. Calls createMapAsync(PropertyType, PropertyType, String)
and waits for the returned PgxFuture
to complete.public <K,V> PgxFuture<PgxMap<K,V>> createMapAsync(PropertyType keyType, PropertyType valueType)
createMapAsync(PropertyType, PropertyType, String)
passing name as null
.public <K,V> PgxFuture<PgxMap<K,V>> createMapAsync(PropertyType keyType, PropertyType valueType, java.lang.String name)
keyType
- key content type of the map.valueType
- value content type of the map.name
- the map's name.PgxMap
of key content type keyType and value content type valueType.public <T> ScalarSequence<T> createSequence(PropertyType contentType)
createSequenceAsync(PropertyType)
. Calls createSequenceAsync(PropertyType)
and waits for the returned PgxFuture
to complete.public <T> ScalarSequence<T> createSequence(PropertyType contentType, java.lang.String name)
createSequenceAsync(PropertyType, String)
. Calls createSequenceAsync(PropertyType, String)
and waits for the returned PgxFuture
to complete.public <T> PgxFuture<ScalarSequence<T>> createSequenceAsync(PropertyType contentType)
createSequenceAsync(PropertyType, String)
passing name as null
.public <T> PgxFuture<ScalarSequence<T>> createSequenceAsync(PropertyType contentType, java.lang.String name)
contentType
- content type of the sequence.name
- the sequence's name.ScalarSequence
of content type contentType.public <T> ScalarSet<T> createSet(PropertyType contentType)
createSetAsync(PropertyType)
. Calls createSetAsync(PropertyType)
and waits for the returned PgxFuture
to complete.public <T> ScalarSet<T> createSet(PropertyType contentType, java.lang.String name)
createSetAsync(PropertyType, String)
. Calls createSetAsync(PropertyType, String)
and waits for the returned PgxFuture
to complete.public <T> PgxFuture<ScalarSet<T>> createSetAsync(PropertyType contentType)
createSetAsync(PropertyType, String)
passing name as null
.public <T> PgxFuture<ScalarSet<T>> createSetAsync(PropertyType contentType, java.lang.String name)
contentType
- content type of the set.name
- the set's name.ScalarSet
of content type contentType.public PgxFuture<GraphConfig> describeGraphAsync(oracle.pgx.loaders.location.GraphLocation location)
PGX will try to detect the graph configuration. If the configuration cannot be determined or if the graph format does not match the given format, the future is completed exceptionally.
location
- the graph locationpublic GraphConfig describeGraphFile(java.lang.String path) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
describeGraphFileAsync(String)
. Calls describeGraphFileAsync(String)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public GraphConfig describeGraphFile(java.lang.String path, Format format) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
describeGraphFileAsync(String, Format)
. Calls describeGraphFileAsync(String, Format)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxFuture<GraphConfig> describeGraphFileAsync(java.lang.String path)
PGX will try to detect the file format and the graph configuration. If the format or the configuration cannot be determined, the future is completed exceptionally.
path
- graph file pathpublic PgxFuture<GraphConfig> describeGraphFileAsync(java.lang.String path, Format format)
PGX will try to detect the graph configuration. If the configuration cannot be determined or if the file format does not match the given format, the future is completed exceptionally.
path
- graph file pathformat
- file formatpublic GraphConfig describeGraphFiles(java.util.List<java.lang.String> filePaths) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
describeGraphFilesAsync(List)
. Calls describeGraphFilesAsync(List)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public GraphConfig describeGraphFiles(java.util.List<java.lang.String> filePaths, Format format) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
describeGraphFilesAsync(List, Format)
. Calls describeGraphFilesAsync(List, Format)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public GraphConfig describeGraphFiles(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
describeGraphFilesAsync(List, List)
. Calls describeGraphFilesAsync(List, List)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public GraphConfig describeGraphFiles(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths, Format format) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
describeGraphFilesAsync(List, List, Format)
. Calls describeGraphFilesAsync(List, List, Format)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public GraphConfig describeGraphFiles(java.lang.String vertexFilePath, java.lang.String edgeFilePath) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
describeGraphFilesAsync(String, String)
. Calls describeGraphFilesAsync(String, String)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public GraphConfig describeGraphFiles(java.lang.String vertexFilePath, java.lang.String edgeFilePath, Format format) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
describeGraphFilesAsync(String, String, Format)
. Calls describeGraphFilesAsync(String, String, Format)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxFuture<GraphConfig> describeGraphFilesAsync(java.util.List<java.lang.String> filePaths)
PGX will try to detect the file format and the graph configuration. If the format or the configuration cannot be determined, the future is completed exceptionally.
filePaths
- paths to the filespublic PgxFuture<GraphConfig> describeGraphFilesAsync(java.util.List<java.lang.String> filePaths, Format format)
PGX will try to detect the file format and the graph configuration. If the format or the configuration cannot be determined, the future is completed exceptionally.
filePaths
- paths to the filespublic PgxFuture<GraphConfig> describeGraphFilesAsync(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths)
PGX will try to detect the file format and the graph configuration. If the format or the configuration cannot be determined, the future is completed exceptionally.
vertexFilePaths
- paths to the vertex filesedgeFilePaths
- paths to the edge filespublic PgxFuture<GraphConfig> describeGraphFilesAsync(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths, Format format)
PGX will try to detect the graph configuration. If the configuration cannot be determined or if the file format does not match the given format, the future is completed exceptionally.
vertexFilePaths
- paths to the vertex filesedgeFilePaths
- paths to the edge filesformat
- file formatpublic PgxFuture<GraphConfig> describeGraphFilesAsync(java.lang.String vertexFilePath, java.lang.String edgeFilePath)
PGX will try to detect the file format and the graph configuration. If the format or the configuration cannot be determined, the future is completed exceptionally.
vertexFilePath
- path to the vertex fileedgeFilePath
- path to the edge filepublic PgxFuture<GraphConfig> describeGraphFilesAsync(java.lang.String vertexFilePath, java.lang.String edgeFilePath, Format format)
PGX will try to detect the graph configuration. If the configuration cannot be determined or if the file format does not match the given format, the future is completed exceptionally.
vertexFilePath
- path to the vertex fileedgeFilePath
- path to the edge fileformat
- file formatpublic PgxFuture<java.lang.Void> destroyAsync()
destroyAsync
in class Destroyable
public PgqlResultSet executePgql(java.lang.String pgqlString) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
executePgql(String)
. Calls executePgqlAsync(String)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxFuture<PgqlResultSet> executePgqlAsync(java.lang.String pgqlString)
getGraphAsync(String)
.pgqlString
- query string in PGQLpublic Operation explainPgql(java.lang.String pgqlString) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
explainPgql(String)
. Calls explainPgqlAsync(String)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxFuture<Operation> explainPgqlAsync(java.lang.String pgqlString)
pgqlString
- query string in PGQLpublic java.util.Set<java.lang.String> getAvailableCompiledProgramIds()
getAvailableCompiledProgramIdsAsync()
. Calls getAvailableCompiledProgramIdsAsync()
and waits for returned PgxFuture
to complete.public PgxFuture<java.util.Set<java.lang.String>> getAvailableCompiledProgramIdsAsync()
public java.util.Deque<GraphMetaData> getAvailableSnapshots(PgxGraph snapshot) throws java.lang.InterruptedException, java.util.concurrent.ExecutionException
getAvailableSnapshotsAsync(PgxGraph)
. Calls getAvailableSnapshotsAsync(PgxGraph)
and waits for returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxFuture<java.util.Deque<GraphMetaData>> getAvailableSnapshotsAsync(PgxGraph graph)
GraphMetaData
information of available in-memory snapshots of graph
.graph
- the graph whose information is returned; note that graph
can reference any snapshot of the graph (see setSnapshot(PgxGraph, long)
): all snapshots GraphMetaData
objects will be retrieved anywaygraph
currently loaded into memory. The list is sorted by descending order based on the GraphMetaData.getCreationTimestamp()
value (milliseconds since Jan 1st 1970) - the timestamp when the snapshot was created.public oracle.pgx.api.CompiledProgram getCompiledProgram(java.lang.String id)
getCompiledProgramAsync(String)
. Calls getCompiledProgramAsync(String)
and waits for returned PgxFuture
to complete.public PgxFuture<oracle.pgx.api.CompiledProgram> getCompiledProgramAsync(java.lang.String id)
id
- the ID of the compiled programpublic ExecutionEnvironment getExecutionEnvironment()
ExecutionEnvironment
gives access to detailed scheduling configurationpublic PgxGraph getGraph(Namespace namespace, java.lang.String name) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
getGraphAsync(String)
. Calls getGraphAsync(String)
and waits for returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph getGraph(java.lang.String name) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
getGraphAsync(String)
. Calls getGraphAsync(String)
and waits for returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxFuture<PgxGraph> getGraphAsync(Namespace namespace, java.lang.String name)
name
within the given namespace: - if namespace
is Namespace.PRIVATE
, than the search occurs on already referenced snapshots of the graph with name name
and the most recent snapshot is returned - if namespace
is Namespace.PUBLIC
, then the search occurs on published graphs and the most recent snapshot of the published graph with name name
is returned - if namespace
is null
, then the PRIVATE namespace is searched first and, if no snapshot is found, the PUBLIC namespace is then searched, according to the shadowing rules
Multiple calls of this method with the same parameters will return different PgxGraph
objects referencing the same graph, with the server keeping track of how many references a session has to each graph. Therefore, a graph is released within the server either if: - all the references are moved to another graph (e.g. via setSnapshot(PgxGraph, long)
- the PgxGraph.destroy()
method is called on one reference: note that this invalidates all references
namespace
- the namespace where to look up the graph. can be null, which implies same behavior as getGraphAsync(String)
name
- the name of the graphnull
if no such graph existsgetGraphAsync(String)
, Namespace.PRIVATE
, Namespace.PUBLIC
public PgxFuture<PgxGraph> getGraphAsync(java.lang.String name)
name
loaded inside PGX. The search for the snapshot to return is done according to the following rules: - first, PGX searches among the snapshots the session is already referencing, if it finds any it returns the most recent one belonging to the graph with name name
- if no graph with name name
is already being referenced, PGX searches among published graphs and, if the search is successful, it returns the most recent snapshots of the published graph with name name
Multiple calls of this method with the same parameters will return different PgxGraph
objects referencing the same graph, with the server keeping track of how many references a session has to each graph. Therefore, a graph is released within the server either if: - all the references are moved to another graph (e.g. via setSnapshot(PgxGraph, long)
- the PgxGraph.destroy()
method is called on one reference: note that this invalidates all references
The graph will be first looked up in the session private namespace, if it is not found there it will be looked up in the public namespace. If a graph with the given name is not found in either the private or public namespace, null
will be returned. A call to this will be semantically the same as the following code:
PgxGraph g = session.getGraph(Namespace.PRIVATE, name);
if (g == null) {
g = session.getGraph(Namespace.PUBLIC, name);
}
name
- the name of the graphnull
if no such graph existsgetGraphAsync(Namespace, String)
, Namespace.PRIVATE
, Namespace.PUBLIC
@Deprecated public java.util.Map<java.lang.String,PgxGraph> getGraphs() throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
getGraphsAsync()
. Calls getGraphsAsync()
and waits for returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public java.util.List<java.lang.String> getGraphs(Namespace namespace) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
getGraphsAsync(Namespace)
. Calls getGraphsAsync(Namespace)
and waits for returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxFuture<java.util.List<java.lang.String>> getGraphsAsync(Namespace namespace)
public java.lang.String getId()
public java.lang.Long getIdleTimeout()
null
indicates this session uses the default session idle timeout as specified by the PGX instance.null
.public java.lang.String getName()
getId()
getName
in class PgxManagedObject
public PgqlResultSet getPgqlResultSet(java.lang.String id)
getPgqlResultSetAsync(String)
. Calls getPgqlResultSetAsync(String)
and waits for returned PgxFuture
to complete.public PgxFuture<PgqlResultSet> getPgqlResultSetAsync(java.lang.String id)
id
- the PGQL result set IDpublic ServerInstance getServerInstance()
public SessionContext getSessionContext()
public java.lang.String getSource()
public java.lang.Long getTaskTimeout()
null
indicates this session uses the default session task timeout as specified by the PGX instance.null
.public PgxPreparedStatement preparePgql(java.lang.String pgqlString)
preparePgqlAsync(String)
. Calls preparePgqlAsync(String)
and waits for the returned PgxFuture
to complete.public PgxFuture<PgxPreparedStatement> preparePgqlAsync(java.lang.String pgqlString)
getGraphAsync(String)
.pgqlString
- query string in PGQLpublic PgqlResultSet queryPgql(java.lang.String pgqlString) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
queryPgql(String)
. Calls queryPgqlAsync(String)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxFuture<PgqlResultSet> queryPgqlAsync(java.lang.String pgqlString)
getGraphAsync(String)
.pgqlString
- query string in PGQLpublic PgxGenericFrameReader readFrame()
public PgxGraph readGraphAsOf(GraphConfig config, GraphMetaData metaData) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphAsOfAsync(GraphConfig, GraphMetaData)
. Calls readGraphAsOfAsync(GraphConfig, GraphMetaData)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphAsOf(GraphConfig config, GraphMetaData metaData, java.lang.String newGraphName) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphAsOfAsync(GraphConfig, GraphMetaData, String)
. Calls readGraphAsOfAsync(GraphConfig, GraphMetaData, String)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphAsOf(GraphConfig config, long creationTimestamp) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphAsOfAsync(GraphConfig, long)
. Calls readGraphAsOfAsync(GraphConfig, long)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphAsOf(GraphConfig config, long creationTimestamp, java.lang.String newGraphName) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphAsOfAsync(GraphConfig, long, String)
. Calls readGraphAsOfAsync(GraphConfig, long, String)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxFuture<PgxGraph> readGraphAsOfAsync(GraphConfig config, GraphMetaData metaData)
config
- the graph configmetaData
- the metaData object returned by (GraphConfig)
identifying the version to be checked outgetAvailableSnapshotsAsync(GraphConfig)
, setSnapshotAsync(PgxGraph, GraphMetaData)
public PgxFuture<PgxGraph> readGraphAsOfAsync(GraphConfig config, GraphMetaData metaData, java.lang.String newGraphName)
config
- the graph configmetaData
- the metaData object returned by (GraphConfig)
identifying the version to be checked outnewGraphName
- how the graph should be named. If null
, a name will be generated. If a graph with that name already exists, the returned future will complete exceptionally.getAvailableSnapshotsAsync(GraphConfig)
, setSnapshotAsync(PgxGraph, GraphMetaData)
public PgxFuture<PgxGraph> readGraphAsOfAsync(GraphConfig config, long creationTimestamp)
getAvailableSnapshotsAsync(GraphConfig)
config
- the graph configcreationTimestamp
- the creation timestamp (milliseconds since jan 1st 1970) identifying the version to be checked outgetAvailableSnapshotsAsync(GraphConfig)
, setSnapshotAsync(PgxGraph, long)
public PgxFuture<PgxGraph> readGraphAsOfAsync(GraphConfig config, long creationTimestamp, java.lang.String newGraphName)
getAvailableSnapshotsAsync(GraphConfig)
config
- the graph configcreationTimestamp
- the creation timestamp (milliseconds since jan 1st 1970) identifying the version to be checked outnewGraphName
- how the graph should be named. If null
, a name will be generated. If a graph with that name already exists, the returned future will complete exceptionally.getAvailableSnapshotsAsync(GraphConfig)
, setSnapshotAsync(PgxGraph, long)
public PgxGraph readGraphFile(java.lang.String path) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphFileAsync(String)
. Calls readGraphFileAsync(String)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphFile(java.lang.String path, Format format) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphFileAsync(String, Format)
. Calls readGraphFileAsync(String, Format)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphFile(java.lang.String path, Format format, java.lang.String newGraphName) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphFileAsync(String, Format, String)
. Calls readGraphFileAsync(String, Format, String)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphFile(java.lang.String path, java.lang.String newGraphName) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphFileAsync(String, String)
. Calls readGraphFileAsync(String, String)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxFuture<PgxGraph> readGraphFileAsync(java.lang.String path)
PGX will try to detect the file format and the graph configuration. If the format or the configuration cannot be determined, the future is completed exceptionally.
path
- graph file pathdescribeGraphFileAsync(String)
public PgxFuture<PgxGraph> readGraphFileAsync(java.lang.String path, Format format)
PGX will try to detect the graph configuration. If the configuration cannot be determined or if the file format does not match the given format, the future is completed exceptionally.
path
- graph file pathformat
- file formatdescribeGraphFileAsync(String, Format)
public PgxFuture<PgxGraph> readGraphFileAsync(java.lang.String path, Format format, java.lang.String newGraphName)
PGX will try to detect the graph configuration. If the configuration cannot be determined or if the file format does not match the given format, the future is completed exceptionally.
path
- graph file pathformat
- file formatnewGraphName
- how the graph should be named. If null
, a name will be generated. If a graph with that name already exists, the returned future will complete exceptionally.describeGraphFilesAsync(String, String, Format)
public PgxFuture<PgxGraph> readGraphFileAsync(java.lang.String path, java.lang.String newGraphName)
PGX will try to detect the file format and the graph configuration. If the format or the configuration cannot be determined, the future is completed exceptionally.
path
- graph file pathnewGraphName
- how the graph should be named. If null
, a name will be generated. If a graph with that name already exists, the returned future will complete exceptionally.describeGraphFileAsync(String)
public PgxGraph readGraphFiles(java.util.List<java.lang.String> filePaths) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphFilesAsync(List)
. Calls readGraphFilesAsync(List)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphFiles(java.util.List<java.lang.String> filePaths, Format format) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphFilesAsync(List, Format)
. Calls readGraphFilesAsync(List, Format)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphFiles(java.util.List<java.lang.String> filePaths, Format format, java.lang.String newGraphName) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphFilesAsync(List, String)
. Calls readGraphFilesAsync(List, String)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphFiles(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphFilesAsync(List, List)
. Calls readGraphFilesAsync(List, List)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphFiles(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths, Format format) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphFilesAsync(List, List, Format)
. Calls readGraphFilesAsync(List, List, Format)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphFiles(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths, Format format, java.lang.String newGraphName) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphFilesAsync(List, List, Format, String)
. Calls readGraphFilesAsync(List, List, Format, String)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphFiles(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths, java.lang.String newGraphName) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphFilesAsync(List, List, String)
. Calls readGraphFilesAsync(List, List, String)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphFiles(java.util.List<java.lang.String> filePaths, java.lang.String newGraphName) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphFilesAsync(List, String)
. Calls readGraphFilesAsync(List, String)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphFiles(java.lang.String vertexFilePath, java.lang.String edgeFilePath) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphFilesAsync(String, String)
. Calls readGraphFilesAsync(String, String)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphFiles(java.lang.String vertexFilePath, java.lang.String edgeFilePath, Format format) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphFilesAsync(String, String, Format)
. Calls readGraphFilesAsync(String, String, Format)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphFiles(java.lang.String vertexFilePath, java.lang.String edgeFilePath, Format format, java.lang.String newGraphName) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphFilesAsync(String, String, Format, String)
. Calls readGraphFilesAsync(String, String, Format, String)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphFiles(java.lang.String vertexFilePath, java.lang.String edgeFilePath, java.lang.String newGraphName) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphFilesAsync(String, String, String)
. Calls readGraphFilesAsync(String, String, String)
and waits for the returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxFuture<PgxGraph> readGraphFilesAsync(java.util.List<java.lang.String> filePaths)
PGX will try to detect the file format and the graph configuration. If the format or the configuration cannot be determined, the future is completed exceptionally.
filePaths
- paths to the filesdescribeGraphFilesAsync(List)
public PgxFuture<PgxGraph> readGraphFilesAsync(java.util.List<java.lang.String> filePaths, Format format)
PGX will try to detect the graph configuration. If the configuration cannot be determined or if the file format does not match the given format, the future is completed exceptionally.
filePaths
- paths to the vertex filesformat
- file formatdescribeGraphFilesAsync(List, Format)
public PgxFuture<PgxGraph> readGraphFilesAsync(java.util.List<java.lang.String> filePaths, Format format, java.lang.String newGraphName)
PGX will try to detect the graph configuration. If the configuration cannot be determined or if the file format does not match the given format, the future is completed exceptionally.
filePaths
- paths to the graph filesformat
- file formatnewGraphName
- how the graph should be named. If null
, a name will be generated. If a graph with that name already exists, the returned future will complete exceptionally.describeGraphFilesAsync(List, Format)
public PgxFuture<PgxGraph> readGraphFilesAsync(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths)
PGX will try to detect the file format and the graph configuration. If the format or the configuration cannot be determined, the future is completed exceptionally.
vertexFilePaths
- paths to the vertex filesedgeFilePaths
- paths to the edge filesdescribeGraphFilesAsync(List, List)
public PgxFuture<PgxGraph> readGraphFilesAsync(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths, Format format)
PGX will try to detect the graph configuration. If the configuration cannot be determined or if the file format does not match the given format, the future is completed exceptionally.
vertexFilePaths
- paths to the vertex filesedgeFilePaths
- paths to the edge filesformat
- file formatdescribeGraphFilesAsync(List, List, Format)
public PgxFuture<PgxGraph> readGraphFilesAsync(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths, Format format, java.lang.String newGraphName)
PGX will try to detect the graph configuration. If the configuration cannot be determined or if the file format does not match the given format, the future is completed exceptionally.
vertexFilePaths
- paths to the vertex filesedgeFilePaths
- paths to the edge filesformat
- file formatnewGraphName
- how the graph should be named. If null
, a name will be generated. If a graph with that name already exists, the returned future will complete exceptionally.describeGraphFilesAsync(List, List, Format)
public PgxFuture<PgxGraph> readGraphFilesAsync(java.util.List<java.lang.String> vertexFilePaths, java.util.List<java.lang.String> edgeFilePaths, java.lang.String newGraphName)
PGX will try to detect the file format and the graph configuration. If the format or the configuration cannot be determined, the future is completed exceptionally.
vertexFilePaths
- paths to the vertex filesedgeFilePaths
- paths to the edge filesnewGraphName
- how the graph should be named. If null
, a name will be generated. If a graph with that name already exists, the returned future will complete exceptionally.describeGraphFilesAsync(List, List)
public PgxFuture<PgxGraph> readGraphFilesAsync(java.util.List<java.lang.String> filePaths, java.lang.String newGraphName)
PGX will try to detect the file format and the graph configuration. If the format or the configuration cannot be determined, the future is completed exceptionally.
filePaths
- paths to the vertex filesnewGraphName
- how the graph should be named. If null
, a name will be generated. If a graph with that name already exists, the returned future will complete exceptionally.describeGraphFilesAsync(List)
public PgxFuture<PgxGraph> readGraphFilesAsync(java.lang.String vertexFilePath, java.lang.String edgeFilePath)
PGX will try to detect the file format and the graph configuration. If the format or the configuration cannot be determined, the future is completed exceptionally.
vertexFilePath
- path to the vertex fileedgeFilePath
- path to the edge filedescribeGraphFilesAsync(String, String)
public PgxFuture<PgxGraph> readGraphFilesAsync(java.lang.String vertexFilePath, java.lang.String edgeFilePath, Format format)
PGX will try to detect the graph configuration. If the configuration cannot be determined or if the file format does not match the given format, the future is completed exceptionally.
vertexFilePath
- path to the vertex fileedgeFilePath
- path to the edge fileformat
- file formatdescribeGraphFilesAsync(String, String, Format)
public PgxFuture<PgxGraph> readGraphFilesAsync(java.lang.String vertexFilePath, java.lang.String edgeFilePath, Format format, java.lang.String newGraphName)
PGX will try to detect the graph configuration. If the configuration cannot be determined or if the file format does not match the given format, the future is completed exceptionally.
vertexFilePath
- path to the vertex fileedgeFilePath
- path to the edge fileformat
- file formatnewGraphName
- how the graph should be named. If null
, a name will be generated. If a graph with that name already exists, the returned future will complete exceptionally.describeGraphFilesAsync(String, String, Format)
public PgxFuture<PgxGraph> readGraphFilesAsync(java.lang.String vertexFilePath, java.lang.String edgeFilePath, java.lang.String newGraphName)
PGX will try to detect the file format and the graph configuration. If the format or the configuration cannot be determined, the future is completed exceptionally.
vertexFilePath
- path to the vertex fileedgeFilePath
- path to the edge filenewGraphName
- how the graph should be named. If null
, a name will be generated. If a graph with that name already exists, the returned future will complete exceptionally.describeGraphFilesAsync(String, String)
public PgxGraph readGraphWithProperties(GraphConfig config) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphWithPropertiesAsync(GraphConfig)
. Calls readGraphWithPropertiesAsync(GraphConfig)
and waits for returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphWithProperties(GraphConfig config, boolean updateIfNotFresh) throws java.lang.InterruptedException, java.util.concurrent.ExecutionException
readGraphWithPropertiesAsync(GraphConfig, boolean)
. Calls readGraphWithPropertiesAsync(GraphConfig, boolean)
and waits for returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphWithProperties(GraphConfig config, boolean updateIfNotFresh, java.lang.String newGraphName) throws java.lang.InterruptedException, java.util.concurrent.ExecutionException
readGraphWithPropertiesAsync(GraphConfig, boolean, String)
. Calls readGraphWithPropertiesAsync(GraphConfig, boolean, String)
and waits for returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphWithProperties(GraphConfig config, long maxAge, java.util.concurrent.TimeUnit maxAgeTimeUnit) throws java.lang.InterruptedException, java.util.concurrent.ExecutionException
readGraphWithPropertiesAsync(GraphConfig, long, TimeUnit)
. Calls readGraphWithPropertiesAsync(GraphConfig, long, TimeUnit)
and waits for returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphWithProperties(GraphConfig config, long maxAge, java.util.concurrent.TimeUnit maxAgeTimeUnit, boolean blockIfFull, java.lang.String newGraphName) throws java.lang.InterruptedException, java.util.concurrent.ExecutionException
readGraphWithPropertiesAsync(GraphConfig, long, TimeUnit, boolean, String)
. Calls readGraphWithPropertiesAsync(GraphConfig, long, TimeUnit, boolean, String)
and waits for returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphWithProperties(GraphConfig config, java.lang.String newGraphName) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphWithPropertiesAsync(GraphConfig, String)
. Calls readGraphWithPropertiesAsync(GraphConfig, String)
and waits for returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphWithProperties(java.lang.String path) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphWithPropertiesAsync(String)
. Calls readGraphWithPropertiesAsync(String)
and waits for returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxGraph readGraphWithProperties(java.lang.String path, java.lang.String newGraphName) throws java.util.concurrent.ExecutionException, java.lang.InterruptedException
readGraphWithPropertiesAsync(String, String)
. Calls readGraphWithPropertiesAsync(String, String)
and waits for returned PgxFuture
to complete.java.lang.InterruptedException
- if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException
- if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxFuture<PgxGraph> readGraphWithPropertiesAsync(GraphConfig config)
config
- the graph configpublic PgxFuture<PgxGraph> readGraphWithPropertiesAsync(GraphConfig config, boolean updateIfNotFresh)
config
- the graph configupdateIfNotFresh
- if a newer data version exists in the backing data source (see PgxGraph.isFresh()
), this flag tells whether to read it and create another snapshot inside PGX. If the "snapshots_source" field of config
is SnapshotsSource.REFRESH
, the returned graph may have multiple snapshots, depending on whether previous reads with the same config
occurred; otherwise, if the "snapshots_source" field is SnapshotsSource.CHANGE_SET
, only the most recent snapshot (either pre-existing or freshly read) will be visiblepublic PgxFuture<PgxGraph> readGraphWithPropertiesAsync(GraphConfig config, boolean updateIfNotFresh, java.lang.String newGraphName)
config
- the graph configupdateIfNotFresh
- if a newer data version exists in the backing data source (see PgxGraph.isFresh()
), this flag tells whether to read it and create another snapshot inside PGX. If the "snapshots_source" field of config
is SnapshotsSource.REFRESH
, the returned graph may have multiple snapshots, depending on whether previous reads with the same config
occurred; otherwise, if the "snapshots_source" field is SnapshotsSource.CHANGE_SET
, only the most recent snapshot (either pre-existing or freshly read) will be visiblenewGraphName
- how the graph should be named. If null
, a name will be generated. If a graph with that name already exists, the returned future will complete exceptionally.public PgxFuture<PgxGraph> readGraphWithPropertiesAsync(GraphConfig config, long maxAge, java.util.concurrent.TimeUnit maxAgeTimeUnit)
config
- the graph configmaxAge
- if another snapshot of the given graph already exists, the age of the latest existing snapshot will be compared to the given maxAge. If the latest snapshot is in the given range, it will be returned, otherwise a new snapshot will be created.maxAgeTimeUnit
- the time unit of the maxAge parameterpublic PgxFuture<PgxGraph> readGraphWithPropertiesAsync(GraphConfig config, long maxAge, java.util.concurrent.TimeUnit maxAgeTimeUnit, boolean blockIfFull, java.lang.String newGraphName)
config
- the graph configmaxAge
- if another snapshot of the given graph already exists, the age of the latest existing snapshot will be compared to the given maxAge. If the latest snapshot is in the given range, it will be returned, otherwise a new snapshot will be created.maxAgeTimeUnit
- the time unit of the maxAge parameterblockIfFull
- if true
and a new snapshot needs to be created but no more snapshots are allowed by the server configuration, the returned future will not complete until space becomes available. If full and this flage is false
, the returned future will complete exceptionally instead.newGraphName
- how the graph should be named. If null
, a name will be generated. If a graph with that name already exists, the returned future will complete exceptionally.public PgxFuture<PgxGraph> readGraphWithPropertiesAsync(GraphConfig config, java.lang.String newGraphName)
config
- the graph confignewGraphName
- how the graph should be named. If null
, a name will be generated. If a graph with that name already exists, the returned future will complete exceptionally.public PgxFuture<PgxGraph> readGraphWithPropertiesAsync(java.lang.String path)
path
- a path to a graph config, e.g. 'hdfs:/path/to/config.json' or 'http://myserver.com/my-config.json'public PgxFuture<PgxGraph> readGraphWithPropertiesAsync(java.lang.String path, java.lang.String newGraphName)
path
- a path to a graph config, e.g. 'hdfs:/path/to/config.json' or 'http://myserver.com/my-config.json'newGraphName
- how the graph should be named. If null
, a name will be generated. If a graph with that name already exists, the returned future will complete exceptionally.public void registerKeystore(java.lang.String keystorePath, char[] keystorePassword)
keystorePath
- the path to the keystore to register.keystorePassword
- the path to the keystore to register.public java.util.List<?> runConcurrently(java.util.List<java.util.function.Supplier<PgxFuture<?>>> asyncRequest)
#runConcurrentlyAsync(List<Supplier>)
. Calls #runConcurrentlyAsync(List<Supplier>)
and waits for returned PgxFuture
to complete.public PgxFuture<java.util.List<?>> runConcurrentlyAsync(java.util.List<java.util.function.Supplier<PgxFuture<?>>> asyncRequestsSuppliers)
asyncRequestsSuppliers
- list of the asynchronous requests to execute concurrentlypublic void setSnapshot(PgxGraph graph, GraphMetaData metaData)
setSnapshotAsync(PgxGraph, GraphMetaData)
. Calls setSnapshotAsync(PgxGraph, GraphMetaData)
and waits for returned PgxFuture
to complete.public void setSnapshot(PgxGraph graph, GraphMetaData metaData, boolean forceDeleteProperties)
setSnapshotAsync(PgxGraph, GraphMetaData, boolean)
. Calls setSnapshotAsync(PgxGraph, GraphMetaData, boolean)
and waits for returned PgxFuture
to complete.public void setSnapshot(PgxGraph graph, long creationTimestamp)
setSnapshotAsync(PgxGraph, long)
. Calls setSnapshotAsync(PgxGraph, long)
and waits for returned PgxFuture
to complete.public void setSnapshot(PgxGraph graph, long creationTimestamp, boolean forceDeleteProperties)
setSnapshotAsync(PgxGraph, long, boolean)
. Calls setSnapshotAsync(PgxGraph, long, boolean)
and waits for returned PgxFuture
to complete.public PgxFuture<java.lang.Void> setSnapshotAsync(PgxGraph graph, GraphMetaData metaData)
graph
- the graph to be checked out to a different version. Note that transient properties cannot be checked out to a different graph version. If the given graph contains any transient properties, the returned future will complete exceptionally with an UnsupportedOperationException
set as cause. You can use setSnapshotAsync(PgxGraph, long, boolean)
to force a checkout on a graph with transient properties.metaData
- the metaData object returned by getAvailableSnapshotsAsync(GraphConfig)
identifying the version to be checked outpublic PgxFuture<java.lang.Void> setSnapshotAsync(PgxGraph graph, GraphMetaData metaData, boolean forceDeleteTransientProperties)
graph
- the graph to be checked out to a different snapshot versionmetaData
- the metaData object returned by (GraphConfig)
identifying the version to be checked outforceDeleteTransientProperties
- Graphs with transient properties cannot be checked out to a different version. If this flag is set to true
, the checked out graph will no longer contain any transient properties. If false
, the returned future will complete exceptionally with an UnsupportedOperationException
as its cause.public PgxFuture<java.lang.Void> setSnapshotAsync(PgxGraph graph, long creationTimestamp)
graph
- the graph to be checked out to a different version. Note that transient properties cannot be checked out to a different graph version. If the given graph contains any transient properties, the returned future will complete exceptionally with an UnsupportedOperationException
set as cause. You can use setSnapshotAsync(PgxGraph, long, boolean)
to force a checkout on a graph with transient properties.creationTimestamp
- the creation timestamp (milliseconds since Jan 1st 1970) identifying the version to be checked outpublic PgxFuture<java.lang.Void> setSnapshotAsync(PgxGraph graph, long creationTimestamp, boolean forceDeleteTransientProperties)
graph
- the graph to be checked out to a different snapshot versioncreationTimestamp
- the creation timestamp (milliseconds since Jan 1st 1970) identifying the version to be checked outforceDeleteTransientProperties
- Graphs with transient properties cannot be checked out to a different version. If this flag is set to true
, the checked out graph will no longer contain any transient properties. If false
, the returned future will complete exceptionally with an UnsupportedOperationException
as its cause.public java.lang.String toString()
toString
in class java.lang.Object