db-derby-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kahat...@apache.org
Subject svn commit: r400014 - /db/derby/docs/trunk/src/adminguide/radminappsclientxmp.dita
Date Fri, 05 May 2006 08:57:23 GMT
Author: kahatlen
Date: Fri May  5 01:57:20 2006
New Revision: 400014

URL: http://svn.apache.org/viewcvs?rev=400014&view=rev
Log:
DERBY-1287: Derby Server and Administration Guide - Network client
driver examples

Improvements to the network client driver examples. Patch contributed
by Halley Pacheco de Oliveira.

Modified:
    db/derby/docs/trunk/src/adminguide/radminappsclientxmp.dita

Modified: db/derby/docs/trunk/src/adminguide/radminappsclientxmp.dita
URL: http://svn.apache.org/viewcvs/db/derby/docs/trunk/src/adminguide/radminappsclientxmp.dita?rev=400014&r1=400013&r2=400014&view=diff
==============================================================================
--- db/derby/docs/trunk/src/adminguide/radminappsclientxmp.dita (original)
+++ db/derby/docs/trunk/src/adminguide/radminappsclientxmp.dita Fri May  5 01:57:20 2006
@@ -19,10 +19,22 @@
 <reference id="radminappsclientxmp" xml:lang="en-us">
 <title>Network client driver examples</title>
 <refbody>
+<section>
+<p>The following examples specify the user and password URL attributes. 
+To enable user authentication, the  property <i>derby.connection.requireAuthentication</i>
+must be set to true, otherwise, <ph conref="adminconrefs.dita#prod/productshortname"></ph>
+does not require a user name and password. For a multi-user product, you would
+typically set it for the system in the <i>derby.properties</i> file for your
+server, since it is in a trusted environment. Below is a sample
+<i>derby.properties</i> file that conforms to these examples:
+<codeblock>derby.connection.requireAuthentication=true
+derby.authentication.provider=BUILTIN
+derby.user.judy=no12see</codeblock></p>
+</section>
 <section><title>Example 1</title><p>The following example connects
to the
 default server name localhost on the default port, 1527, and to the database
-sample. It specifies the user and password URL attributes. You must set these
-attributes before attempting to connect to the server.</p><codeblock>jdbc:derby://localhost:1527/sample;user=judy;password=no12see</codeblock></section>
+sample.</p>
+<codeblock>jdbc:derby://localhost:1527/sample;user=judy;password=no12see</codeblock></section>
 <section><title>Example 2</title><p>The following example specifies
both <ph
 conref="adminconrefs.dita#prod/productshortname"></ph> and Network Client
 driver attributes:  <codeblock>jdbc:derby://localhost:1527/sample;create=true;user=judy;
@@ -37,8 +49,8 @@
 Class.forName("org.apache.derby.jdbc.ClientDriver");
 <b>// Set user and password properties</b>
 Properties properties = new Properties();
-properties.put("user", "APP");
-properties.put("password", "APP");
+properties.put("user", "judy");
+properties.put("password", "no12see");
 <b>// Get a connection</b>
 Connection conn = DriverManager.getConnection(databaseURL, properties); </codeblock></section>
 </refbody>



Mime
View raw message