Return-Path: Delivered-To: apmail-jakarta-commons-user-archive@www.apache.org Received: (qmail 99736 invoked from network); 20 Dec 2004 14:43:48 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 20 Dec 2004 14:43:48 -0000 Received: (qmail 28701 invoked by uid 500); 20 Dec 2004 14:42:43 -0000 Delivered-To: apmail-jakarta-commons-user-archive@jakarta.apache.org Received: (qmail 28675 invoked by uid 500); 20 Dec 2004 14:42:43 -0000 Mailing-List: contact commons-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Jakarta Commons Users List" Reply-To: "Jakarta Commons Users List" Delivered-To: mailing list commons-user@jakarta.apache.org Received: (qmail 28654 invoked by uid 99); 20 Dec 2004 14:42:42 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: pass (hermes.apache.org: local policy) Received: from s2.ukfsn.org (HELO mail.ukfsn.org) (217.158.120.143) by apache.org (qpsmtpd/0.28) with ESMTP; Mon, 20 Dec 2004 06:42:39 -0800 Received: from localhost (lucy.ukfsn.org [127.0.0.1]) by mail.ukfsn.org (Postfix) with ESMTP id A5AF1E6D45 for ; Mon, 20 Dec 2004 14:39:59 +0000 (GMT) Received: from mail.ukfsn.org ([127.0.0.1]) by localhost (lucy.ukfsn.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 11589-19 for ; Mon, 20 Dec 2004 14:39:59 +0000 (GMT) Received: from [194.203.211.119] (194-203-211-119.kbcfp.net [194.203.211.119]) by mail.ukfsn.org (Postfix) with ESMTP id 6FD02E6A9F for ; Mon, 20 Dec 2004 14:39:59 +0000 (GMT) Message-ID: <41C6E4BF.1070402@darkcoding.net> Date: Mon, 20 Dec 2004 14:42:07 +0000 From: Graham King User-Agent: Mozilla Thunderbird 0.7 (Windows/20040616) X-Accept-Language: en-us, en MIME-Version: 1.0 To: commons-user@jakarta.apache.org Subject: [dbcp] setReadOnly always being called Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Using Hibernate, DBCP and Sybase I am getting the following warning from Hibernate: 010SK: Database cannot set connection option SET_READONLY_FALSE This is because DBCP's PoolableConnectionFactory.activateObject(..) method is calling 'setReadOnly' on the Connection and the database does not support it. Hibernate spots the warning and logs it. There is a guard in the 'activateObject' method to only call setReadOnly if '_defaultReadOnly' is not null. All the constructors of PoolableConnectionFactory set '_defaultReadOnly' to a 'boolean' so it will never be null. This goes against what the docs (http://jakarta.apache.org/commons/dbcp/configuration.html) say about the defaultReadOnly config parameter: "If not set then the setReadOnly method will not be called". Has anyone else come across this ? Is there a workaround ? Should I log this as a bug ? Thanks in advance, Graham King. --------------------------------------------------------------------- To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: commons-user-help@jakarta.apache.org