Changes in This Release for Oracle Big Data Spatial and Graph User's Guide and Reference

This preface describes significant new features and changes in Oracle Big Data Spatial and Graph User's Guide and Reference for Oracle Big Data Spatial and Graph Release 2.2.

In-Memory Analyst (PGX) Enhancements

The in-memory analyst (PGX) API has been enhanced for this release. For detailed information about any API feature, see Oracle Spatial and Graph In-Memory Analyst (PGX) Java API Reference. The more notable changes include the following:

  • Type Casting in PGQL: Data values can be cast from one data type to another using the CAST function. The syntax is like that for the SQL CAST function: CAST(expression AS datatype). For example:

    SELECT CAST(n.age AS STRING), CAST('123' AS INT), CAST('true' AS BOOLEAN)
    WHERE (n:Person)
    

    For information about PGQL, see Using Pattern-Matching Queries with Graphs.

  • Transpose of a Graph: The transpose of a directed graph is the same graph but with all of the edges reversed. You can use the new method PgxGraph.transpose() to (non-destructively) return a new graph that is a transpose of the original.

  • New Algorithms:

    • The PRIM algorithm can be used to find minimum spanning trees in a graph.

    • Additional personalization options are available for the SALSA algorithm.

  • Apache Spark Support Improvements:

    • Vertex IDs can be of string type.

    • Vertex and edge label support has been added.

  • Distributed PGX Improvements: The PGX distributed run-time implementation of the in-memory analyst now supports properties of value type string.

Spark Vector Analysis API Support for Scala

New SpatialRDD and DistributedSpatialIndex implementations have been added to provide better integration between the Spark Vector Analysis API and Scala.

The new SpatialRDD extends the native Spark’s RDD class and adds spatial transformations and actions, just like the SpatialJavaRDD class.

Both SpatialRDD and Scala’s DistributedSpatialIndex allow passing Scala function literals (lambdas) to the spatial transformations and actions, making it easier to work with the Vector API from Scala.

For information about the Scala support, see Oracle Big Data Spatial Vector Analysis for Spark.

Nearest Neighbors Using Distributed Spatial Index

The nearest neighbors action has been added to DistributedSpatialIndex. A Distrbuted Spatial Index may decrease the execution time when running the nearest neighbors action.

For more information, see Spatial Actions (MBR and NearestNeighbors).

Controlling Execution of Spatial Evaluation

You can control whether a spatial operation is evaluated before or after calling a user-defined filtering lambda when executing a filtering transformation or a nearest neighbors action.

For more information, see Controlling Spatial Evaluation.

New Utility Methods to Write Vertex and Edge Records

Two new utility methods let you write a vertex or edge record directly in Oracle flat file format, so that you no longer need to worry about encoding special characters.

  • OraclePropertyGraphUtils.outputVertexRecord(os, vid, key, value) lets you serialize a vertex record directly in Oracle flat file format. (See Vertex File.)

  • OraclePropertyGraphUtils.outputEdgeRecord(os, eid,svid, dvid, label, key, value) lets you write a new line of text in the given output stream describing the key/value property of the given edge identified with eid. (See Edge File.)