Jacopo
On Feb 8, 2009, at 11:32 AM, Bruno Busco wrote:
David, many thanks for your help here. It is my first approach to EECAs and SECAs and this light in the dark really helps! ;-) -Bruno 2009/2/7 David E Jones <[email protected]>:A general rule for EECAs and SECAs that may or may not apply here (notenough info to tell):- EECAs are for maintaining derived data like a total field or a keywordindex- SECAs are for triggering business processes based on business eventsIf you use either one for the other's purpose you'll likely run intotrouble. It can work, but it's like using a hammer instead of a screw driverto put a screw into something... it's just the wrong tool. As for updating an entity in a service triggered by an EECA on thatentity... I'd be interested in hearing what you are trying to do. It's either the wrong tool, a bad data structure, or a simple lack of having a condition to see if a change happened that would require the ECA to run (orwhatever condition would distinguish the before and after states). HTH as it's a shot in the dark ;) -David On Feb 7, 2009, at 7:27 AM, Bruno Busco wrote:Yes, your solution makes sense. I have another eecas related question.I am facing a case in which in an "create-store" eeca I need to updatethe entity content itself. So an endless loop happens.Is there a way to hinibit the eeca retrigger due to an entity store inthe eeca itself? Many thanks, Bruno 2009/2/7 Nikita Shinde <[email protected]>:Hi Jacques,I wanted to track the history of changes(CUD) made to any entity and who made those changes. So I wrote a service to do that which was triggered by eecas on that entity. But in my service I could never getthecurrent logged in user who was making those changes, it always gave meadmin(because in my entity-eca.xsd its set to admin). I had a work around for this by using secas instead. Regards, Nikita. -----Original Message----- From: Jacques Le Roux [mailto:[email protected]] Sent: Thursday, February 05, 2009 5:34 AM To: [email protected] Subject: Re: Question related to eecas Hi Nikita,"run-as-user" is defaulted to "system" not admin for some times now (seeentity-eca.xsd).I think you should poke into EntityEcaAction.java around line 80 andchange their for your purpose.BTW, it's weird to use an EECA with an user different than system, whatis the purpose ? Jacques From: "Nikita Shinde" <[email protected]>Hello All,When I trigger a service on an eecas, I always get userLoginas"admin" which is correct because "run-as-user" being defaulted to "admin".But in the triggered service, I want the userLogin to be theexisting logged in user, is there a way to get that? Kind Regards, Nikita Shinde Amicon Technologies Pvt. Ltd., Mumbai, India.
smime.p7s
Description: S/MIME cryptographic signature
