From dev-return-7586-apmail-continuum-dev-archive=continuum.apache.org@continuum.apache.org Wed Nov 19 06:09:16 2008 Return-Path: Delivered-To: apmail-continuum-dev-archive@www.apache.org Received: (qmail 49357 invoked from network); 19 Nov 2008 06:09:16 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 19 Nov 2008 06:09:16 -0000 Received: (qmail 91381 invoked by uid 500); 19 Nov 2008 06:09:24 -0000 Delivered-To: apmail-continuum-dev-archive@continuum.apache.org Received: (qmail 91349 invoked by uid 500); 19 Nov 2008 06:09:24 -0000 Mailing-List: contact dev-help@continuum.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@continuum.apache.org Delivered-To: mailing list dev@continuum.apache.org Received: (qmail 91338 invoked by uid 99); 19 Nov 2008 06:09:24 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 18 Nov 2008 22:09:24 -0800 X-ASF-Spam-Status: No, hits=2.2 required=10.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of napoleonesmundocarpioramirez@gmail.com designates 209.85.200.170 as permitted sender) Received: from [209.85.200.170] (HELO wf-out-1314.google.com) (209.85.200.170) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 19 Nov 2008 06:08:00 +0000 Received: by wf-out-1314.google.com with SMTP id 25so3315954wfc.14 for ; Tue, 18 Nov 2008 22:08:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:in-reply-to:mime-version:content-type:references; bh=KK9AV5Y7HBIb2drUyFkK8aJH+hG1RK6phcwS9uWMcMo=; b=Tn3J3FyXblLQlUxDhbogaR4kOcjmY/wlx2J0AwPQQ6b8L0NJ14ITbmfCecAMUEp8W9 EoD25Jqnpo/g5RCyFZcOoWdGCXEJu9BLLxESE05kntCaitzIv7cwtAfLsVhLByjlPX5Y ZeKJR//rXEsaNBoJIEnAIM6yAeFir5hKP9Smw= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:in-reply-to:mime-version :content-type:references; b=G9sqqdlM59W9Lol8oZvySNJY2vnq+ivxbmcc6NNERbZIRQD5fz6LIB4+TRsWGguVJQ S5NHzKucgTz0rHslMXDZTzswW22ov6qkXTUJ5b8phsvV0nPpkGVQoJr5tvIymeNtz5hj pvszBDvmsORwkRHsy41P92ZcrRGKuSaQC48IM= Received: by 10.142.163.13 with SMTP id l13mr343549wfe.244.1227074925091; Tue, 18 Nov 2008 22:08:45 -0800 (PST) Received: by 10.142.223.3 with HTTP; Tue, 18 Nov 2008 22:08:45 -0800 (PST) Message-ID: Date: Wed, 19 Nov 2008 14:08:45 +0800 From: "Napoleon Esmundo C. Ramirez" To: dev@continuum.apache.org Subject: Re: Database compatibility checking step during startup In-Reply-To: MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_67612_15617150.1227074925094" References: X-Virus-Checked: Checked by ClamAV on apache.org ------=_Part_67612_15617150.1227074925094 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline On Wed, Nov 19, 2008 at 12:28 PM, Brett Porter wrote: > There's actually a version tracked in the modello metadata database table > for this purpose already. > > The tricky part is how to do the conversion - that seems to need to be done > outside of modello because of the complexity of having multiple versions > (see what it did to the data management :) I think if you init normally, but > don't load any data, then check that table for the right version, you can > decide to upgrade it before loading any data. You'll need to lock the store > accesses while that occurs. I expect we'd use some other migration tool like > has been discussed recently for the task. > > - Brett > > -- > Brett Porter > brett@apache.org > http://blogs.exist.com/bporter/ > > I saw a ContinuumModelloMetadata class in the package.jdo file, but it isn't declared as a table thus isn't persisted in the database. I verified it with a MySQL database, and that version table indeed isn't there. The conversion is the real hard part, and I agree it is the job of the migration tool. I was thinking the compatibility checking step can be used to just identify discrepancies when switching databases and to act as some fail secure mechanism when starting continuum. It seems that the initialization of the database will load the data at the same time, so I was suggesting to defer it until after the schema validation is done. - Nap ------=_Part_67612_15617150.1227074925094--