Return-Path: Delivered-To: apmail-db-derby-user-archive@www.apache.org Received: (qmail 85057 invoked from network); 21 Jul 2006 19:02:13 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 21 Jul 2006 19:02:13 -0000 Received: (qmail 95299 invoked by uid 500); 21 Jul 2006 19:02:12 -0000 Delivered-To: apmail-db-derby-user-archive@db.apache.org Received: (qmail 95275 invoked by uid 500); 21 Jul 2006 19:02:11 -0000 Mailing-List: contact derby-user-help@db.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: List-Id: Reply-To: "Derby Discussion" Delivered-To: mailing list derby-user@db.apache.org Received: (qmail 95264 invoked by uid 99); 21 Jul 2006 19:02:11 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 21 Jul 2006 12:02:11 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [63.247.81.241] (HELO tss8.serverconfig.com) (63.247.81.241) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 21 Jul 2006 12:02:10 -0700 Received: from rrcs-67-52-41-92.west.biz.rr.com ([67.52.41.92] helo=[127.0.0.1]) by tss8.serverconfig.com with esmtpa (Exim 4.52) id 1G40Fx-0000tD-Ea for derby-user@db.apache.org; Fri, 21 Jul 2006 15:01:49 -0400 Message-ID: <44C124BB.5070408@decoursey.net> Date: Fri, 21 Jul 2006 14:02:19 -0500 From: Paul J DeCoursey User-Agent: Thunderbird 1.5.0.4 (Windows/20060516) MIME-Version: 1.0 To: Derby Discussion Subject: Re: Embedded in Servlet on Tomcat? References: <44C0C3BF.8070109@stanczakgroup.com> <44C121BB.8070206@gmail.com> In-Reply-To: <44C121BB.8070206@gmail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - tss8.serverconfig.com X-AntiAbuse: Original Domain - db.apache.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - decoursey.net X-Source: X-Source-Args: X-Source-Dir: X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Stanley Bradbury wrote: > Stanczak Group wrote: >> How does one get Derby embedded in a servlet under Tomcat. In my >> development environment I'm using Netbeans and Tomcat. Tomcat install >> is under root so I can't write to is, just my web modules >> directories. I can connect to a path with Netbeans's database tool, >> but when I launch the app on Tomcat I get errors that it can't create >> files like createDD.jdbc and derby.log. I'm guessing this is because >> Derby is showing it's home as the root of the Tomcat server. The >> question is why and how can I fix this? I have an absolute path set, >> but it still does it. Shouldn't it write everything to that path and >> not just start writing to where ever it decides home is? >> > Hi - > > For embedded Derby to work properly it needs to be loaded high in the > classloader hierarchy of the server. As far as I know this cannot be > done by an application, the application layer has too many > restrictions and Derby is designed to be a shared resource. Sharing > Derby is done by integrating Derby with Tomcat as described in the > JPetStore write-up at: > > http://db.apache.org/derby/integrate/DerbyTomcat5512JPetStor.html > > I believe that Derby in client/server architecture might be your only > choice if you cannot get Derby embedded as a global resource at the > Server level. > > > I've made it a staticly accessible resource. I use my own database management container, the DataSource container for tomcat has been too heavy for my needs. I've also set it up in Spring successfully. Paul