Return-Path: Delivered-To: apmail-cayenne-dev-archive@www.apache.org Received: (qmail 75850 invoked from network); 2 Nov 2009 03:24:32 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 2 Nov 2009 03:24:32 -0000 Received: (qmail 68432 invoked by uid 500); 2 Nov 2009 03:24:32 -0000 Delivered-To: apmail-cayenne-dev-archive@cayenne.apache.org Received: (qmail 68359 invoked by uid 500); 2 Nov 2009 03:24:31 -0000 Mailing-List: contact dev-help@cayenne.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cayenne.apache.org Delivered-To: mailing list dev@cayenne.apache.org Received: (qmail 68345 invoked by uid 99); 2 Nov 2009 03:24:30 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 02 Nov 2009 03:24:30 +0000 X-ASF-Spam-Status: No, hits=-2.6 required=5.0 tests=AWL,BAYES_00,HTML_MESSAGE X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of razumovsky.andrey@gmail.com designates 209.85.219.205 as permitted sender) Received: from [209.85.219.205] (HELO mail-ew0-f205.google.com) (209.85.219.205) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 02 Nov 2009 03:24:27 +0000 Received: by ewy1 with SMTP id 1so4200548ewy.27 for ; Sun, 01 Nov 2009 19:24:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :from:date:message-id:subject:to:content-type; bh=GOmvinI1EnG3BuLl0s5WdI8GHnFihFC8Ox6J5L7gnaA=; b=clNUJSqb0YUn0Qk465dyzpQl8Puge0PSM/4FHvk9rZYIbHoDS+kw0sybZPSH9TROCX G1GH35GZtDsUogUQIOQqg8EZq1u9LlnX72DlXF60jN62ugtQPvB4VmukfE+bZeFVrNdd OhT8Mfsx/wsiDq4C4/PDxhYy/xF9wDBgRdQvk= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type; b=SalkBGTVretVsNR1Dq1+HnDY3Xe8o/kl1bpzQdUc7MvnzgitEWQ72Vrkp7YNfrfEZV lFa4/Wn7OWCFQ10qeHSl4yYYesqXpMBj14riGbGxMT2JWV0omfKuEbZK/vurO/yQZmxf 6sSzImGx/Z8RbOlJTuCuzryTQGEQUO+F0SKIU= MIME-Version: 1.0 Received: by 10.216.87.14 with SMTP id x14mr3685198wee.127.1257132246184; Sun, 01 Nov 2009 19:24:06 -0800 (PST) In-Reply-To: References: <7F1B4BC1-2051-4D63-85D3-F23A5DE2E6B1@gmail.com> <1591BBE9-3942-4260-B139-C8687CDAF4EA@objectstyle.org> <3219fff70910300157v10e8ee7q828788a6e5c33e25@mail.gmail.com> <3219fff70910300252x25305165y9f9db3b97da36a4a@mail.gmail.com> <3219fff70910300318m3434b9aub8c5ac3f05ceba2f@mail.gmail.com> From: Andrey Razumovsky Date: Mon, 2 Nov 2009 09:23:46 +0600 Message-ID: <3219fff70911011923u79082be2if71bb15ec36b50e@mail.gmail.com> Subject: Re: Making sense of callbacks To: dev@cayenne.apache.org Content-Type: multipart/alternative; boundary=0016e6d7dff8f8327104775ae884 --0016e6d7dff8f8327104775ae884 Content-Type: text/plain; charset=ISO-8859-1 So you've not configured callbacks in model - have you added callbacks through LifecycleCallbackRegistry or something? Could you give a snippet? Could you ensure that both prePersist and postAdd callbacks are invoked (e.g. add a breakpoint there). My test above shows it must be so. 2009/11/2 Lachlan Deck > On 01/11/2009, at 10:24 PM, Andrus Adamchik wrote: > > >> On Oct 30, 2009, at 11:21 PM, Lachlan Deck wrote: >> >> I refactored these (after the jar update) to postAdd (when noticing that >>> it wasn't working anymore .. and checked the mail archives for what Andrus >>> had committed) ... and found that things weren't working either way until I >>> rolled back the jar update. >>> >> >> Actually no refactoring should is needed. Just open the model in the new >> CayenneModeler and agree to perform an upgrade. It will remap (in the XML) >> the existing Java method names to the right callbacks. Or do you configure >> callbacks in the code, not the model? >> > > Yeah - we've not configured any callbacks in the Model. Just accept the > default behaviour... so our code obviously needed adjusting prePersist() -> > postAdd(). > > with regards, > -- > > Lachlan Deck > > > > -- Andrey --0016e6d7dff8f8327104775ae884--