[
https://issues.apache.org/jira/browse/SPARK-12529?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Sean Owen resolved SPARK-12529.
-------------------------------
Resolution: Cannot Reproduce
> Spark streaming: java.lang.NoSuchFieldException: SHUTDOWN_HOOK_PRIORITY
> -----------------------------------------------------------------------
>
> Key: SPARK-12529
> URL: https://issues.apache.org/jira/browse/SPARK-12529
> Project: Spark
> Issue Type: Bug
> Components: Spark Core
> Affects Versions: 1.5.2
> Environment: MacOSX Standalone
> Reporter: Brad Cox
>
> Posted originally on stackoverflow. Reposted here on request by Josh Rosen.
> I'm trying to start spark streaming in standalone mode (MacOSX) and getting
> the following error nomatter what:
> Exception in thread "main" java.lang.ExceptionInInitializerError at
> org.apache.spark.storage.DiskBlockManager.addShutdownHook(DiskBlockManager.scala:147)
> at org.apache.spark.storage.DiskBlockManager.(DiskBlockManager.scala:54) at
> org.apache.spark.storage.BlockManager.(BlockManager.scala:75) at
> org.apache.spark.storage.BlockManager.(BlockManager.scala:173) at
> org.apache.spark.SparkEnv$.create(SparkEnv.scala:347) at
> org.apache.spark.SparkEnv$.createDriverEnv(SparkEnv.scala:194) at
> org.apache.spark.SparkContext.createSparkEnv(SparkContext.scala:277) at
> org.apache.spark.SparkContext.(SparkContext.scala:450) at
> org.apache.spark.streaming.StreamingContext$.createNewSparkContext(StreamingContext.scala:566)
> at
> org.apache.spark.streaming.StreamingContext$.createNewSparkContext(StreamingContext.scala:578)
> at org.apache.spark.streaming.StreamingContext.(StreamingContext.scala:90)
> at
> org.apache.spark.streaming.api.java.JavaStreamingContext.(JavaStreamingContext.scala:78)
> at io.ascolta.pcap.PcapOfflineReceiver.main(PcapOfflineReceiver.java:103)
> Caused by: java.lang.NoSuchFieldException: SHUTDOWN_HOOK_PRIORITY at
> java.lang.Class.getField(Class.java:1584) at
> org.apache.spark.util.SparkShutdownHookManager.install(ShutdownHookManager.scala:220)
> at
> org.apache.spark.util.ShutdownHookManager$.shutdownHooks$lzycompute(ShutdownHookManager.scala:50)
> at
> org.apache.spark.util.ShutdownHookManager$.shutdownHooks(ShutdownHookManager.scala:48)
> at
> org.apache.spark.util.ShutdownHookManager$.addShutdownHook(ShutdownHookManager.scala:189)
> at org.apache.spark.util.ShutdownHookManager$.(ShutdownHookManager.scala:58)
> at org.apache.spark.util.ShutdownHookManager$.(ShutdownHookManager.scala) ...
> 13 more
> This symptom is discussed in relation to EC2 at
> https://forums.databricks.com/questions/2227/shutdown-hook-priority-javalangnosuchfieldexceptio.html
> as a Hadoop2 dependency. But I'm running locally (for now), and am using the
> spark-1.5.2-bin-hadoop2.6.tgz binary from
> https://spark.apache.org/downloads.html which I'd hoped would eliminate this
> possibility.
> I've pruned my code down to essentially nothing; like this:
> SparkConf conf = new SparkConf()
> .setAppName(appName)
> .setMaster(master);
> JavaStreamingContext ssc = new JavaStreamingContext(conf, new
> Duration(1000));
> I've permuted maven dependencies to ensure all spark stuff is consistent at
> version 1.5.2. Yet the ssc initialization above fails nomatter what. So I
> thought it was time to ask for help.
> Build environment is eclipse and maven with the shade plugin. Launch/run is
> from eclipse debugger, not spark-submit, for now.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]