2010-12-17 88 views
1

我正在從事Eclipse中的Java項目。我可以啓動應用程序(運行爲),我工作正常,但我無法啓動調試爲(我可以啓動調試爲,但突然間我不能了)。有沒有人有這種奇怪的東西經驗?Eclipse無法啓動調試爲


@dimitrisil 在調試控制檯

MainWindow (1) [Java Application] 
    com.euroicc.histo.view.MainWindow at localhost:4325 
     Thread [AWT-Shutdown] (Running) 
     Daemon Thread [AWT-Windows] (Running) 
     Thread [AWT-EventQueue-0] (Suspended (exception NumberFormatException)) 
      Integer.parseInt(String, int) line: not available 
      Integer.<init>(String) line: not available 
      InetAddressCachePolicy.<clinit>() line: not available 
      InetAddress$Cache.getPolicy() line: not available 
      InetAddress$Cache.put(String, Object) line: not available 
      InetAddress.cacheInitIfNeeded() line: not available 
      InetAddress.cacheAddress(String, Object, boolean) line: not available 
      InetAddress.getAddressFromNameService(String, InetAddress) line: not available 
      InetAddress.getLocalHost() line: not available 
      SeedGenerator$1.run() line: not available 
      AccessController.doPrivileged(PrivilegedAction<T>) line: not available [native method] 
      SeedGenerator.getSystemEntropy() line: not available  
      SecureRandom.engineNextBytes(byte[]) line: not available  
      SecureRandom.nextBytes(byte[]) line: not available 
      SecureRandom.next(int) line: not available 
      SecureRandom(Random).nextLong() line: not available 
      File.generateFile(String, String, File) line: not available 
      File.createTempFile(String, String, File) line: not available 
      FileCacheImageInputStream.<init>(InputStream, File) line: not available 
      InputStreamImageInputStreamSpi.createInputStreamInstance(Object, boolean, File) line: not available 
      ImageIO.createImageInputStream(Object) line: not available 
      ImageIO.read(URL) line: not available 
      BrushedMetalDecorationPainter.<init>() line: 69 
      BusinessBlackSteelSkin.<init>() line: 135 
      SubstanceBusinessBlackSteelLookAndFeel.<init>() line: 54  
      MainWindow$7.run() line: 238  
      InvocationEvent.dispatch() line: not available 
      EventQueue.dispatchEvent(AWTEvent) line: not available 
      EventDispatchThread.pumpOneEventForFilters(int) line: not available 
      EventDispatchThread.pumpEventsForFilter(int, Conditional, EventFilter) line: not available 
      EventDispatchThread.pumpEventsForHierarchy(int, Conditional, Component) line: not available 
      EventDispatchThread.pumpEvents(int, Conditional) line: not available  
      EventDispatchThread.pumpEvents(Conditional) line: not available 
      EventDispatchThread.run() line: not available 
     Thread [DestroyJavaVM] (Running)  
    C:\Program Files\Java\jre1.6.0_17\bin\javaw.exe (17.12.2010. 15.00.45) 
MainWindow (1) [Java Application] 
    com.euroicc.histo.view.MainWindow at localhost:4363 
     Thread [AWT-Shutdown] (Running) 
     Daemon Thread [AWT-Windows] (Running) 
     Thread [AWT-EventQueue-0] (Suspended (exception NumberFormatException)) 
      Integer.parseInt(String, int) line: not available 
      Integer.<init>(String) line: not available 
      InetAddressCachePolicy.<clinit>() line: not available 
      InetAddress$Cache.getPolicy() line: not available 
      InetAddress$Cache.put(String, Object) line: not available 
      InetAddress.cacheInitIfNeeded() line: not available 
      InetAddress.cacheAddress(String, Object, boolean) line: not available 
      InetAddress.getAddressFromNameService(String, InetAddress) line: not available 
      InetAddress.getLocalHost() line: not available 
      SeedGenerator$1.run() line: not available 
      AccessController.doPrivileged(PrivilegedAction<T>) line: not available [native method] 
      SeedGenerator.getSystemEntropy() line: not available  
      SecureRandom.engineNextBytes(byte[]) line: not available  
      SecureRandom.nextBytes(byte[]) line: not available 
      SecureRandom.next(int) line: not available 
      SecureRandom(Random).nextLong() line: not available 
      File.generateFile(String, String, File) line: not available 
      File.createTempFile(String, String, File) line: not available 
      FileCacheImageInputStream.<init>(InputStream, File) line: not available 
      InputStreamImageInputStreamSpi.createInputStreamInstance(Object, boolean, File) line: not available 
      ImageIO.createImageInputStream(Object) line: not available 
      ImageIO.read(URL) line: not available 
      BrushedMetalDecorationPainter.<init>() line: 69 
      BusinessBlackSteelSkin.<init>() line: 135 
      SubstanceBusinessBlackSteelLookAndFeel.<init>() line: 54  
      MainWindow$7.run() line: 238  
      InvocationEvent.dispatch() line: not available 
      EventQueue.dispatchEvent(AWTEvent) line: not available 
      EventDispatchThread.pumpOneEventForFilters(int) line: not available 
      EventDispatchThread.pumpEventsForFilter(int, Conditional, EventFilter) line: not available 
      EventDispatchThread.pumpEventsForHierarchy(int, Conditional, Component) line: not available 
      EventDispatchThread.pumpEvents(int, Conditional) line: not available  
      EventDispatchThread.pumpEvents(Conditional) line: not available 
      EventDispatchThread.run() line: not available 
     Thread [DestroyJavaVM] (Running)  
    C:\Program Files\Java\jre1.6.0_17\bin\javaw.exe (17.12.2010. 15.01.06) 
MainWindow (1) [Java Application] 
    com.euroicc.histo.view.MainWindow at localhost:4369 
     Thread [AWT-Shutdown] (Running) 
     Daemon Thread [AWT-Windows] (Running) 
     Thread [AWT-EventQueue-0] (Suspended (exception NumberFormatException)) 
      Integer.parseInt(String, int) line: not available 
      Integer.<init>(String) line: not available 
      InetAddressCachePolicy.<clinit>() line: not available 
      InetAddress$Cache.getPolicy() line: not available 
      InetAddress$Cache.put(String, Object) line: not available 
      InetAddress.cacheInitIfNeeded() line: not available 
      InetAddress.cacheAddress(String, Object, boolean) line: not available 
      InetAddress.getAddressFromNameService(String, InetAddress) line: not available 
      InetAddress.getLocalHost() line: not available 
      SeedGenerator$1.run() line: not available 
      AccessController.doPrivileged(PrivilegedAction<T>) line: not available [native method] 
      SeedGenerator.getSystemEntropy() line: not available  
      SecureRandom.engineNextBytes(byte[]) line: not available  
      SecureRandom.nextBytes(byte[]) line: not available 
      SecureRandom.next(int) line: not available 
      SecureRandom(Random).nextLong() line: not available 
      File.generateFile(String, String, File) line: not available 
      File.createTempFile(String, String, File) line: not available 
      FileCacheImageInputStream.<init>(InputStream, File) line: not available 
      InputStreamImageInputStreamSpi.createInputStreamInstance(Object, boolean, File) line: not available 
      ImageIO.createImageInputStream(Object) line: not available 
      ImageIO.read(URL) line: not available 
      BrushedMetalDecorationPainter.<init>() line: 69 
      BusinessBlackSteelSkin.<init>() line: 135 
      SubstanceBusinessBlackSteelLookAndFeel.<init>() line: 54  
      MainWindow$7.run() line: 238  
      InvocationEvent.dispatch() line: not available 
      EventQueue.dispatchEvent(AWTEvent) line: not available 
      EventDispatchThread.pumpOneEventForFilters(int) line: not available 
      EventDispatchThread.pumpEventsForFilter(int, Conditional, EventFilter) line: not available 
      EventDispatchThread.pumpEventsForHierarchy(int, Conditional, Component) line: not available 
      EventDispatchThread.pumpEvents(int, Conditional) line: not available  
      EventDispatchThread.pumpEvents(Conditional) line: not available 
      EventDispatchThread.run() line: not available 
     Thread [DestroyJavaVM] (Running)  
    C:\Program Files\Java\jre1.6.0_17\bin\javaw.exe (17.12.2010. 15.01.30) 
MainWindow (1) [Java Application] 
    com.euroicc.histo.view.MainWindow at localhost:4383 
     Thread [AWT-Shutdown] (Running) 
     Daemon Thread [AWT-Windows] (Running) 
     Thread [AWT-EventQueue-0] (Suspended (exception NumberFormatException)) 
      Integer.parseInt(String, int) line: not available 
      Integer.<init>(String) line: not available 
      InetAddressCachePolicy.<clinit>() line: not available 
      InetAddress$Cache.getPolicy() line: not available 
      InetAddress$Cache.put(String, Object) line: not available 
      InetAddress.cacheInitIfNeeded() line: not available 
      InetAddress.cacheAddress(String, Object, boolean) line: not available 
      InetAddress.getAddressFromNameService(String, InetAddress) line: not available 
      InetAddress.getLocalHost() line: not available 
      SeedGenerator$1.run() line: not available 
      AccessController.doPrivileged(PrivilegedAction<T>) line: not available [native method] 
      SeedGenerator.getSystemEntropy() line: not available  
      SecureRandom.engineNextBytes(byte[]) line: not available  
      SecureRandom.nextBytes(byte[]) line: not available 
      SecureRandom.next(int) line: not available 
      SecureRandom(Random).nextLong() line: not available 
      File.generateFile(String, String, File) line: not available 
      File.createTempFile(String, String, File) line: not available 
      FileCacheImageInputStream.<init>(InputStream, File) line: not available 
      InputStreamImageInputStreamSpi.createInputStreamInstance(Object, boolean, File) line: not available 
      ImageIO.createImageInputStream(Object) line: not available 
      ImageIO.read(URL) line: not available 
      BrushedMetalDecorationPainter.<init>() line: 69 
      BusinessBlackSteelSkin.<init>() line: 135 
      SubstanceBusinessBlackSteelLookAndFeel.<init>() line: 54  
      MainWindow$7.run() line: 238  
      InvocationEvent.dispatch() line: not available 
      EventQueue.dispatchEvent(AWTEvent) line: not available 
      EventDispatchThread.pumpOneEventForFilters(int) line: not available 
      EventDispatchThread.pumpEventsForFilter(int, Conditional, EventFilter) line: not available 
      EventDispatchThread.pumpEventsForHierarchy(int, Conditional, Component) line: not available 
      EventDispatchThread.pumpEvents(int, Conditional) line: not available  
      EventDispatchThread.pumpEvents(Conditional) line: not available 
      EventDispatchThread.run() line: not available 
     Thread [DestroyJavaVM] (Running)  
    C:\Program Files\Java\jre1.6.0_17\bin\javaw.exe (17.12.2010. 15.05.23) 
MainWindow (1) [Java Application] 
    com.euroicc.histo.view.MainWindow at localhost:2740 
     Thread [AWT-Shutdown] (Running) 
     Daemon Thread [AWT-Windows] (Running) 
     Thread [AWT-EventQueue-0] (Suspended (exception NumberFormatException)) 
      Integer.parseInt(String, int) line: not available 
      Integer.<init>(String) line: not available 
      InetAddressCachePolicy.<clinit>() line: not available 
      InetAddress$Cache.getPolicy() line: not available 
      InetAddress$Cache.put(String, Object) line: not available 
      InetAddress.cacheInitIfNeeded() line: not available 
      InetAddress.cacheAddress(String, Object, boolean) line: not available 
      InetAddress.getAddressFromNameService(String, InetAddress) line: not available 
      InetAddress.getLocalHost() line: not available 
      SeedGenerator$1.run() line: not available 
      AccessController.doPrivileged(PrivilegedAction<T>) line: not available [native method] 
      SeedGenerator.getSystemEntropy() line: not available  
      SecureRandom.engineNextBytes(byte[]) line: not available  
      SecureRandom.nextBytes(byte[]) line: not available 
      SecureRandom.next(int) line: not available 
      SecureRandom(Random).nextLong() line: not available 
      File.generateFile(String, String, File) line: not available 
      File.createTempFile(String, String, File) line: not available 
      FileCacheImageInputStream.<init>(InputStream, File) line: not available 
      InputStreamImageInputStreamSpi.createInputStreamInstance(Object, boolean, File) line: not available 
      ImageIO.createImageInputStream(Object) line: not available 
      ImageIO.read(URL) line: not available 
      BrushedMetalDecorationPainter.<init>() line: 69 
      BusinessBlackSteelSkin.<init>() line: 135 
      SubstanceBusinessBlackSteelLookAndFeel.<init>() line: 54  
      MainWindow$7.run() line: 238  
      InvocationEvent.dispatch() line: not available 
      EventQueue.dispatchEvent(AWTEvent) line: not available 
      EventDispatchThread.pumpOneEventForFilters(int) line: not available 
      EventDispatchThread.pumpEventsForFilter(int, Conditional, EventFilter) line: not available 
      EventDispatchThread.pumpEventsForHierarchy(int, Conditional, Component) line: not available 
      EventDispatchThread.pumpEvents(int, Conditional) line: not available  
      EventDispatchThread.pumpEvents(Conditional) line: not available 
      EventDispatchThread.run() line: not available 
     Thread [DestroyJavaVM] (Running)  
    C:\Program Files\Java\jre1.6.0_17\bin\javaw.exe (17.12.2010. 16.17.11) 
MainWindow (1) [Java Application] 
    com.euroicc.histo.view.MainWindow at localhost:2926 
     Thread [AWT-Shutdown] (Running) 
     Daemon Thread [AWT-Windows] (Running) 
     Thread [DestroyJavaVM] (Running)  
     Thread [AWT-EventQueue-0] (Suspended (exception NumberFormatException)) 
      Integer.parseInt(String, int) line: not available 
      Integer.<init>(String) line: not available 
      InetAddressCachePolicy.<clinit>() line: not available 
      InetAddress$Cache.getPolicy() line: not available 
      InetAddress$Cache.put(String, Object) line: not available 
      InetAddress.cacheInitIfNeeded() line: not available 
      InetAddress.cacheAddress(String, Object, boolean) line: not available 
      InetAddress.getAddressFromNameService(String, InetAddress) line: not available 
      InetAddress.getLocalHost() line: not available 
      SeedGenerator$1.run() line: not available 
      AccessController.doPrivileged(PrivilegedAction<T>) line: not available [native method] 
      SeedGenerator.getSystemEntropy() line: not available  
      SecureRandom.engineNextBytes(byte[]) line: not available  
      SecureRandom.nextBytes(byte[]) line: not available 
      SecureRandom.next(int) line: not available 
      SecureRandom(Random).nextLong() line: not available 
      File.generateFile(String, String, File) line: not available 
      File.createTempFile(String, String, File) line: not available 
      FileCacheImageInputStream.<init>(InputStream, File) line: not available 
      InputStreamImageInputStreamSpi.createInputStreamInstance(Object, boolean, File) line: not available 
      ImageIO.createImageInputStream(Object) line: not available 
      ImageIO.read(URL) line: not available 
      BrushedMetalDecorationPainter.<init>() line: 69 
      BusinessBlackSteelSkin.<init>() line: 135 
      SubstanceBusinessBlackSteelLookAndFeel.<init>() line: 54  
      MainWindow$7.run() line: 238  
      InvocationEvent.dispatch() line: not available 
      EventQueue.dispatchEvent(AWTEvent) line: not available 
      EventDispatchThread.pumpOneEventForFilters(int) line: not available 
      EventDispatchThread.pumpEventsForFilter(int, Conditional, EventFilter) line: not available 
      EventDispatchThread.pumpEventsForHierarchy(int, Conditional, Component) line: not available 
      EventDispatchThread.pumpEvents(int, Conditional) line: not available  
      EventDispatchThread.pumpEvents(Conditional) line: not available 
      EventDispatchThread.run() line: not available 
    C:\Program Files\Java\jre1.6.0_17\bin\javaw.exe (17.12.2010. 16.37.37) 
+2

那你找回或不是看到調試器來阻止你的第一個斷點? – dimitrisli 2010-12-17 15:26:43

回答

0

我已經看到了這兩個菜單成爲單獨搞不清自己的目標。例如,對於Ant構建文件,將繼續標題爲「Run As> Ant Build」,另一個將命名爲其他內容,並失敗。

重新啓動Eclipse始終解決了這個問題。

+0

我已重新啓動並且沒有任何幫助 – Damir 2010-12-17 15:37:11

0

根據真正應該成爲問題一部分的(格式錯誤)答案,它看起來像您可能有一個格式錯誤的套接字地址。

的NumberFormatException的重複了一遍又一遍,在問候INetAddress.getLocalhost ...

啊!你有IPv4還是IPv6?如果一個v4(十進制)解釋器試圖解析一個v6(十六進制)地址,那麼事情可能會被破壞。

它也可能是你的調試套接字號碼不是一個數字(至少不是小數)......但我沒有看到在UI中的任何地方來調整這一點,所以我不明白你可能會打破它。

0

只是爲了將來有人會遇到同樣的問題。最近我被相同的用例(但是在NetBeans中)所迷惑 - 問題是由於我之前創建的java.lang.IllegalArgumentException的斷點造成的,並且忘記了它,所以IDE始終停在某處Java核心代碼只是因爲這個斷點,但我認爲這是由我的代碼或運行時環境中的東西引起的:(

實際上,我會說這個問題通常是核心Java庫中的編碼風格。在if()條件更合適的情況下,有很多地方會拋出異常,這會導致Exceptions調試中的主要問題 - 只有太多的問題,在這種特殊情況下,它是由以下行(我從這裏採取InetAddressCachePolicy的來源http://download.java.net/openjdk/jdk6/):

try { 
     tmp = new Integer(
      java.security.AccessController.doPrivileged (
      new PrivilegedAction<String>() { 
       public String run() { 
        return Security.getProperty(cachePolicyProp); 
       } 
      })); 
    } catch (NumberFormatException e) { 
     // ignore 
    } 

您可能會注意到,編寫代碼的人知道配置中提供了潛在的'not-a-number'字符串,但沒有試圖處理更優雅的字符串爲空或空的情況,實際上就是這個問題。

有相關的討論有關的Integer.parseInt()在這裏 - Java: Good way to encapsulate Integer.parseInt()