Return-Path: Delivered-To: apmail-cxf-users-archive@www.apache.org Received: (qmail 88891 invoked from network); 1 Oct 2008 11:04:56 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 1 Oct 2008 11:04:56 -0000 Received: (qmail 52635 invoked by uid 500); 1 Oct 2008 11:04:53 -0000 Delivered-To: apmail-cxf-users-archive@cxf.apache.org Received: (qmail 52596 invoked by uid 500); 1 Oct 2008 11:04:53 -0000 Mailing-List: contact users-help@cxf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@cxf.apache.org Delivered-To: mailing list users@cxf.apache.org Received: (qmail 52584 invoked by uid 99); 1 Oct 2008 11:04:53 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 01 Oct 2008 04:04:53 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of andrew.clegg@gmail.com designates 64.233.184.237 as permitted sender) Received: from [64.233.184.237] (HELO wr-out-0506.google.com) (64.233.184.237) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 01 Oct 2008 11:03:52 +0000 Received: by wr-out-0506.google.com with SMTP id c30so208635wra.14 for ; Wed, 01 Oct 2008 04:04:08 -0700 (PDT) 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:mime-version:content-type:content-transfer-encoding :content-disposition; bh=tDYfBj8JXO9uNG2MehTsHL86nmdq/f//i8ghqF0ETKY=; b=hZ14yOfOZ/HLWzBoYkbbd8Mv3TlTe+yGoM66AwooJhf8kjwIZrMuAsB4krgqmO8qhk /4RuzHf+QWK9nlgIeUBR9Ytq3Whj4DYAWsMdxOKNQnObGI02UvP4BUKPQQTwNprjsf+O pjBp8XZCyqhqlmwAXTp7iUVlu6eoXALHLoMGk= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:mime-version:content-type :content-transfer-encoding:content-disposition; b=Wb/JqlWLMY4mSJg2QEYwa/DvISfMJmhZXy+6InBu9muUbZquQTlwO6kHzsyepGQwPx KGg4GM7Dc/hRvkYJh2YTmn6UBivPnPEHpmUrfPSibSzorAelU7yaud0UHbaxS6mDxmXE wLvCKiffTkGCWrZX4J8T9SQQcL4vU22hCUi50= Received: by 10.151.112.19 with SMTP id p19mr11875452ybm.65.1222859048777; Wed, 01 Oct 2008 04:04:08 -0700 (PDT) Received: by 10.65.252.10 with HTTP; Wed, 1 Oct 2008 04:04:08 -0700 (PDT) Message-ID: Date: Wed, 1 Oct 2008 12:04:08 +0100 From: "Andrew Clegg" To: "users@cxf.apache.org" Subject: Persistent helper objects on server side MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline X-Virus-Checked: Checked by ClamAV on apache.org Morning all, This is a slightly noob-ish question that reflects my lack of experience with Java web apps in general. I have some objects for database access and business logic which I want to create on deploying my service WAR. I want these to hang around within the CXF servlet so they can by called on by my service implementation classes. Where do I put the code to initialize them? And how do I call them from my services? A pointer to a relevant example would be ideal, unless it's just a two-line answer. Thanks in advance, Andrew. (PS... The objects in question use Guice for dependency injection, if anyone has any extra tips about linking CXF to Guice then fire away, otherwise I'm sure I can figure that part out from a general example.)