Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

unable to download the jar com.crealytics:spark-excel_2.10:jar:0.8.2 even after adding to the porm.xml #2

Closed
ghost opened this issue Oct 24, 2016 · 10 comments

Comments

@ghost
Copy link

ghost commented Oct 24, 2016

jar is not able to be downloaded automatically

Failed to find data source: com.crealytics.spark.excel

com.crealytics spark-excel_2.10 0.8.2

could find below note from the spark packages page

u'Maven coordinate should be groupId:artifactId but got com.crealytics:spark-google-adwords_2.11:0.8.2.'

@nightscape
Copy link
Collaborator

Hi @bssulfikkar,

that's workable, thanks for rephrasing the issue 👍
I just published the version to Sonatype, it should appear here within the next hours:
https://repo1.maven.org/maven2/com/crealytics/spark-excel_2.11/0.8.2/
When this link doesn't give you a 404 anymore then you should be able to start spark-shell with the package like this

spark-shell --packages com.crealytics:spark-excel_2.11:0.8.2

@ghost
Copy link
Author

ghost commented Oct 25, 2016

Hi @nightscape

Thanks for the information. Could you please let me know how can I utilize the com.crealytics.spark.excel for running the code from local eclipse.

import org.apache.spark.sql.SQLContext
import org.apache.spark.{SparkConf, SparkContext}

object Test {
def main(args:Array[String]): Unit ={
val conf = new SparkConf().setAppName("Test-Excel Importer").setMaster("local[*]")
val sc = new SparkContext(conf)
val sqlContext = new SQLContext(sc)
val df = sqlContext.read
.format("com.crealytics.spark.excel")
.option("location", "GL.xlsx")
.option("sheetName", "ISDA")
.option("useHeader", "true")
.option("treatEmptyValuesAsNulls", "true")
.option("inferSchema", "true")
.option("addColorColumns", "true")
.load("GL")
df.printSchema()
df.show()
}
}

Error is

Exception in thread "main" java.lang.ClassNotFoundException: Failed to find data source: com.crealytics.spark.excel. Please find packages at http://spark-packages.org

@ghost
Copy link
Author

ghost commented Oct 25, 2016

Description Resource Path Location Type
spark-excel_2.11-0.8.2.jar of sulfi build path is cross-compiled with an incompatible version of Scala (2.11.0). In case this report is mistaken, this check can be disabled in the compiler preference page. sulfi Unknown Scala Version Problem

I may need to use the 2.11.0 jar... or 2.10 version jars.

@nightscape
Copy link
Collaborator

It sounds like you are using a Spark version based on Scala 2.10, so in that case you have to use the 2.10 version of this plugin as well.

@ghost
Copy link
Author

ghost commented Oct 26, 2016

i am using scala plugin version 2.11 and using the scala compilor of 2.10...How can I get the jar spark-excel with 2.10 version..

@nightscape
Copy link
Collaborator

The same way you got the 2.11 one (SBT, Maven, Gradle, manual download, whatever), just replace 2.11 by 2.10.

@nightscape
Copy link
Collaborator

@bssulfikkar Can this issue be closed?

@shoffing
Copy link
Contributor

https://repo1.maven.org/maven2/com/crealytics/spark-excel_2.10/0.8.2/
404 Not Found

Is there a released 2.10 version?

@nightscape
Copy link
Collaborator

Hmm, I thought I had published for 2.10 as well, but my memory fails me quite frequently 😉
@shoffing I just tried the link and now it shows some files.
Can you check and report back here?

@shoffing
Copy link
Contributor

Yes, I also see the files now. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants