Please help on performing periodical tasks

Hi all,
we are developing a system in which we store incoming requests in database and the performs commands they carry with themself.
after performing a command then the response will be stored in database as well.
we have three schedulers that every often looks for incoming messages and process and then send the responses.
the problem is that some commands are periodical, in other words, they will run say, every 2 days, or at a specific time. currently, each time, we explore the database table in which incoming messages are stored and if a record has reached the time to be executed we load it and execute that task.
but this seems very messy and not a good solution. I was thinking that each time I run a task store the next time that this task should be executed but don't know how to understand whether this time is that time? because, there is a possibility to down the server for a while and after starting we want to perform the tasks that missed in this period.
I would appreciate any comment if you had such experience in this matter
thank you very much

Each task has an entry that specifies the next time it runs.
When the system comes up you check for expired (past) times and run any that need to be.
You might want to consider that some tasks don't actually need to be caught up. For instance if you clear out old log entries once a day you probably don't need to play catch up on a restart because the next scheduled clean up will do the same thing anyways. Skipping taks like that requires implementating another flag in the task table though.
Rather than polling you can create a scheduled timer where the timer fires on the next available task to be completed. Myself I don't really consider this useful because it takes a lot of work dealing with situations like adding new tasks, firing too often, etc. Conversely just polling every, for example, 5 minutes has very little impact on a system.

Similar Messages

  • Please help. Performance tips and tricks on Camera RAW 6.6 needed.

    Hello I really need your help and I want to thank you in advance for your time!! I need performance tips and tricks for Camera raw 6.6 and Bridge CS5? I have Intel i7 920, with 16GB of RAM which I thought is powerful enough to make developing in Camera RAW smooth as butter but I am not getting that performance. When I slide the settings, it has a delay for the preview and it gets worse if I apply a vignette. I usually open the camera raw file to photoshop and sometimes it does take a considerable amount of time to load. Working on photoshop is great, quick as expected, but Camera RAW makes me cringe.
    What tips and tricks would you suggest for performance boost? The best case scenario is to have the preview reflects the changes of the slider without delay. Is this possible?
    Thank you very much.

    Thank you for your help.
    I found an adobe link on how to optimize lightroom and followed some tips there that are applicable to bridge. The notable setting I tweaked was to change my cache directory to my RAID 0 drive, and increased cached size to the maximum setting. The difference is night and day, and I am extremely  happy now. The only thing that still bugs me a little is that there is still a slight delay cropping when the vignette is not set to 0 . I can understand that's a little extreme though and I usually add the vignette at the end anyways.
    Yammer P:
    After making the tweaks, I was able to slide the settings with instant previews even with Noise Reduction (luminance) set to zero.
    Robert Shomier:
    Thank you for the link, I have seen that before and followed the directions. I upgraded to 16GB of RAM two weeks ago after reading the tips.
    Thank you guys again..

  • Please help, Discoverer Performance.

    I am having problems with report performance in Discoverer. I believe I have set up the Business Area correctly. I am having a problem when adding a drop down menu to a report in that it takes a long time. Is there anything I can do? (It takes about 5 seconds to refresh a report without any drill filters on top, and with 5 drill filters on top it takes about 4 minutes.)
    Also, I copied and pasted the sql querry into sql developer from the report, and the report took less than 5 seconds. This tells me there is something set up on the report side that is incorrect. Any suggestions?
    Thanks!

    1. This is a 10G Plus Olap situation.
    2. Yes, the dims are set up linked to the larger fact table.
    3. I have tried re-arranging the group items without anything else on the group level. If there is only one group by (on the dropdown) such as state, it is really quick (less than 2 seconds to refresh), even with the Customer Dim (with 7k + names). However, when I put more than one group by on the drill down, everything is exponentially slowed down.
    4. This definitely doesn't work.
    6. Unfortunately, the table design isnt as simple as I have defined it to be. There are probably 20 measures involved, along with about 30+ parameters. I do have Toad and SQL Developer, and can create a view for each particular group by, because that is faster, but I run into 2 problems.
    A. The data is refreshed and broken down to a weekly basis which would create an incredible runtime for the number of views I would need to write
    B. This is only one Business area in an end user layer of about 15. This problem spans across the other business areas as well.
    7. Taking the sql right out of the report, and crunching the report in developer produces timely results, regardless of what kind of group by statements are included.(although the view sql doesn't include the group by statements)
    8. One thing I really don't get: This is a work around I have figured out, but the end users probably won't want to deal with this:
    1. I set up the customer name as a parameter (so when the report is refreshed, the end user can select one or more names before refreshing reports)
    2. I put all of the other group bys/ drop downs into the report (4 of them).
    The result is the report works with lightning speed. The drawbacks are the end user can't scroll through the names as easily and it creates more steps for the end user.
    If I can get it to work efficiently by creating a parameter, why can't I have a drop down? It seems that they are pretty much the same thing?
    Thanks Russ.
    Message was edited by:
    user519817

  • Need help in Performance tuning for function...

    Hi all,
    I am using the below algorithm for calculating the Luhn Alogorithm to calculate the 15th luhn digit for an IMEI (Phone Sim Card).
    But the below function is taking about 6 min for 5 million records. I had 170 million records in a table want to calculate the luhn digit for all of them which might take up to 4-5 hours.Please help me performance tuning (better way or better logic for luhn calculation) to the below function.
    A wikipedia link is provided for the luhn algorithm below
    Create or Replace FUNCTION AddLuhnToIMEI (LuhnPrimitive VARCHAR2)
          RETURN VARCHAR2
       AS
          Index_no     NUMBER (2) := LENGTH (LuhnPrimitive);
          Multiplier   NUMBER (1) := 2;
          Total_Sum    NUMBER (4) := 0;
          Plus         NUMBER (2);
          ReturnLuhn   VARCHAR2 (25);
       BEGIN
          WHILE Index_no >= 1
          LOOP
             Plus       := Multiplier * (TO_NUMBER (SUBSTR (LuhnPrimitive, Index_no, 1)));
             Multiplier := (3 - Multiplier);
             Total_Sum  := Total_Sum + TO_NUMBER (TRUNC ( (Plus / 10))) + MOD (Plus, 10);
             Index_no   := Index_no - 1;
          END LOOP;
          ReturnLuhn := LuhnPrimitive || CASE
                                             WHEN MOD (Total_Sum, 10) = 0 THEN '0'
                                             ELSE TO_CHAR (10 - MOD (Total_Sum, 10))
                                         END;
          RETURN ReturnLuhn;
       EXCEPTION
          WHEN OTHERS
          THEN
             RETURN (LuhnPrimitive);
       END AddLuhnToIMEI;
    http://en.wikipedia.org/wiki/Luhn_algorithmAny sort of help is much appreciated....
    Thanks
    Rede

    There is a not needed to_number function in it. TRUNC will already return a number.
    Also the MOD function can be avoided at some steps. Since multiplying by 2 will never be higher then 18 you can speed up the calculation with this.
    create or replace
    FUNCTION AddLuhnToIMEI_fast (LuhnPrimitive VARCHAR2)
          RETURN VARCHAR2
       AS
          Index_no     pls_Integer;
          Multiplier   pls_Integer := 2;
          Total_Sum    pls_Integer := 0;
          Plus         pls_Integer;
          rest         pls_integer;
          ReturnLuhn   VARCHAR2 (25);
       BEGIN
          for Index_no in reverse 1..LENGTH (LuhnPrimitive) LOOP
             Plus       := Multiplier * TO_NUMBER (SUBSTR (LuhnPrimitive, Index_no, 1));
             Multiplier := 3 - Multiplier;
             if Plus < 10 then
                Total_Sum  := Total_Sum + Plus ;
             else
                Total_Sum  := Total_Sum + Plus - 9;
             end if;  
          END LOOP;
          rest := MOD (Total_Sum, 10);
          ReturnLuhn := LuhnPrimitive || CASE WHEN rest = 0 THEN '0' ELSE TO_CHAR (10 - rest) END;
          RETURN ReturnLuhn;
       END AddLuhnToIMEI_fast;
    /My tests gave an improvement for about 40%.
    The next step to try could be to use native complilation on this function. This can give an additional big boost.
    Edited by: Sven W. on Mar 9, 2011 8:11 PM

  • Apple TV 1G black screen or green and violet colors please help me

    Hi, I have an apple tv 1G and from one day to another is not black screen, the strange thing is that on another monitor "HP w2207" looks good. But I've tested Sony LED TV, LG, .... and does not work in some apple when starting out and color is violet and green and looks bad but does not exit the main menu. I've reinstalled the factory, I tried to change resolution I miss everything but nothing. I'm desperate please help me

    I also periodically have this purple/green color showing on the screen when I turn on and sometimes it happens when I turn on Directv so not an Apple TV issue.  I believe in my case it is the HDMI cable/port causing it.  But it corrects and gives normal picture if I turn off the tv and all devices and turn all on again.

  • I have unabled 5 fingure gesture now not able to perform any task,also my power button is not working,please help me in removing this gesture,using I phone 4

    I have unabled 5 fingure gesture now not able to perform any task,also my power button is not working,please help me in removing this gesture,using I phone 4

    I have unabled 5 fingure gesture now not able to perform any task,also my power button is not working,please help me in removing this gesture,using I phone 4

  • Aggregates Question (Performance) Please Help

    I have 2 Questions first one is
    <b><i>1. Its been mentioned in the Forum that we can anlyse in the workload Monitor (ST03N) i went through that and did not find any Data for anlysis rather its showing information for Load Analysis.</i></b>
    <i><b>2. Its been mentioned that we also check in RSDDSTAT table contents i checked this table but could not find data (How this table is Populated)</b></i>
    When i checked in
    <b>InfoCube Manage Screen --> Performance --> Check Statistics (Refresh Aggregate Statistics)</b>
    What are these for?
    Can we Analyse to create aggregates or not with out BW Statistics data and just checking ST03N and RSDDSTAT and RSDDAGGRDIR tables?Please Help Me
    I am using BI 7.Points will be assigned (Thanks)
    Message was edited by:
            SV S
    Message was edited by:
            SV S
    null

    Hi,
    For ST03N
    From Document
    BI Administration Cockpit and New BI Statistics Content in SAP NetWeaver 7.0
    As of SAP NetWeaver 7.0 BI, transaction ST03 is based on the Technical Content InfoProviders (unlike prior releases). Therefore, using transaction ST03 for BI Monitoring requires the Technical Content to be activated and to be populated periodically with statistics data.
    So, looks like you have to install the new statistics technical content.
    From thread /message/3461465#3461465 [original link is broken]
    Rajani Saralaya K   
    IN BI 7.0, ST03n is based on BI Statistics cubes, so unless you install these cubes and schedule the dataflow you cant see any result in there. Even the same thing is mentioned in the note 934848.
    For information about RSDDSTAT,
    see /message/3627627#3627627 [original link is broken]
    Raj.

  • Ask your question.please help itunes will not launch on my computer the icon on desktop has changed to a white folder no error message appears and it appears but then disappears in task manager when the programme will not open quick time is working

    please help i need to fix my itunes it will not launch on my computer . no error message appears it simply will not run. the icon on desktop has changed to a white folder and it still appears in programmes in start menu but will not open. it appears in task manager but disappears when the programme will not open

    You music etc should not be affected by problems with the iTunes program, nevertheless it is always a good idea to backup your data.
    You haven't said if there was any error message when you tried to start iTunes. If  there was one please give it in full.
    Also check to see if QuickTime works, iTunes can not work without it. If QuickTime doesn't work, it has to be fixed before worrying about iTunes.
    Then restart your PC and open your Task manger and select the Processes tab.
    Try to start iTunes, does iTunes.exe appear on the processes tab? If so does it disappear again or remain although the programs does not open?

  • Lookup transformation - Performance Issue -Please help!

    Hi,
     I have a Source table with 5 million rows. I am pulling all the rows from the source table, then doing the lookup with 5 different tables one by one.
    I use Full cache as the lookup table size is very less only. I used 'Ignore Failure' option in lookup table as I need to do the left join. That means, even if there is NO match, those records also should be passed to the bottom.
     Now, the problem is it is taking a lot of time. To load 1,00,000 records, it is taking 1 hour. The how about 5 Million rows? 50 hours? Could you please help me to find out what is the  mistake i am doing here?

    Is the performance still very poor if you only add for example a row count transformation after your source?
    How many rows are there in the lookup tables? Are you only selecting the columns you need? Is the data type of the selected columns very large?
    Please mark the post as answered if it answers your question | My SSIS Blog:
    http://microsoft-ssis.blogspot.com |
    Twitter

  • I have a Mac, IPad, I phones, and 2 Windows Vista Pcs and I'm having trouble with the Windows Laptop staying connected.  I have to re-boot after and extended period of time please help

    I have a Mac, IPad, I phones, and 2 Windows Vista Pcs and I'm having trouble with the Windows Laptop staying connected.  I have to re-boot after an extended period of time please help.  Thanks!

    I have a Mac, IPad, I phones, and 2 Windows Vista Pcs and I'm having trouble with the Windows Laptop staying connected.  I have to re-boot after an extended period of time please help.  Thanks!

  • After updating my Macbook Pro retina display to os x yosemite 10.10.2, the mause and track pad locks, and do not respond especially when using the Mac for a long period, please help, how can I solve this, I do not like feel like in windows, so I paid

    after updating my Macbook Pro retina display to os x yosemite 10.10.2, the mause and track pad locks, and do not respond especially when using the Mac for a long period, please help, how can I solve this, I do not like feel like in windows, so I paid good money for this mack, I feel calm

    Hi Buterem,
    I'm sorry to hear you are having issues with your MacBook Pro since your recent Yosemite update. I also apologize, I'm a bit unclear on the exact nature of the issue you are describing. If you are having intermittent but persistent responsiveness issues with your mouse or trackpad, you may want to try using Activity Monitor to see if these incidents correspond to occupied system resources, especially system memory or CPU. You may find the following article helpful:
    How to use Activity Monitor - Apple Support
    If the entire system hangs or locks up (for example, if the system clock freezes and stops counting up), you may also be experiencing some variety of Kernel Panic. If that is the case, you may also find this article useful:
    OS X: When your computer spontaneously restarts or displays "Your computer restarted because of a problem." - Apple Support
    Regards,
    - Brenden

  • My iphone is at tech service and since it is in guarantee period most probably they will give a new one.Thats why I want to deactivate or sign out my apple ID from that Iphone. Please help me, what shoud I do?

    My iphone is at tech service and since it is in guarantee period most probably they will give a new one.Thats why I want to deactivate or sign out my apple ID from that Iphone. Please help me, what shoud I do?

    Wow... you seriously over paid for an iPhone.
    That probably explains why you have/had no clue you were purchasing a locked device and think it's an Apple problem to get it unlocked.

  • How to improve the performance of the attached query, Please help

    Hi,
    How to improve performance of the below query, Please help. also attached explain plan -
    SELECT Camp.Id,
    rCam.AccountKey,
    Camp.Id,
    CamBilling.Cpm,
    CamBilling.Cpc,
    CamBilling.FlatRate,
    Camp.CampaignKey,
    Camp.AccountKey,
    CamBilling.billoncontractedamount,
    (SUM(rCam.Impressions) * 0.001 + SUM(rCam.Clickthrus)) AS GR,
    rCam.AccountKey as AccountKey
    FROM Campaign Camp, rCamSit rCam, CamBilling, Site xSite
    WHERE Camp.AccountKey = rCam.AccountKey
    AND Camp.AvCampaignKey = rCam.AvCampaignKey
    AND Camp.AccountKey = CamBilling.AccountKey
    AND Camp.CampaignKey = CamBilling.CampaignKey
    AND rCam.AccountKey = xSite.AccountKey
    AND rCam.AvSiteKey = xSite.AvSiteKey
    AND rCam.RmWhen BETWEEN to_date('01-01-2009', 'DD-MM-YYYY') and
    to_date('01-01-2011', 'DD-MM-YYYY')
    GROUP By rCam.AccountKey,
    Camp.Id,
    CamBilling.Cpm,
    CamBilling.Cpc,
    CamBilling.FlatRate,
    Camp.CampaignKey,
    Camp.AccountKey,
    CamBilling.billoncontractedamount
    Explain Plan :-
    Description                    Object_owner          Object_name     Cost     Cardinality     Bytes     
    SELECT STATEMENT, GOAL = ALL_ROWS                              14     1     13
    SORT AGGREGATE                                                  1     13
    VIEW                         GEMINI_REPORTING               14     1     13
    HASH GROUP BY                                        14     1     103
    NESTED LOOPS                                        13     1     103
    HASH JOIN                                             12     1     85
    TABLE ACCESS BY INDEX ROWID     GEMINI_REPORTING     RCAMSIT          2     4     100
    NESTED LOOPS                                        9     5     325
    HASH JOIN                                        7     1     40
    SORT UNIQUE                                        2     1     18
    TABLE ACCESS BY INDEX ROWID     GEMINI_PRIMARY          SITE          2     1     18
    INDEX RANGE SCAN          GEMINI_PRIMARY          SITE_I0          1     1     
    TABLE ACCESS FULL          GEMINI_PRIMARY          SITE          3     27     594
    INDEX RANGE SCAN          GEMINI_REPORTING     RCAMSIT_I     1     1     5     
    TABLE ACCESS FULL     GEMINI_PRIMARY     CAMPAIGN                    3     127     2540
    TABLE ACCESS BY INDEX ROWID     GEMINI_PRIMARY          CAMBILLING     1     1     18
    INDEX UNIQUE SCAN     GEMINI_PRIMARY     CAMBILLING_U1                    0     1

    Hello,
    This has really nothing to do with the Oracle Forms product.
    Please, send the SQL or/and PL/SQL questions in the corresponding forums.
    Francois

  • Please help for using perform in SAP script

    As subject.
    My sap script code as below:
    /: PERFORM GET_CHAMT_DATE IN PROGRAM ZRAP004
    /:USING    &SPELL-WORD&
    /:CHANGING &SPELL-WORD&
    /:ENDPERFORM
    My program ZRAP004 code as below:
    FORM get_chamt_date USING u_iword TYPE spell-word
                       CHANGING u_oword TYPE spell-word.
    CONCATENATE u_iword '&#20803;&#25972;'(t01) INTO u_oword.
    endform.
    This form is for check printing.
    It's by standard function 'F110' to excute check printing.
    But when i finished this transaction. System return error message as below:
    <b>This routine contains 2 formal parameters, but the current call
    contains 4 actual parameters.</b>
    Please help. Thanks a lot!!

    Hiii
    PERFORM CDE_CENT IN PROGRAM ZKRPMM_PERFORM_Z1MEDRUCK
    /:USING &EKKO-EBELN&
    /:CHANGING &CDECENT&
    /:ENDPERFORM
    The report :
    REPORT zkrpmm_perform_z1medruck .
    DATA : BEGIN OF it_input_table OCCURS 10.
           INCLUDE STRUCTURE itcsy.
    DATA : END OF it_input_table.
    déclaration de la table output_table contenant les
    variables exportées
    DATA : BEGIN OF it_output_table OCCURS 0.
           INCLUDE STRUCTURE itcsy.
    DATA : END OF it_output_table.
    DATA : w_ebeln LIKE ekko-ebeln,
          w_vbeln LIKE vbak-vbeln,
          w_zcdffa LIKE vbak-zcdffa.
    FORM CDE_CENT
    FORM cde_cent TABLES input output.
    it_input_table[] = input[].
    it_output_table[] = output[].
    READ TABLE it_input_table INDEX 1.
    MOVE it_input_table-value TO w_ebeln.
    CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
          EXPORTING
               input  = w_ebeln
          IMPORTING
               output = w_ebeln.
    SELECT SINGLE zcdffa FROM ekko
    INTO w_zcdffa
    WHERE ebeln = w_ebeln.
    it_output_table-name = 'CDECENT'.
    MOVE w_zcdffa TO it_output_table-value.
    MODIFY it_output_table INDEX 1.
    output[] = it_output_table[].
    ENDFORM.

  • Itunes 7.5 does not open, but it shows up in task manager please help?

    please help its been 2 months already and i cant sync my ipod cuz itunes does not open but it shows up on task manager.
    i have tried every thing but still it does not work. i have reintall my itunes and quicktime like 20 times i've gone to older version but still does not work.
    PLZZZZZZZZZZZZ HELPPPPP. im desperate and tired of liseting to the same songs for 2 months

    Let's try to get an idea of what might be going on with some preliminary questions from b noir's "smack" for iTunes launch failures:
    Is there an error message associated with the launch failure?
    If so, what does it say and what (if any) error numbers are there?
    If there's not an error message, let's check your QuickTime (its well-being is a requirement for a functioning iTunes).
    Go to the XP Start menu > All Programs and try running QuickTime.
    Does it start?
    If not, then the same question as for iTunes - is there an error message?
    If so, what does it say and what (if any) error numbers are there?
    Do you notice any other peculiar behavior with QuickTime?

Maybe you are looking for

  • Turning off wifi-sync

    I know other people have posted questions about this topic, but nobody seems to be having the exact issue I am. Hardware is MacBook and iPhone outlined below, and iTunes version 10.6.1(7) running. My issue is as follows. My iPhone did not back up for

  • Why can't I read the Sticky Notes I put in my PDF?

    I've made PDFs before and added sticky notes, which I can go back to and read later.  But this time around, when I added sticky notes and saved the document, later on when I went back the sticky note image was there, but I couldn't access any of the

  • Adobe Output Designer in Golden Valley, MN

    Adobe Output Designer Golden Valley, MN 3-6 Months Project Must Have Skills: Adobe Output Designer forms design and modification skill.. Other similar product experience could also be considered. Desired Skills: Coding / form design changes for deskt

  • Unterschrift platzieren klappt, aber wo ist bei Adobe diese Unterschrift gespeichert

    Ich habe eine Unterschrift über "Bild verwenden" (aus z. B. C:\1) in einem Dokument platziert. Klappt. Auch bei weiteren Dokumenten. Aber: Wo ist diese Unterschrift eigentlich abgelegt? (Wenn ich sie in C:\1 lösche, kannn ich sie ja trotzdem noch für

  • Encoding movies from DVD

    Has any one got any tips on Encoding DVD to MP4 format for the ATV? So far all my efforts have result in movies with big Black bolder around the outside. Sorry Mac Guys but I use Window XP