Package

com.datastax.bdp.graph.spark

graphframe

Permalink

package graphframe

The root package of DSE GraphFrame support. Offers handy implicit conversions that add DSE-specific methods to SparkSession and GraphFrame.

Call dseGraph method on the SparkSession object to create a GraphFrame exposing DSE Graph as Spark GraphFrame.

Example:

import com.datastax.bdp.graph.spark.graphframe._

val graphName = "test"
// Read graph and print vertices labels:
val graph = spark.dseGraph(graphName)
graph.V().select("label").distinct.show
Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. graphframe
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. class BasicDseGraphFrame extends DseGraphFrame

    Permalink

    Minimal read only DseGraphFrame implementation that wraps a GraphFrame to run traversal.

    Minimal read only DseGraphFrame implementation that wraps a GraphFrame to run traversal. Update and delete methods are not supported and will throw a NotImplementedError.

  2. class DGFCleaner extends AnyRef

    Permalink
  3. class DGFCleanerInterceptor extends SparkVertexProgramInterceptor[CleanGraphVertexProgram]

    Permalink
  4. class DGFCleanupStats extends AnyRef

    Permalink
  5. abstract class DseGraphFrame extends Serializable

    Permalink

    Provides DSE Graph-specific methods on GraphFrames.

    Provides DSE Graph-specific methods on GraphFrames. A DseGraphFrame requires a graphName for creating some traversal steps and for writing data back to DSE. Implicit conversions ensure the graphName is preserved or reassigned since it can be lost during a DseGraphFrame->GraphFrame->DseGraphFrame transition chain.

  6. abstract class DseGraphFrameBuilder extends AnyRef

    Permalink
  7. class DseGraphTraversal[E] extends DefaultGraphTraversal[Row, E]

    Permalink

    wrap vertex data frame to implement TinkerPop functions

  8. class SparkSessionFunctions extends Serializable

    Permalink

    Provides DSE-specific methods on SparkSession

Value Members

  1. object DGFCleaner

    Permalink
  2. object DseGraphFrame extends Serializable

    Permalink
  3. object DseGraphFrameBuilder

    Permalink

    Usage: val dataFrame = DseGraphFrameBuilder("graph", spark).dataFrame()

  4. object DseGraphMigration

    Permalink
  5. object DseGraphSchemaMigration

    Permalink
  6. object Order

    Permalink

    The spark-shell show may show an "ambiguous reference to overloaded definition" error for two functions: GraphTraversal.by(Order) and GraphTraversal.by(Comparable)

    The spark-shell show may show an "ambiguous reference to overloaded definition" error for two functions: GraphTraversal.by(Order) and GraphTraversal.by(Comparable)

    Here is an example:

    scala>  g.V().values("name").order().by(Order.decr)
    console>:43: error: ambiguous reference to overloaded definition,
    both method by in trait GraphTraversal of type (x$1: org.apache.tinkerpop.gremlin.process.traversal.Order)org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.GraphTraversal[org.apache.spark.sql.Row,E2]
    and  method by in trait GraphTraversal of type (x$1: java.util.Comparator[E2])org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.GraphTraversal[org.apache.spark.sql.Row,E2]
    match argument types (org.apache.tinkerpop.gremlin.process.traversal.Order)

    To workaround this problem a user can directly cast Order to super class: Comparable

    scala> g.V().values("name").order().by(Order.decr.asInstanceOf[Order])

    This is an inconvenient workaround, so this class replicates the Order interface but returns Comparable instead of Order. Users should import this object to avoid the aforementioned issues.

  7. object VertexLabelDropInterceptor extends DseGraphTraversalInterceptor

    Permalink
  8. implicit def backToDseVertexFrame[E](gt: GraphTraversal[Row, E]): DseGraphTraversal[E]

    Permalink

  9. package classic

    Permalink
  10. package dsedb

    Permalink
  11. implicit def fromDseGraphFrame(gf: DseGraphFrame): GraphFrame

    Permalink
  12. implicit def fromVertexFrame[E](gt: GraphTraversal[Row, E]): DataFrame

    Permalink

    add all DataFrame functions to DseGraphTraversal

  13. package optimizer

    Permalink
  14. implicit def toDseGraphFrame(gf: GraphFrame): DseGraphFrame

    Permalink
  15. implicit def toSparkSessionFunctions(spark: SparkSession): SparkSessionFunctions

    Permalink

Inherited from AnyRef

Inherited from Any

Ungrouped