Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

SparkSession class not found in spark-sql-2.1

SOLVED Go to solution

SparkSession class not found in spark-sql-2.1

Hi,

 

Unable to import SparkSession class that is available from Spark-sql version 2.x. Here is my gradle entry:

sparkVersion        = '1.6.0-cdh5.11.0'

    spark_sql          = "org.apache.spark:spark-sql_2.10:$sparkVersion"

 

Here I assume spark-sql_2.10 is spark 2.x version, not 1.6.

When I expanded spark-sql_2.10-1.6.0-cdh5.11.0-sources.jar, i don't see SparkSession class in org.apache.spark.sql package.

 

Can you please clarify when I am not able to see SparkSession class or point to right  repository etnry.

 

Appreciate your help.

 

Thanks,

Ravi Papisetti

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted

Re: SparkSession class not found in spark-sql-2.1

This issue got resolved after changing to spark 2.1 version. I understand that in cloudera mvn artifactory, number associated to spark-core-2.10 is scala version, 1.6.0 associated with CDH is spark version.

2 REPLIES 2
Highlighted

Re: SparkSession class not found in spark-sql-2.1

This issue got resolved after changing to spark 2.1 version. I understand that in cloudera mvn artifactory, number associated to spark-core-2.10 is scala version, 1.6.0 associated with CDH is spark version.

Re: SparkSession class not found in spark-sql-2.1

New Contributor

can you post your maven dependencies for spark?