Return-Path: Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: (qmail 3674 invoked from network); 7 Apr 2010 18:46:55 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 7 Apr 2010 18:46:55 -0000 Received: (qmail 12259 invoked by uid 500); 7 Apr 2010 17:46:55 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 12230 invoked by uid 500); 7 Apr 2010 17:46:55 -0000 Mailing-List: contact derby-dev-help@db.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: Delivered-To: mailing list derby-dev@db.apache.org Received: (qmail 12223 invoked by uid 99); 7 Apr 2010 17:46:55 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 07 Apr 2010 17:46:55 +0000 X-ASF-Spam-Status: No, hits=-1241.6 required=10.0 tests=ALL_TRUSTED,AWL X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 07 Apr 2010 17:46:54 +0000 Received: from brutus.apache.org (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 0EC60234C4AB for ; Wed, 7 Apr 2010 17:46:34 +0000 (UTC) Message-ID: <1276091939.48241270662394059.JavaMail.jira@brutus.apache.org> Date: Wed, 7 Apr 2010 17:46:34 +0000 (UTC) From: "Mike Matrigali (JIRA)" To: derby-dev@db.apache.org Subject: [jira] Updated: (DERBY-393) Allow multiple JVMs to have read-only access to the same directory-based database In-Reply-To: <859801425.1119850437743.JavaMail.jira@ajax.apache.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/DERBY-393?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Mike Matrigali updated DERBY-393: --------------------------------- While these hacks may allow the access to procede the results are not going to be consistent and may cause corruption. Here are some of the problems: 1) When a database is opened in write mode, not all of the data is actually on disk. Some of the dirty data is in memory (in the database cache) only accessible to the jvm that has opened the database for write. So another db opening for write if allowed would see inconsistent data. 2) a second db opening in read only mode still has to boot. This boot process has to read the log file and may need to write stuff into the log. This can cause corruption when it conflicts with the write db. > Allow multiple JVMs to have read-only access to the same directory-based database > --------------------------------------------------------------------------------- > > Key: DERBY-393 > URL: https://issues.apache.org/jira/browse/DERBY-393 > Project: Derby > Issue Type: Improvement > Components: Store > Reporter: Trejkaz > Attachments: readonly.patch > > > For an application I'm building, we needed to permit multiple JVMs to access the same database. > We couldn't easily use a network server configuration, as it would be difficult to figure out who to connect to since either user might want to view the database while the other database is offline. > We couldn't just dump all the data in a JAR file, as our databases often end up being several gigabytes in size. > So what we really need is a version of the directory store which is treated as if it were read-only. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.