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 127139 - IOException: Could not create instance
Summary: IOException: Could not create instance
Status: RESOLVED WORKSFORME
Alias: None
Product: serverplugins
Classification: Unclassified
Component: Sun Appserver 9 (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: Vince Kraemer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-02-11 15:58 UTC by Lukas Hasik
Modified: 2008-02-20 16:22 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
stacktrace (10.19 KB, text/plain)
2008-02-11 16:02 UTC, Lukas Hasik
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Lukas Hasik 2008-02-11 15:58:27 UTC
Product Version: NetBeans IDE Dev (Build 080208)
Java: 1.6.0_04; Java HotSpot(TM) Client VM 10.0-b19
System: Windows XP version 5.1 running on x86; Cp1252; en_US (nb)
Userdir: C:\Documents and Settings\Lukas\.netbeans\dev

The exception appeared when I wanted add server (Local Default Domain) second time

INFO [org.openide.WizardDescriptor]
java.io.IOException: Could not create instance.
        at org.netbeans.modules.j2ee.sun.ide.j2ee.ui.AddDomainWizardIterator.instantiate(AddDomainWizardIterator.java:303)
        at
org.netbeans.modules.j2ee.deployment.impl.bridge.BridgingServerWizardProvider$InstantiatingIteratorBridge.instantiate(BridgingSer
verWizardProvider.java:97)
        at
org.netbeans.modules.server.ui.wizard.AddServerInstanceWizard$AddServerInstanceWizardIterator.instantiate(AddServerInstanceWizard
.java:279)
Comment 1 Lukas Hasik 2008-02-11 16:02:01 UTC
Created attachment 56461 [details]
stacktrace
Comment 2 Vince Kraemer 2008-02-11 19:45:39 UTC
instantiate is implemented as
http://bits.netbeans.org/dev/javadoc/org-openide-dialogs/org/openide/WizardDescriptor.InstantiatingIterator.html#instantiate()

dictates....

I don't know why somebody decided to print the exception at INFO level in the log...  I will take a deeper look at this
Comment 3 Vince Kraemer 2008-02-11 20:42:57 UTC
looks like WizardDescriptor.java is the one sending this message out at INFO... See WizardDescriptor.java (line 1913)
Comment 4 Jiri Rechtacek 2008-02-13 11:20:18 UTC
I don't see any problem here. If a API user implementation of WD.II.instantiate() throws some IOException, wizard
infrastructure logs it as INFO for tracking a problem later. It's intentional. The only question is why
AddDomainWizardIterator.instantiate() is called in that case of duplicate server what was caught before. IMHO the Add
Server wizard should not call instantiate() in that case.
Comment 5 Vince Kraemer 2008-02-13 20:20:58 UTC
How do I indicate that instantiate fails?
http://bits.netbeans.org/dev/javadoc/org-openide-dialogs/org/openide/WizardDescriptor.InstantiatingIterator.html#instantiate()


Do I:

1. return an empty set
2. return null
3. throw an IOException
Comment 6 Vince Kraemer 2008-02-20 16:22:08 UTC
I cannot stop the lower layer from logging an exception that the documentations says it may have to catch.