From dev-return-20401-apmail-openjpa-dev-archive=openjpa.apache.org@openjpa.apache.org Fri Apr 20 17:35:07 2012 Return-Path: X-Original-To: apmail-openjpa-dev-archive@www.apache.org Delivered-To: apmail-openjpa-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 01E849EA9 for ; Fri, 20 Apr 2012 17:35:07 +0000 (UTC) Received: (qmail 92884 invoked by uid 500); 20 Apr 2012 17:35:06 -0000 Delivered-To: apmail-openjpa-dev-archive@openjpa.apache.org Received: (qmail 92780 invoked by uid 500); 20 Apr 2012 17:35:06 -0000 Mailing-List: contact dev-help@openjpa.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@openjpa.apache.org Delivered-To: mailing list dev@openjpa.apache.org Received: (qmail 92633 invoked by uid 99); 20 Apr 2012 17:35:06 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 20 Apr 2012 17:35:06 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 20 Apr 2012 17:35:02 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id A704248CC7D for ; Fri, 20 Apr 2012 17:34:41 +0000 (UTC) Date: Fri, 20 Apr 2012 17:34:41 +0000 (UTC) From: "Heath Thomann (Updated) (JIRA)" To: dev@openjpa.apache.org Message-ID: <1140797980.10480.1334943281685.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <963487506.4026.1329914028939.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Updated] (OPENJPA-2139) OpenJPA fails to recover from a broken database on startup 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/OPENJPA-2139?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Heath Thomann updated OPENJPA-2139: ----------------------------------- Attachment: OPENJPA-2139-1.2.x.patch Will provide detailed comments about this patch shortly. Thanks, Heath > OpenJPA fails to recover from a broken database on startup > ---------------------------------------------------------- > > Key: OPENJPA-2139 > URL: https://issues.apache.org/jira/browse/OPENJPA-2139 > Project: OpenJPA > Issue Type: Bug > Affects Versions: 2.2.0 > Reporter: Mark Struberg > Assignee: Mark Struberg > Priority: Critical > Fix For: 2.3.0 > > Attachments: OPENJPA-2139-1.2.x.patch, OPENJPA-2139.mdr.patch, OPENJPA-2139.patch > > > The following scenario: > 1.) turn off the database > 2.) perform a query against the database > 3.) turn on the database > 4.) try to re-run the query from 2.) > In 4.) you will get the following Exception: > openjpa-2.2.0-r422266:1244990 nonfatal user error> org.apache.openjpa.persistence.ArgumentException: An error occurred while parsing the query filter "SELECT k FROM DbEnumKey AS k where k.type=:typ ORDER BY k.ordinal". Error message: The name "DbEnumKey" is not a recognized entity or identifier. Known entity names: [] > Basically the whole app is stale afterwards! > Solution: caching the entities might only be done if a connection can be established. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira