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 149286 - Connection Pool Password property cannot be created if db password is blank
Summary: Connection Pool Password property cannot be created if db password is blank
Status: RESOLVED FIXED
Alias: None
Product: serverplugins
Classification: Unclassified
Component: Sun Appserver 9 (show other bugs)
Version: 6.x
Hardware: All All
: P2 blocker (vote)
Assignee: Nitya Doraisamy
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-10-06 21:05 UTC by John Baker
Modified: 2008-10-07 17:23 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
Visual Web project connecting to MySQL (26.01 KB, application/x-compressed)
2008-10-07 06:03 UTC, John Baker
Details

Note You need to log in before you can comment on or make changes to this bug.
Description John Baker 2008-10-06 21:05:16 UTC
If MySQL is installed without specifying a password, then a Password property cannot be created in the Connection pool.

A couple of ways to reproduce:

First install MySQL without a root password (or change the root password to blank)
and Connect to MySQL using the Services window and create a new sample database (sample, travel or vir)

1) Create a new Web Application using the Visual Web framework
2) Using the Palette, drag and drop a Dropdown component
3) From Services, drag and drop a database table from the sample database connection
4) Execute

Result- error in browser, No PasswordCredential found

Another way to reproduce:

1) Create a new Java Web application
2) try to a Connection pool for the datasource of the sample database

Result- the connection pool dialog won't allow a pool to be created without a password.
Comment 1 Vince Kraemer 2008-10-06 21:13:48 UTC
The 'another way' got cleaned up recently in 6.5... if a property value is empty, the error message at the bottom of the
wizard should include the 'Use "()" ...' hint.

I think the first method comes from the ResourceConfigurator.java
Comment 2 Nitya Doraisamy 2008-10-07 03:24:59 UTC
John, Could you attach the project created using the first method?
Comment 3 John Baker 2008-10-07 06:03:17 UTC
Created attachment 71252 [details]
Visual Web project connecting to MySQL
Comment 4 Nitya Doraisamy 2008-10-07 07:13:24 UTC
The plugin zero config and resource wizards need to be updated to accept empty password for connection pools.

I noticed that the 'Use Database ..' context action does not allow selecting a valid database connection with empty
password. 

Will fix the plugin to accept empty password's for connection pools. Filed Issue 149317 for 'Use Database ..' action to
accept empty password.
Comment 5 Nitya Doraisamy 2008-10-07 15:49:44 UTC
fixed
Comment 6 Quality Engineering 2008-10-07 17:23:52 UTC
Integrated into 'main-golden', will be available in build *200810071401* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/18e988beec86
User: nityad@netbeans.org
Log: #149286 : Handle empty password in create cp resource using wizard from existing connection.
Also accept empty password via zero-config and store as '()'