// Path: core/src/main/java/it/nerdammer/spash/shell/api/fs/SpashFileSystem.java
// public final class SpashFileSystem {
// 
//     private static final FileSystemFacade FACADE_INSTANCE = new FileSystemFacadeImpl(SpashConfig.getInstance().hdfsHost(), SpashConfig.getInstance().hdfsPort());
// 
//     private SpashFileSystem() {
//     }
// 
//     public static FileSystemFacade get() {
//         return FACADE_INSTANCE;
//     }
// 
// }
// 
// Path: core/src/main/java/it/nerdammer/spash/shell/api/spark/SpashSparkSubsystem.java
// public class SpashSparkSubsystem {
// 
//     private static final SparkFacade FACADE_INSTANCE;
// 
//     static {
//         String master = System.getProperty("spark.master");
//         if(master==null) {
//             System.setProperty("spark.master", "local");
//         }
// 
//         SparkConf conf = new SparkConf().setAppName("Spash");
//         JavaSparkContext sc = new JavaSparkContext(conf);
//         FACADE_INSTANCE = new SparkFacadeImpl(sc);
//     }
// 
//     private SpashSparkSubsystem() {
//     }
// 
//     public static SparkFacade get() {
//         return FACADE_INSTANCE;
//     }
// }


import it.nerdammer.spash.shell.api.fs.SpashFileSystem;
import it.nerdammer.spash.shell.api.spark.SpashSparkSubsystem;
import org.apache.sshd.server.SshServer;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.util.Arrays;
package it.nerdammer.spash.shell;



/**
 * The main class of the application.
 *
 * @author Nicola Ferraro
 */
public class Spash {

    public static void main(String[] args) throws Exception {

        Logger logger = LoggerFactory.getLogger(Spash.class);

        logger.info("Initializing the file system");
        SpashFileSystem.get().getFileSystem();

        logger.info("Initializing Spark by running a simple job");
// Path: core/src/main/java/it/nerdammer/spash/shell/api/fs/SpashFileSystem.java
// public final class SpashFileSystem {
// 
//     private static final FileSystemFacade FACADE_INSTANCE = new FileSystemFacadeImpl(SpashConfig.getInstance().hdfsHost(), SpashConfig.getInstance().hdfsPort());
// 
//     private SpashFileSystem() {
//     }
// 
//     public static FileSystemFacade get() {
//         return FACADE_INSTANCE;
//     }
// 
// }
// 
// Path: core/src/main/java/it/nerdammer/spash/shell/api/spark/SpashSparkSubsystem.java
// public class SpashSparkSubsystem {
// 
//     private static final SparkFacade FACADE_INSTANCE;
// 
//     static {
//         String master = System.getProperty("spark.master");
//         if(master==null) {
//             System.setProperty("spark.master", "local");
//         }
// 
//         SparkConf conf = new SparkConf().setAppName("Spash");
//         JavaSparkContext sc = new JavaSparkContext(conf);
//         FACADE_INSTANCE = new SparkFacadeImpl(sc);
//     }
// 
//     private SpashSparkSubsystem() {
//     }
// 
//     public static SparkFacade get() {
//         return FACADE_INSTANCE;
//     }
// }


// Path: core/src/main/java/it/nerdammer/spash/shell/Spash.java
import it.nerdammer.spash.shell.api.fs.SpashFileSystem;
import it.nerdammer.spash.shell.api.spark.SpashSparkSubsystem;
import org.apache.sshd.server.SshServer;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.util.Arrays;

package it.nerdammer.spash.shell;



/**
 * The main class of the application.
 *
 * @author Nicola Ferraro
 */
public class Spash {

    public static void main(String[] args) throws Exception {

        Logger logger = LoggerFactory.getLogger(Spash.class);

        logger.info("Initializing the file system");
        SpashFileSystem.get().getFileSystem();

        logger.info("Initializing Spark by running a simple job");
        SpashSparkSubsystem.get().parallelize(Arrays.asList(1, 2, 3)).collect();