Sunday, April 28, 2019

Create scala project on eclipse

  1. Choose a workspace where the data is stored
  2. Create a new Scala project
  3. Give it any name
  4. Create a new package in the project
  5. Give a name to the package
  6. Import files
  7. General-> File systems
  8. Browse to directory
  9. Click the file you want then click finish
  10. Might get those errors
  11. Right click project -> properties
  12. Java build path->Libraries->Add external JARs
  13. Go to spark folder->Jars->Add all
  14. There might still be a problem with Scala version
  15. Project right click properties
  16. Scala compiler->then change scala installation
  17. To compile and run. Run->run configurations
  18. Double click Scala Application -> Give a name to run -> Main class is the name of the package.<object_name>

DO NOT FORGET TO RENAME THE PACKAGE DEFINITION AT THE BEGININNG OF THE FILES!!! package com.abolfadl.spark
YOU COULD HAVE ONLY ONE SCRIPT WITH MAIN, NOT MULTIPLE!!

No comments:

Post a Comment

Loud fan of desktop

 Upon restart the fan of the desktop got loud again. I cleaned the desktop from the dust but it was still loud (Lower than the first sound) ...