This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 205830 - java.net.UnknownHostException: plugins.netbeans.org Caused: java.io.IOException: plugins.netbeans.org , java.net.UnknownHostException: updates.netbeans.org Caused: java.io.IOException: updates.netbeans.org
Summary: java.net.UnknownHostException: plugins.netbeans.org Caused: java.io.IOExcept...
Status: RESOLVED INCOMPLETE
Alias: None
Product: platform
Classification: Unclassified
Component: Autoupdate (show other bugs)
Version: 7.1
Hardware: PC Windows XP
: P3 normal (vote)
Assignee: Jiri Rechtacek
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-12-02 10:04 UTC by Vibhuti
Modified: 2011-12-07 17:42 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Vibhuti 2011-12-02 10:04:24 UTC
Product Version = NetBeans IDE 7.1 RC1 (Build 201111242103)
Operating System = Windows XP version 5.1 running on x86
Java; VM; Vendor = 1.7.0_01
Runtime = Java HotSpot(TM) Client VM 21.1-b02

While running a module having osgi bundle and containing an installer , action and a java class got the following exceptions :

java.net.UnknownHostException: updates.netbeans.org
	at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:176)
	at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:157)
	at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:391)
	at java.net.Socket.connect(Socket.java:579)
	at sun.net.NetworkClient.doConnect(NetworkClient.java:175)
	at sun.net.www.http.HttpClient.openServer(HttpClient.java:388)
	at sun.net.www.http.HttpClient.openServer(HttpClient.java:483)
	at sun.net.www.http.HttpClient.<init>(HttpClient.java:213)
	at sun.net.www.http.HttpClient.New(HttpClient.java:300)
	at sun.net.www.http.HttpClient.New(HttpClient.java:316)
	at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:992)
	at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:928)
	at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:846)
	at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1296)
	at org.netbeans.modules.autoupdate.updateprovider.NetworkAccess$Task$2.call(NetworkAccess.java:146)
	at org.netbeans.modules.autoupdate.updateprovider.NetworkAccess$Task$2.call(NetworkAccess.java:136)
	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
	at java.util.concurrent.FutureTask.run(FutureTask.java:166)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
	at java.lang.Thread.run(Thread.java:722)
Caused: java.io.IOException: updates.netbeans.org
	at org.netbeans.modules.autoupdate.updateprovider.DownloadListener.notifyException(DownloadListener.java:103)
	at org.netbeans.modules.autoupdate.updateprovider.AutoupdateCatalogCache.copy(AutoupdateCatalogCache.java:255)
	at org.netbeans.modules.autoupdate.updateprovider.AutoupdateCatalogCache.writeCatalogToCache(AutoupdateCatalogCache.java:100)
	at org.netbeans.modules.autoupdate.updateprovider.AutoupdateCatalogProvider.refresh(AutoupdateCatalogProvider.java:137)
	at org.netbeans.modules.autoupdate.services.UpdateUnitProviderImpl.refresh(UpdateUnitProviderImpl.java:174)
	at org.netbeans.api.autoupdate.UpdateUnitProvider.refresh(UpdateUnitProvider.java:186)
[catch] at org.netbeans.modules.autoupdate.pluginimporter.libinstaller.JUnitLibraryInstaller.install(JUnitLibraryInstaller.java:96)
	at org.netbeans.modules.autoupdate.pluginimporter.libinstaller.InstallLibraryTask.run(InstallLibraryTask.java:86)
	at org.netbeans.core.startup.WarmUpSupport.run(WarmUpSupport.java:94)
	at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1411)
	at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:1991)
INFO [org.netbeans.modules.autoupdate.updateprovider.DownloadListener]: Reading URL http://plugins.netbeans.org/nbpluginportal/updates/7.1/catalog.xml.gz failed (java.net.UnknownHostException: plugins.netbeans.org)
INFO [org.netbeans.modules.autoupdate.pluginimporter.libinstaller.JUnitLibraryInstaller]: While refreshing org.netbeans.api.autoupdate.UpdateUnitProvider@1e18667[Plugin Portal[pluginportal-update-provider] to http://plugins.netbeans.org/nbpluginportal/updates/7.1/catalog.xml.gz] thrown java.io.IOException: plugins.netbeans.org
java.net.UnknownHostException: plugins.netbeans.org
	at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:176)
	at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:157)
	at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:391)
	at java.net.Socket.connect(Socket.java:579)
	at sun.net.NetworkClient.doConnect(NetworkClient.java:175)
	at sun.net.www.http.HttpClient.openServer(HttpClient.java:388)
	at sun.net.www.http.HttpClient.openServer(HttpClient.java:483)
	at sun.net.www.http.HttpClient.<init>(HttpClient.java:213)
	at sun.net.www.http.HttpClient.New(HttpClient.java:300)
	at sun.net.www.http.HttpClient.New(HttpClient.java:316)
	at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:992)
	at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:928)
	at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:846)
	at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1296)
	at org.netbeans.modules.autoupdate.updateprovider.NetworkAccess$Task$2.call(NetworkAccess.java:146)
	at org.netbeans.modules.autoupdate.updateprovider.NetworkAccess$Task$2.call(NetworkAccess.java:136)
	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
	at java.util.concurrent.FutureTask.run(FutureTask.java:166)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
	at java.lang.Thread.run(Thread.java:722)
Caused: java.io.IOException: plugins.netbeans.org
	at org.netbeans.modules.autoupdate.updateprovider.DownloadListener.notifyException(DownloadListener.java:103)
	at org.netbeans.modules.autoupdate.updateprovider.AutoupdateCatalogCache.copy(AutoupdateCatalogCache.java:255)
	at org.netbeans.modules.autoupdate.updateprovider.AutoupdateCatalogCache.writeCatalogToCache(AutoupdateCatalogCache.java:100)
	at org.netbeans.modules.autoupdate.updateprovider.AutoupdateCatalogProvider.refresh(AutoupdateCatalogProvider.java:137)
	at org.netbeans.modules.autoupdate.services.UpdateUnitProviderImpl.refresh(UpdateUnitProviderImpl.java:174)
	at org.netbeans.api.autoupdate.UpdateUnitProvider.refresh(UpdateUnitProvider.java:186)
[catch] at org.netbeans.modules.autoupdate.pluginimporter.libinstaller.JUnitLibraryInstaller.install(JUnitLibraryInstaller.java:96)
	at org.netbeans.modules.autoupdate.pluginimporter.libinstaller.InstallLibraryTask.run(InstallLibraryTask.java:86)
	at org.netbeans.core.startup.WarmUpSupport.run(WarmUpSupport.java:94)
	at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1411)
	at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:1991)
INFO [org.netbeans.modules.autoupdate.updateprovider.DownloadListener]: Reading URL http://updates.netbeans.org/netbeans/updates/7.1/uc/final/distribution/catalog.xml.gz?unique=NB_CND_GFMOD_GROOVY_JAVA_JC_MOB_PHP_WEBEE0a8d488d1-14ca-46c1-996c-1e7d997b5da3_514a27a4-488f-4804-bb02-4bee861deba2 failed (java.net.UnknownHostException: updates.netbeans.org)
INFO [org.netbeans.modules.autoupdate.pluginimporter.libinstaller.JUnitLibraryInstaller]: While refreshing org.netbeans.api.autoupdate.UpdateUnitProvider@18e882f[NetBeans Distribution[distribution-update-provider] to http://updates.netbeans.org/netbeans/updates/7.1/uc/final/distribution/catalog.xml.gz?unique=NB_CND_GFMOD_GROOVY_JAVA_JC_MOB_PHP_WEBEE0a8d488d1-14ca-46c1-996c-1e7d997b5da3_514a27a4-488f-4804-bb02-4bee861deba2] thrown java.io.IOException: updates.netbeans.org
java.net.UnknownHostException: updates.netbeans.org
	at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:176)
	at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:157)
	at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:391)
	at java.net.Socket.connect(Socket.java:579)
	at sun.net.NetworkClient.doConnect(NetworkClient.java:175)
	at sun.net.www.http.HttpClient.openServer(HttpClient.java:388)
	at sun.net.www.http.HttpClient.openServer(HttpClient.java:483)
	at sun.net.www.http.HttpClient.<init>(HttpClient.java:213)
	at sun.net.www.http.HttpClient.New(HttpClient.java:300)
	at sun.net.www.http.HttpClient.New(HttpClient.java:316)
	at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:992)
	at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:928)
	at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:846)
	at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1296)
	at org.netbeans.modules.autoupdate.updateprovider.NetworkAccess$Task$2.call(NetworkAccess.java:146)
	at org.netbeans.modules.autoupdate.updateprovider.NetworkAccess$Task$2.call(NetworkAccess.java:136)
	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
	at java.util.concurrent.FutureTask.run(FutureTask.java:166)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
	at java.lang.Thread.run(Thread.java:722)
Caused: java.io.IOException: updates.netbeans.org
	at org.netbeans.modules.autoupdate.updateprovider.DownloadListener.notifyException(DownloadListener.java:103)
	at org.netbeans.modules.autoupdate.updateprovider.AutoupdateCatalogCache.copy(AutoupdateCatalogCache.java:255)
	at org.netbeans.modules.autoupdate.updateprovider.AutoupdateCatalogCache.writeCatalogToCache(AutoupdateCatalogCache.java:100)
	at org.netbeans.modules.autoupdate.updateprovider.AutoupdateCatalogProvider.refresh(AutoupdateCatalogProvider.java:137)
	at org.netbeans.modules.autoupdate.services.UpdateUnitProviderImpl.refresh(UpdateUnitProviderImpl.java:174)
	at org.netbeans.api.autoupdate.UpdateUnitProvider.refresh(UpdateUnitProvider.java:186)
[catch] at org.netbeans.modules.autoupdate.pluginimporter.libinstaller.JUnitLibraryInstaller.install(JUnitLibraryInstaller.java:96)
	at org.netbeans.modules.autoupdate.pluginimporter.libinstaller.InstallLibraryTask.run(InstallLibraryTask.java:86)
	at org.netbeans.core.startup.WarmUpSupport.run(WarmUpSupport.java:94)
	at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1411)
	at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:1991)
BUILD SUCCESSFUL (total time: 9 minutes 41 seconds)
Comment 1 Jiri Rechtacek 2011-12-02 13:20:54 UTC
Okay, what is the problem? Probably your application cannot access updates.netbeans.org. Are you behind a proxy? I need more information, test-case, description to evaluate this.
Comment 2 Vibhuti 2011-12-04 11:47:46 UTC
(In reply to comment #1)
> Okay, what is the problem? Probably your application cannot access
> updates.netbeans.org. Are you behind a proxy? I need more information,
> test-case, description to evaluate this.


I tested the TS 69 Apisupport OSGI on :

Product Version: NetBeans IDE 7.1 RC1 (Build 201111242103)
Java: 1.7.0_01; Java HotSpot(TM) Client VM 21.1-b02
System: Windows XP version 5.1 running on x86; Cp1252; en_US (nb)
User directory: C:\Documents and Settings\Pithwa\.netbeans\7.1rc1
Cache directory: C:\Documents and Settings\Pithwa\.netbeans\7.1rc1\var\cache

The test case i am referring to is http://wiki.netbeans.org/TS_69_Apisupport_OSGI#Test_suite:_Ant_OSGi_Bundle

Steps to reproduce the bug is : 
1. Create OSGi Bundle
    In new project wizard, choose NetBeans Module project (Module)
    Fill in some data, and on panel 3, check "Generate OSGi Bundle" 
2. Create some package and class in it 
3. Create from new file template Installer/Activator
type some code into start() method (try to print to stdout                 c.getBundles().length)
4. Clean and build project 
5.  Create new Action from new file template
    This adds dependency to couple NB modules
6.  Build and run project


I noticed that i get the previously mentioned exception if the module is runned for the first time and that too the internet connection is off. If it is runned for the next time the exception doesn't occur.