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 192125 - AddConnectionWizard bug
Summary: AddConnectionWizard bug
Status: RESOLVED FIXED
Alias: None
Product: db
Classification: Unclassified
Component: Code (show other bugs)
Version: 7.0
Hardware: PC Linux
: P3 normal (vote)
Assignee: Jiri Rechtacek
URL:
Keywords: REGRESSION
Depends on:
Blocks:
 
Reported: 2010-11-18 17:44 UTC by nnnnnk
Modified: 2010-11-20 06:11 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
patch (2.24 KB, text/plain)
2010-11-18 17:51 UTC, nnnnnk
Details

Note You need to log in before you can comment on or make changes to this bug.
Description nnnnnk 2010-11-18 17:44:50 UTC
Hello,

In case of Oracle driver I can not provide url, user and password for connection wizard.
updateState ignores them.

Please, fix it ASAP.
I need it for the demo session...

Regards,
Nikolay.
Comment 1 nnnnnk 2010-11-18 17:51:34 UTC
Created attachment 103077 [details]
patch

patch
Comment 2 Jiri Rechtacek 2010-11-18 19:25:28 UTC
Thanks for your patch. However, I don't understand what's a problem. Please, describe your problem in detail. I'll fix it quickly, then. Thanks
Comment 3 nnnnnk 2010-11-18 20:07:37 UTC
I'm creating wizard that uses database connection.

It's possible to select existing connection or create new one.
In most cases I already know host name for new connection, so I'd like to provide it to AddConnectionWizard.

Unfortunately for Oracle Driver AddConnectionWizard always takes host name from Bundle.properties - localhost.

Thank you very much for reply.
Comment 4 Jiri Rechtacek 2010-11-19 11:29:46 UTC
Pardon my ignorance I still don't understand the problem. Are you developing on top of NetBeans APIs? In that case post code snippet what do need, a unit test is the best. Or do you have any scenario what doesn't work correctly in UI. I suppose you have some use-case what fails when use API in your program. Thanks
Comment 5 nnnnnk 2010-11-19 12:20:06 UTC
Sorry. It seems that I didn't explain my problem well...

Yes, I'm developing on top of NetBeans APIs.

My code:
connectionManager.showAddConnectionDialog(getDriver("oracle.jdbc.OracleDriver"), "jdbc:oracle:thin:@host:1521:XE", "user", "password");

In case of oracle.jdbc.OracleDriver (contains "Oracle" substring) wizard ignores url, user and password parameters.

See AddConnectionWizard.java:338.
There are special code for Oracle driver that ignores updateState function parameters.
Comment 6 Jiri Rechtacek 2010-11-19 15:09:14 UTC
Thanks. It make it clear.
Comment 7 Jiri Rechtacek 2010-11-19 17:33:39 UTC
Nikolay, thanks for catching this regression. Your patch was applied in core-main/rev/02c83941dec2
Comment 8 nnnnnk 2010-11-19 17:55:33 UTC
Thank you very much!
Comment 9 Quality Engineering 2010-11-20 06:11:04 UTC
Integrated into 'main-golden', will be available in build *201011200001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/02c83941dec2
User: Jiri Rechtacek <jrechtacek@netbeans.org>
Log: #192125: AddConnectionWizard bug; applied Nikolay's patch, thanks