db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From david myers <david.myers.scibearsp...@gmail.com>
Subject Re: Get a "read-only" connection using Derby EmbeddedDataSource40
Date Fri, 31 Aug 2012 19:59:02 GMT

Have you though about using the 'roles' that are available.

Create a role that has 'read only access', then add your user to that 
role. This is the link to the page in the docs.

Then when you log in you log in a that specified 'read only' user. You 
can hard code this into the interface, and give a menu item to enable 
users to log in at a 'higher' level.

Also you can hook your derby into LDAP or other directory name service, 
and use a 'non priveleged user' from there.


On 31/08/12 17:25, Alain Kuchta wrote:
> Thank you for bringing this  to my attention.
> *From:*Katherine Marsden [mailto:kmarsdenderby@sbcglobal.net]
> *Sent:* Friday, August 31, 2012 11:23 AM
> *To:* Derby Discussion
> *Subject:* Re: Get a "read-only" connection using Derby 
> EmbeddedDataSource40
> On 8/31/2012 7:05 AM, Alain Kuchta wrote:
>     Hello all,
>     I've actually found an answer to my own question in the Derby
>     Reference Manual.
>     The java.sql.Connection method "setReadOnly(boolean)" is supported
>     and performs as I desired.
>     Perhaps someone else will found this snippet useful.
> One word of caution: While Connection.setReadOnly works fine for 
> Embedded.   There is a long standing  issue with the call with Client:
> https://issues.apache.org/jira/browse/DERBY-911

View raw message