Cairngorm event execute() called 2 times

Hi folks,
This is driving me nuts. Please help.
My unit test program has this:
quote:
CairngormEventDispatcher.getInstance().addEventListener(Time2doControl.EVENT_CONTACTSAVES UCCESS,
testContact2);
CairngormEventDispatcher.getInstance().dispatchEvent(new
ContactSaveEvent());
Inside my
ContactSaveEvent, I have:
quote:
trace("ContactSave Event");
super( Time2doControl.EVENT_CONTACTSAVE,false,true );
(note -- have tried with simply super(
Time2doControl.EVENT_CONTACTSAVE); -- no diff)
Then, inside my
ContactSaveCommand, I have:
quote:
trace("Executing ContactSave Command");
CairngormEventDispatcher.getInstance().dispatchEvent(new
CairngormEvent(Time2doControl.EVENT_CONTACTSAVESUCCESS));
Inside the
execute() function of the command, I have this trace:
quote:
trace("Firing ContactSave execute");
Here's what I'm getting in the trace:
quote:
Saving Contact
ContactSave Event
Executing ContactSave Command
Firing Save Contact execute
Executing ContactSave Command
Firing Save Contact execute
Am I missing something basic?
(note: I've trimmed out a bunch of stuff to make this
readable -- that could be the problem)
TIA
Mike

You cannot have the getter methods only called once. They will be called as needed in the appropriate phases.
What you need to do is to move the database access to the model layer and only make the database calls from the backing beans when required.

Similar Messages

  • BKPF- CREATED event executing 3 times (we are expecting just once)

    We have created a custom event to trigger on BKPF->CREATE. We are noticing that the simple act of updating the payment block on the invoice header is causing this event to be triggered three times. We can see this in the Event Trace in transaction SWEL. There are three identical entries that execute at the same time stamp.
    Can anyone help me understand where I should be looking to figure out why this event is being tripped multiple times when it should only be happening one time?
    Kind Regards,
    Andy

    We have created a custom event to trigger on BKPF->CREATE. We are noticing that the simple act of updating the payment block on the invoice header is causing this event to be triggered three times. We can see this in the Event Trace in transaction SWEL. There are three identical entries that execute at the same time stamp.
    Can anyone help me understand where I should be looking to figure out why this event is being tripped multiple times when it should only be happening one time?
    Kind Regards,
    Andy

  • Server side function not get called after dispatching cairngorm event second time on same page

    Hi All,
    I am facing a urgent issue regarding cairngorm event. Actually my page contain 3 button add,delete,save
    and  clicking of any button I do the respected functionality. For ex:
    I click the add button & on clicking of add button I fire a cairngorm evnt & after getting response from server side that the record is added
    I displayed a message that the record is added & update the data source.
    After addition of the record , with out going to other page if I perform the same functionaly(Like adding another record) on same page the cairngorm
    event not call the server side function  -  after debugging I find out that cairngorm event  reach to the corresponding excutecommand function & called that function  but it is not calling my server side function & I also din't get any error message .
    I dont know why  the server side function not get called?. similarly if I try for delete or update case the same things happend. Only for the first time it works properly but not for the second  time.
    Could any of  you please tell me why the cairngorm event not calling the server side function.
    Thank you for your kind assistance.
    Regards,
    Ujjwal

    Okay, well I think I've worked out the problem.
    In ASP.NET we would typically bind repeating controls such as DataLists and Repeaters manually using <i>Control</i>.DataBind(), because we're usually using a separate class library containing collections for our objects. Seems the SAP Table control doesn't like this approach.
    I changed the code so that the databinding is specified on the control, and call the Page's DataBind() method and it all worked fine.
    One tip: because the collection I used to bind to is in a separate class library, I receieved a <i>BC306523: Reference required to assembly MyAssemblyName...</i> message, even though I had a reference to the assembly in my project and the DLL is being properly deployed. To fix this, you must include the following directive at the top of the component's ASCX file:
    <%@ Assembly Name="AssemblyName" %>

  • "3.x Analyzer Server" EVENT taking more Time when Executing Query

    Hi All,
    When I am Executing the Query Through RSRT   taking more time. When I have checked the statistics
    and observed that "3.x Analyzer Server" EVENT taking more Time .
    What I have to do , How I will reduce this 3.x Analyzer Server EVENT time.
    Please Suggest me.
    Thanks,
    Kiran Manyam

    Hello,
    Chk this on query performance:
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/ce7fb368-0601-0010-64ba-fadc985a1f94
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/4c0ab590-0201-0010-bd9a-8332d8b4f09c
    Query Performance
    Reg,
    Dhanya

  • Event Executing Itself Multiple Times

    Hello Experts,
    I have created a validation in the Sales Order Form for checking the Item Gross Profit greater than 0 .
    When user press tab from the UnitPrice column this checking is done but system is executing the event multiple time
    rather than once .It makes the checking very slow each time this check occurs event occur mulitple times.
    Please suggest what to do .
    Thanks & Regards,
    Amit

    Hi,
    Please ensure that u r given necessary conditions before doing validation
    1. pval.BeforeAction = False
    2.Pval.ColumUID = "UrId"
    3.Pval.ItemUId = "UrMatId"
    4.pVal.InnerEvent
    By
    Firos C

  • ALV events for data_change  executing multiple times

    Hello Experts,
    I am using the event "data_changed" of cl_gui_alv_grid and its getting triggred multiple times based on
    no. of rows in my ALV grid output.
    For ex: if i have 5 rows and if i input a field in any cell in a new row, in data_changed event is triggered 2 times.
    The  LOOP AT er_data_changed->mt_mod_cells INTO ls_modified is executing 6 times as in above example
    even though is having only 1 entry.
    Can some one pls help me with this?
    Also i see the  toolbar event is often getting excuted multiples no of times making the application slow.
    Please suggest.
    Thanks
    Dan

    Dan,
    Maybe you've placed or doing something wrong, take this report as a pattern "BCALV_EDIT_03".
    Best regards,
    Alexandre

  • Cairngorm events dispatch problem

    Hi,
    We are developing a Flex 3 AIR application on Cairngorm and
    LCDS 2.6. The problem is some Cairngorm events don't get fired
    which results in null reference errors. But when we put an Alert is
    starts working. Can you suggest any solution and reason why its
    happening.
    Thanks,
    Oleg

    One thing that will cause events to appear not to fire is
    when you forget to instantiate your controller somewhere on your
    mxml file. The events will dispatch, but the command won't get
    executed.
    Another one - if you create custom events and override the
    constructor, you have to to call super(MyController.EVENT_TYPE) or
    else your event doesn't get bound to the command.

  • GetNext() of Disassemble Stage is executing two time

    why GetNext() of Disassemble Stage is executing two times ?I checked it in event log.
    Prakash

    GetNext method returns all the messages created out of Disassemple method.
    Returned message it passed to next pipeline stage or message box as configured. GetNext method is called repeatedly as long as it returns some IBaseMessage type. Repeated calls stop only when
    GetNext returns null.
    So, the second call is when the
    GetNext returns null for you.
    If this answers your question please mark it accordingly. If this post is helpful, please vote as helpful by clicking the upward arrow mark next to my reply.

  • Found iCal events in Time Machine.  Now Lion only allowing me to import one event at a time.

    Upgrade my macbook pro over the weekend to Snow Leopard and then Lion.   I lost all my the majority of my iCal events.   Went to Apple store and they said that was rare and not sure how to restore my last back up from Time Machine on an external drive.   I've been spending hours trying to go through a bunch of threads on different MAC formums.  
    So I finally found my iCal events in Time Machine.   When I try to import these events, I am only allowed to highlight/import one event at a time.   This will take me forever to import years of missing data.   I basically have been using my iCal to journal for my 3 small daughters - first tooth, hair cut, etc.   So I am desperate to get these events back so I can get them printed and SAFE.
    Does anyone have any suggestions on how to import my ics files?   The Apple Store Genius had me tryng to import the corestorage.ics files.   2 or 3 of those files showed they were trying to be imported for over 4 hours.   I finally Forced Quit iCal.   I've tried this several times and same result. 
    The corestorage files were under user/library/application support/ical/sources
    I now located the calendar events user/library/calendars/ then a bunch of coded files leading to the events.  These events appear to be the ones I am looking for as I can read some of the files.   I have several years I want to import back into my working iCal.  
    Please help if you know how!!!
    Thank you,
    Very Upset Mama of 3 little girls

    Thomas - You are awesome - THANK YOU!  
    I did exactly what you said (CAN"T believe an Apple Genius did not know this) and I think all of my events got restored.  
    However, it duplicated all of the calendars - I have 6 (one for each family member plus an extra called home that we all have to do).   Not sure if I did something wrong, but do you have any ideas?  
    Also, the time setting must be wrong b/c I have events from 2008 showing up in 2012 - same day and time as the old sessoin - just out dated.    Do I need to manually change all of this?   Should I delete the Calendars folder again and try again?  
    Also, I read some where about deleting a iCal cache file.   Do I need to do this?
    I TRULY appreciate you taking the time to help people in this forum.   I have spent hours the past two days trying to figure this out.   Plus, now I need to figure out about upgrading my Office for Mac b/c I didn't realize I lost Office 2004 when upgrading to Lion.   
    Thank you for your time and support!
    Lori

  • Action is executing multiple times

    Hi Experts,
    I am using an action for a service transaction in which a method is called APPROVE_RFC_VIA_WF - the method triggers a workflow, but the action runs multiple (6) times, 6 workflow items are created and 6 emails are triggered likewise.
    I restricted the action to only one executable/successful action and it works ! Only 1 email and 1 workflow item is created, but then the workflow item is not executed !
    Please I need help on this, thnx.
    Regards.

    Another action definition was restricted to execute 5 times which was somehow effecting the workflow action definition
    Adjustments were made to both definitions so that both would give correct results.
    Regards.

  • Query performance analysis in RSRT --- event text 'Wait Time, User'  means?

    Hi All,
    I am running some queries in RSRT in 'execute + debug' mode.
    selecting 'statistics data for query' option.
    Statistics says that most of the time is taken by the event 'Wait Time, User' (event text).
    handler type is OLAP or DFLT depending on the query.
    This is taking around 90% of the query run time.
    Can any one tell me what it means ? Where is it actualy taking time?
    What does it mean by :
    Event text --> 'waiting time, User'
    Handler type DFLT
    Handler type OLAP.
    A sample record of the statistics:
    4A2Z2CFA1GLIRPIK9O2Z18GK1     4A2Z2SN22IFE3AKOL50W9DQZ5     BEX3     2     ZS233BIWDEV     11.06.2008  19:29:08          DFLT               2     1     Wait Time, User     98.467887     0     1
    Thanks in advance.
    rgds,
    Raghu.
    Edited by: Raghu tej harish reddy on Jun 11, 2008 4:19 PM

    Thank you for your immediate response.
    But i won't think it is the time taken to enter the values in the variable screen because of two reasons:
    1.There are some events starting before these events(i can say by seeing the starting time of the events)
    2.For some queries this time is around 3 minutes; and i hardly take 30 seconds to enter the variable values.
    Thanks,
    Raghu

  • Et_ITEM_PRESSED event  firing two times

    Hi ,
    I have a added a button to one of the windows and use the
    et_ITEM_PRESSED in the ItemEvent to do something. My problem is whenever I click the button the event fires two times. I thought it was my code but the sample code in the CatchingEvents project does the same.
    Does anyone know any wayaround it?
    appologise if this question has been asked before (I assumed so but could not find any matches for my search)
    Regards,
    Indika

    Almost all the item event in SBO executes two times before and after SBO events handler works. If you dont catch one of the events SBO will execute two events in one time. To avoide that you should cacth the events before "OR" after the SBO Events Handler Works.
    For Example:
    <i><b>Before Action:</b></i>
    If pVal.ItemUID = "1" And pVal.EventType = et_ITEM_PRESSED Then
    If Len(oEditText.String) <> 0 Then
    If IsNumeric(oEditText.String) Then
    If Len(oEditText.String) <> 15 Then
    If pVal.Before_Action = True Then
    BubbleEvent = False
    SBOApplication.SetStatusBarMessage "Federal ID Must be 15 Character", bmt_Short
    oTmpForm.Items("41").Click  ....
    <i><b>Action Success:</b></i>If pVal.Action_Success = True Then
    Set oItem = oTmpForm.Items("8")
    Set oEditText = oItem.Specific
    sDocNum = CLng(oEditText.String)
    Set oItem = oTmpForm.Items("29")
    Set oEditText = oItem.Specific
    sJumlah = oEditText.String
    If sJumlah = "" Then
    BubbleEvent = False
    That's all. Hopefully helps.
    Cheers,
    Hamdi

  • Web Service executing multiple times

    We are noticing an ongoing problem with web services both consumed in SAP as well as web services published in SAP and consumed via .NET applications.  In both cases, we are occasionally seeing examples of a single web service method calls executing multiple times.  For example, one of our methods in our SAP generated web services inserts records into a custom Z table.  We are noticing that for a single invocation of the web service, data records are appearing multiple times in the custom table.  We have placed code inside of the function in SAP to catch these multiple executions, but the code does not recognize the duplicates because most likely, the commit from the previous execution has not yet occurred.  We have time stamped the inserts into the table and can see that they do not have the same time.  Our web services are being created in SE80.  My guess is this is some sort of caching issue.  Has anyone run into a similar problem?  We are using NetWeaver 7.0 and SAP ECC 6.0.
    Edited by: Joseph Sciacca on Sep 9, 2008 4:10 PM
    Edited by: Joseph Sciacca on Sep 9, 2008 7:34 PM

    Hi Developers,
    I have the same question, is it possible to have multiple outgoing parameters?
    When not, does SAP Netweaver knows a IN-OUT parameter? Because I found on the internet that it is possible to have a IN-OUT parameter. But that was with the BEA Weblogic 8.x.
    When not, is then the only solution to return a object? With in this object all the parameters you want.
    Or otherwise is there a other workaround?
    Thanks in advance,
    Marinus Geuze

  • '%Total Call Time ' in AWR report

    Hi.
    I have a quick question here,
    For the awr report, the ‘Top 5 Timed Events’ section, does anybody knows how the ‘%Total Call Time ‘ is calculated for each event listed there?
    Top 5 Timed Events Avg %Total
    ~~~~~~~~~~~~~~~~~~ wait Call
    Event Waits Time (s) (ms) Time Wait Class
    PX Deq Credit: send blkd 5,682,600 3,816 1 39.8 Other
    db file scattered read 91,236 1,681 18 17.5 User I/O
    CPU time 1,347 14.0
    log file sync 99,426 752 8 7.8 Commit
    log file parallel write 97,921 523 5 5.4 System I/O
    Thanks,
    Lei

    922884 wrote:
    Hi,
    Db version is 10.2.0.4.0
    What is meaning of waits and % Total Call Time in Top 5 Timed Events in AWR report? Waits is the number of times a session waited on a particular call
    % Total Call Time is the total time spent in this event divided by the db time, converted to a percentage.
    It gives you some idea of how signifcant this event was in the total time spent waiting by the user. Unfortunately the SQLNet times are excluded in the calculations, so there is a component of time that (from the end-users' perspective) is lost.
    How to read AWR report?Where i have to start from it?
    The best place to start is probably still the white paper about statspack produced by Oracle 11 years ago: http://www.oracle.com/technetwork/database/focus-areas/performance/statspack-opm4-134117.pdf
    How the values are calculated in awr? For example db time is 556.15 and elapsed time is 1,439.73 .
    elapsed time is the clock time between the start and end time of the snapshots, reportedin in minutes - in your case your report covers 24 hours which is generally far too long to be useful.
    db time is the time your sessions were active "inside" the database - again in minutes - and it's a measure of how much time you spent working. It is the sum of wait time and CPU time.
    Regards
    Jonathan Lewis

  • WDDOINIT method executes every time when returning to View

    We are making Enhancements to the Travel Expense WDA. (Package: PTRM_WEB_UI)
    When creating a New Expense Report, the WDDOINIT method is being executed only once each time the View is displayed.  This is what is expected.
    When changing an existing Expense Report, the WDDOINIT method is being executed each time the view is displayed.
    The Lifetime Property of all of the views are set to "framework controlled".  It seems like when in change mode, the lifetime property of the views is acting as if they were set to "when visible". 
    Is there some way that this property is being dynamically changed when in change mode?  Does anyone know if SAP intended the Travel Expense WDA to act this way when in change mode?
    Any help or insight regarding this issue would be helpful. 
    Thanks,
    Aaron

    It could be that there are multiple component usages and that this view belongs to an inner component. The parent component could call DELTE_COMPONENT on the component usage if no views from that componet are currently visibile.  This is done for memory manage as there is no garbage collection of compoonent instances at runtime. This would have the effect that the WDDOINIT would be called again if the component is used again/the view is reshown. I have seen complex internal applications that use separate components for each tab for instance.  When the tab switch occurs, they perform a DELTEE_COMPONENT.  This can have a significant positive impact on the memory consumption of the session. This could explain the behaviour you are seeing.

Maybe you are looking for

  • Create Title from File Name

    Is there a way to automatically transfer the file name to the title of the image? Can it be done with a script in the export cations folder? If it can, does anyone have a script?

  • Time Stamp a Voice Memo to the Second

    I need to make a voice memo that's date and time-stamped to the second. It looks like Voice Memo doesn't do this (but if there's a way to, please advise!). Does anyone know an app that would do this? The greatest thing would be to be able to make the

  • I need to re-lead the bios on aspire 3100, can't find file

    Anyone know where I can get the bios file for aspire 3100.  I reset the windows vista before selling itand now it won't boot.  disconnected hard drive and still no initial boot, want to re-load bios.  HELP! the buyer wants to pick it up soon.

  • Error in Data updation From ODS TO CUBE

    hello Experts We are working on BW 3.5 for FI GL line items we are loading the data to ODS and than to Cube. earlier there was a process chain failure 2 months back so delta were stuck for 2 months now about 10 million records have been uploaded in O

  • AR Transaction Create Accounting Error APP-AR-96282

    HI Everyone, I need some urgent help. I can't create online accounting of AR transaction because of Error: APP-AR-96282. Autoaccounting has generated distributions for invoice properly & invoice is complete. Online Create accounting & even Accounting