需要在Netbeans中编译Spark的一些帮助



我一直在下载我需要在Netbeans中编译Spark的所有. jar文件。但是我现在被困在一个点上,不知道如何继续。

下面是我尝试构建spark时的输出:

C:UserspstongeDesktopWorkspaceSpark Source 2.6.3srcjavaorgjivesoftwareSparkStartupListener.java:31: error: package com.install4j.api.launcher.StartupNotification does not exist
public class SparkStartupListener implements com.install4j.api.launcher.StartupNotification.Listener {
C:UserspstongeDesktopWorkspaceSpark Source 2.6.3srcjavaorgjivesoftwarelauncherInstaller.java:23: error: package com.install4j.api.actions does not exist
import com.install4j.api.actions.InstallAction;
C:UserspstongeDesktopWorkspaceSpark Source 2.6.3srcjavaorgjivesoftwarelauncherInstaller.java:24: error: package com.install4j.api.context does not exist
import com.install4j.api.context.Context;
C:UserspstongeDesktopWorkspaceSpark Source 2.6.3srcjavaorgjivesoftwarelauncherInstaller.java:25: error: package com.install4j.api.context does not exist
import com.install4j.api.context.InstallerContext;
C:UserspstongeDesktopWorkspaceSpark Source 2.6.3srcjavaorgjivesoftwarelauncherInstaller.java:26: error: package com.install4j.api.context does not exist
import com.install4j.api.context.UserCanceledException;
C:UserspstongeDesktopWorkspaceSpark Source 2.6.3srcjavaorgjivesoftwarelauncherInstaller.java:27: error: package com.install4j.api.windows does not exist
import com.install4j.api.windows.RegistryRoot;
C:UserspstongeDesktopWorkspaceSpark Source 2.6.3srcjavaorgjivesoftwarelauncherInstaller.java:28: error: package com.install4j.api.windows does not exist
import com.install4j.api.windows.WinRegistry;

我试着下载软件包,但我似乎找不到它们。此外,当我尝试在NetBeans中使用SVN时,我一直得到以下错误:

==[IDE]== May 6, 2014 9:23:21 AM Updating "SpellcheckChatRoomDecorator.java" to HEAD
update C:/Users/pstonge/Desktop/Workspace/Spark Source 2.6.3/src/plugins/spelling/src/java/org/jivesoftware/spellchecker/SpellcheckChatRoomDecorator.java -r HEAD --force
svn: E175002: timed out waiting for server
svn: E175002: OPTIONS request failed on '/svn/repos/spark/trunk/src/plugins/spelling/src/java/org/jivesoftware/spellchecker'
svn: E175002: timed out waiting for server
svn: E175002: OPTIONS request failed on '/svn/repos/spark/trunk/src/plugins/spelling/src/java/org/jivesoftware/spellchecker'
Connect timed out
==[IDE]== May 6, 2014 9:24:30 AM Updating "SpellcheckChatRoomDecorator.java" to HEAD finished.

如果有人能给我一些关于如何继续构建的线索,那就太好了。

非常感谢。保罗

我使用Maven在Netbeans上构建Spark。如下:

  • 从NetBeans安装大于7.4的NetBeans(8是最好的)网站
  • 从Netbeans插件网站安装Scala插件
  • 按照下面的说明将它安装到netbeans中。
  • 创建Maven项目:新建项目-> Maven -> project From prototype ->选择"scala- prototype -simple" -> "Next" -> "Finish"。
  • 打开POM文件,将内容替换为以下内容:

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
  <groupId>group.programming</groupId>
  <artifactId>myproject</artifactId>
  <version>1.0-SNAPSHOT</version>
  <name>myproject</name>
  <description>My wonderfull scala app</description>
  <inceptionYear>2014</inceptionYear>
  <licenses>
    <license>
      <name>My License</name>
      <distribution>repo</distribution>
    </license>
  </licenses>
<properties>
    <maven.compiler.source>3.1</maven.compiler.source>
    <maven.compiler.target>3.1</maven.compiler.target>
    <encoding>UTF-8</encoding>
    <!--<scala.version>2.10.3</scala.version>-->
    <scalaCompatVersion>2.10</scalaCompatVersion>
    <maven.scala.checkConsistency>false</maven.scala.checkConsistency>
  </properties>

  <dependencies>
<!--    <dependency>
      <groupId>org.scala-lang</groupId>
      <artifactId>scala-library</artifactId>
      <version>${scala.version}</version>
    </dependency>-->
<dependency>
    <groupId>org.apache.spark</groupId>
    <artifactId>spark-core_2.10</artifactId>
    <version>1.0.1</version>
</dependency>
    <!-- Test -->
<!--    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>4.11</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.scala-tools.testing</groupId>
      <artifactId>specs</artifactId>
      <version>1.6.2.2_1.5.0</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.scalatest</groupId>
      <artifactId>scalatest_2.10</artifactId>
      <version>2.2.0</version>
      <scope>test</scope>
    </dependency>-->
  </dependencies>
  <build>
    <sourceDirectory>src/main/scala</sourceDirectory>
    <testSourceDirectory>src/test/scala</testSourceDirectory>
    <plugins>
      <plugin>
        <groupId>net.alchim31.maven</groupId>
        <artifactId>scala-maven-plugin</artifactId>
        <version>3.1.6</version>
        <executions>
          <execution>
            <goals>
              <goal>compile</goal>
              <!--<goal>testCompile</goal>-->
            </goals>
            <configuration>
              <args>
<!--                <arg>-make:transitive</arg>-->
                <arg>-dependencyfile</arg>
                <arg>${project.build.directory}/.scala_dependencies</arg>
              </args>
            </configuration>
          </execution>
        </executions>
<configuration>
  <launchers>
    <launcher>
      <id>sample</id>
      <!-- This is to set the main to App.scala-->
      <mainClass>myproject.App</mainClass>
      <args>
        <arg>${basedir}</arg>
      </args>
    </launcher>
  </launchers>
</configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-surefire-plugin</artifactId>
        <version>2.6</version>
        <configuration>
          <useFile>false</useFile>
          <disableXmlReport>true</disableXmlReport>
          <!-- If you have classpath issue like NoDefClassError,... -->
          <!-- useManifestOnlyJar>false</useManifestOnlyJar -->
          <includes>
<!--            <include>**/*Test.*</include> -->
            <include>**/*Suite.*</include>
          </includes>
        </configuration>
      </plugin>
    </plugins>
  </build>
</project>

相关内容

  • 没有找到相关文章

最新更新