Issue Details (XML | Word | Printable)

Key: DERBY-406
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Philip Wilder
Reporter: Kathey Marsden
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Derby

Client DataSource should not require user property to be set

Created: 30/Jun/05 06:02 AM   Updated: 26/Jan/06 02:01 AM
Return to search
Component/s: Network Client
Affects Version/s: 10.1.1.0, 10.2.1.6
Fix Version/s: 10.1.2.1, 10.2.1.6

Time Tracking:
Not Specified

File Attachments:
  Size
Java Source File Licensed for inclusion in ASF works DataSourceNoUser.java 2005-06-30 06:02 AM Kathey Marsden 2 kB
Text File Licensed for inclusion in ASF works Derby406_409_410.patch 2005-07-06 10:31 PM Philip Wilder 11 kB

Resolution Date: 18/Sep/05 12:05 AM


 Description  « Hide
ClientDataSource should not require user to be set. It should default to user APP as described in:
http://incubator.apache.org/derby/docs/adminguide/cadminappsclient.html

This all seems to work ok for for DriverManager connections but fails for ClientDataSource
run the attached repro


$ java DataSourceNoUser
embedded no userid/password
client userid/password set
client no password
client no userid/no password
org.apache.derby.client.am.SqlException: null userid not supported
        at org.apache.derby.client.net.NetConnection.checkUser(NetConnection.java:998)
        at org.apache.derby.client.net.NetConnection.flowConnect(NetConnection.java:380)
        at org.apache.derby.client.net.NetConnection.initialize(NetConnection.java:233)
        at org.apache.derby.client.net.NetConnection.<init>(NetConnection.java:201)
        at org.apache.derby.jdbc.ClientDataSource.getConnection(ClientDataSource.java:156)
        at org.apache.derby.jdbc.ClientDataSource.getConnection(ClientDataSource.java:135)
        at DataSourceNoUser.main(DataSourceNoUser.java:42)


 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Repository Revision Date User Message
ASF #219256 Fri Jul 15 23:01:02 UTC 2005 djd DERBY-409 This is a potential patch for the issue brought up in DERBY-406
connectionAttributes will now default to null (aka no default)

Patch contributed by Philip Wilder 050503w@acadiau.ca
Files Changed
MODIFY /incubator/derby/code/trunk/java/client/org/apache/derby/client/am/Connection.java
MODIFY /incubator/derby/code/trunk/java/client/org/apache/derby/jdbc/ClientBaseDataSource.java

Repository Revision Date User Message
ASF #219980 Thu Jul 21 01:52:49 UTC 2005 bandaram Merge trunk change 209498 to 10.1 branch.

DERBY-406 - Sets the username to start with the default value ("APP")
DERBY-410 - Sets the server name to start with the default value ("localhost")
DERBY-409 - Adds a semi-colon in the connection class to avoid databasenames like myDBcreate=true resulting from no dividing semi-colon.

Submitted by Satheesh Bandaram (satheesh@sourcery.org)
Files Changed
MODIFY /incubator/derby/code/branches/10.1/java/testing/org/apache/derbyTesting/functionTests/master/DerbyNetClient/dataSourcePermissions_net.out
MODIFY /incubator/derby/code/branches/10.1/java/client/org/apache/derby/jdbc/ClientBaseDataSource.java
MODIFY /incubator/derby/code/branches/10.1/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/dataSourcePermissions_net.java
MODIFY /incubator/derby/code/branches/10.1/java/client/org/apache/derby/client/am/Connection.java

Repository Revision Date User Message
ASF #219981 Thu Jul 21 01:55:40 UTC 2005 bandaram Port trunk change 219256 to 10.1 branch.

DERBY-409: This is a potential patch for the issue brought up in DERBY-406 connectionAttributes will now default to null (aka no default)

Ported to 10.1 by Satheesh Bandaram (satheesh@sourcery.org)
Files Changed
MODIFY /incubator/derby/code/branches/10.1/java/client/org/apache/derby/jdbc/ClientBaseDataSource.java
MODIFY /incubator/derby/code/branches/10.1/java/client/org/apache/derby/client/am/Connection.java