Announcement

Collapse
No announcement yet.

Extra calls to main at first load

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Extra calls to main at first load

    Hi Jason,

    1. Can you please be so kind and respond to my other posts where I ask specific questions about EFS engine. I do not expect anybody else to know [only guess].
    Thank you.

    2. Also about EFS engine, can you please explain why, at first load [new symbol for example] there are more calls to main than the number of bars in the time template?
    There are anywhere from 2-6 extra calls.
    They occur after the chart is completelly loaded and executed and are detected as extra ticks on the last bar [even after hours].
    Even getBarState reports them as "CURRENT_BAR".

    You can try with any chart, with studies provided by eSignal [except the built-in studies, whose execution is not reported in Performance Monitor].

    Subsequent loads [using Reload of any sort] do not have the problem.

    Thank you.
    Last edited by mbuta; 10-28-2008, 12:18 AM.
    Mihai Buta

  • #2
    Re: Extra calls to main at first load

    Hello Mihai,

    Originally posted by mbuta
    Hi Jason,

    1. Can you please be so kind and respond to my other posts where I ask specific questions about EFS engine. I do not expect anybody else to know [only guess].
    Thank you.
    I apologize for the delays. Please see my other reply to you from earlier today. Regarding your other recent threads where other users have replied, it appears that they have given you correct information. There isn't anything else I can think of to add to those threads.

    2. Also about EFS engine, can you please explain why, at first load [new symbol for example] there are more calls to main than the number of bars in the time template?
    There are anywhere from 2-6 extra calls.
    They occur after the chart is completely loaded and executed and are detected as extra ticks on the last bar [even after hours].
    Even getBarState reports them as "CURRENT_BAR".

    You can try with any chart, with studies provided by eSignal [except the built-in studies, whose execution is not reported in Performance Monitor].

    Subsequent loads [using Reload of any sort] do not have the problem.

    Thank you.
    I've tested a few of the EFS 2 Custom studies and I'm not see this problem. I've added the following code to the top of main() for the tests and I'm not seeing any BARSTATE_CURRENTBAR executions. I'm testing equity symbols, which aren't trading right now. Are you sure that there wasn't some trades occurring in the chart? Was your time template set to 24-hours?


    PHP Code:
        if (getBarState() == BARSTATE_CURRENTBAR) {
            
    debugPrintln(getCurrentBarIndex() + "  BARSTATE_CURRENTBAR");
        } 
    What symbol, intervals and time template settings did you experience this with?
    Jason K.
    Project Manager
    eSignal - an Interactive Data company

    EFS KnowledgeBase
    JavaScript for EFS Video Series
    EFS Beginner Tutorial Series
    EFS Glossary
    Custom EFS Development Policy

    New User Orientation

    Comment


    • #3
      Hi Jason,

      Maybe you recall, I raised this issue before long time ago.

      I inserted an example, using three random efs files generated with the Wizard [so I have no involvement]. It is taken today, Saturday when no markets are open.
      In this example, only 1 extra call is generated, many times there 2 or more, depending on ????. I hope you can clarify it.

      I am surprised you were unable to see the problem.

      ALL your Custom and Libray studies do it. Some of them more, but justified, as they include calls to other functions.
      Basic studies never generate these extra calls.

      Re. Time Templates: I tested with all templates I found. Same result. I never use "Dynamic" time templates. All my templates have clearly defined Start/End times.

      Last piece of info: I am using V8.0 Build 872, as later versions have performance degradations I cannot live with.

      Note: The main reason I need this issue resolved is to be able to, accuratelly, determine Real Time activity [looking for extra ticks after the last bar was processed].

      I hope you will come with a resolution and solution.

      Mihai Buta

      Comment


      • #4
        Jason,

        I "digged" some more and here is additional information that should help you troubleshoot this problem.

        I added my efs to the picture, where I can detect activity on extra ticks, as follows:

        if (NEWBAR) {..}
        else {
        Draw the yellow line;
        if (1==0) {var XX=open(0,inv("1S"));}
        }

        Please note that there is one reference to "1S" sub-interval, but is is disabled.

        I show three distinct situations:
        Note: first, please note tha just by adding my efs, the number of extraticks in other studies increased [?!?!?]

        Case 1: First load, brand new symbol [never used in this session]. Note that my efs is executed 2x600+1 times. No "CURRENTBAR" detected.

        Case 2: Previously used symbol. All panes execute the same with 5 extra tick and "CURRENTBAR" is detected [see the yellow line].
        Note that EFS engine "remembers" the "1S" data series.

        Case 3: Subsequent reloads, using my buttons. There are no extraticks. Total number of calls is 600 x ReloadEfs.

        I hope this will help you guys identify the problem and come up with a solution to avoid thse extra ticks.

        a/ Why MY efs makes EFS engine generate more calls to the other panes?!?!?!?
        b/ Why the lower intervals are not treated the same as higher external intervals. I have plenty of those in my efs and no problem??!!??
        Al least I know now why the first loads are so slow.
        c/ Why is so dificult to provide a simple and efficient way to deal with busy times, for those of us who need it?
        Note: I have several good suggestions that are quite simple to implement at your level [please do not ask me to submit a suggestion, have tried, never got anywhere].

        Thank you for taking the time to provide a solution to this problem that has become very frustating [given the recent volatility].






        Mihai Buta

        Comment


        • #5
          Mihai
          I can replicate the issue when using version 8 (btw I suppose you meant build 782 and not 872) although I am not sure if it is caused by the efs engine or by how the chart is being built (which the efs engine just happens to expose).
          Regardless from what I am seeing the issue appears to have been since resolved as it does not seem to be occurring in version 10.2 build 1391
          I doubt that eSignal would be doing any further revisions of version 8 so the only solution available to you may be to install the most recent version
          Alex


          Originally posted by mbuta
          Hi Jason,

          Maybe you recall, I raised this issue before long time ago.

          I inserted an example, using three random efs files generated with the Wizard [so I have no involvement]. It is taken today, Saturday when no markets are open.
          In this example, only 1 extra call is generated, many times there 2 or more, depending on ????. I hope you can clarify it.

          I am surprised you were unable to see the problem.

          ALL your Custom and Libray studies do it. Some of them more, but justified, as they include calls to other functions.
          Basic studies never generate these extra calls.

          Re. Time Templates: I tested with all templates I found. Same result. I never use "Dynamic" time templates. All my templates have clearly defined Start/End times.

          Last piece of info: I am using V8.0 Build 872, as later versions have performance degradations I cannot live with.

          Note: The main reason I need this issue resolved is to be able to, accuratelly, determine Real Time activity [looking for extra ticks after the last bar was processed].

          I hope you will come with a resolution and solution.

          Comment


          • #6
            Alex,

            Yes, it is Build 782.
            No, there is nothing in "the way my efs is constructed" to generate this, as yhou were able to reproduce it with yours.

            I did try the V10.x. It has serious performance issues [absolutelly un-usable] so I had to roll back to v8.

            Also, I am unable to find a solution to "busy times" and, practically, I am prohibited from using symbols like: QQQQ, SPY, DIA, INTC, AAPL, CSCO, etc. etc.
            In busy times I look at the "clepsidra" for minutes [until eSignal forces on me ALL the ticks, which have no meaning 3min later anyway].

            Please note that my "aggregate execution time" [from all running charts and panes] is way under 1ms!!!!!!!!!!

            The conclusion is: the "external intervals" made available by EFS2 is nice, very nice, but only for "accademic" purposes, not to trade real money.
            Mihai Buta

            Comment


            • #7
              Mihai
              I don't believe I said that the issue was caused by "the way your efs is constructed" but rather that it could be due to the way the chart is built in version 8 [meaning by the application and not by you] and not necessarily the efs engine.
              Regardless as I indicated in my previous reply the issue appears to have been since resolved as it does not seem to occur in version 10.2
              Alex


              Originally posted by mbuta
              Alex,

              Yes, it is Build 782.
              No, there is nothing in "the way my efs is constructed" to generate this, as yhou were able to reproduce it with yours.

              I did try the V10.x. It has serious performance issues [absolutelly un-usable] so I had to roll back to v8.

              Also, I am unable to find a solution to "busy times" and, practically, I am prohibited from using symbols like: QQQQ, SPY, DIA, INTC, AAPL, CSCO, etc. etc.
              In busy times I look at the "clepsidra" for minutes [until eSignal forces on me ALL the ticks, which have no meaning 3min later anyway].

              Please note that my "aggregate execution time" [from all running charts and panes] is way under 1ms!!!!!!!!!!

              The conclusion is: the "external intervals" made available by EFS2 is nice, very nice, but only for "accademic" purposes, not to trade real money.

              Comment


              • #8
                The information that the problem was fixed in v10 is incorrect and here the proof.
                Same extra ticks [1 for price pane and 3 for the others] and the same 600 calls for the "1S" data series in each pane.
                The only diference: the execution time is a lot longer.

                I invite the eSignal specialists to respond to this issue, which is very important to me.

                Thank you.



                Mihai Buta

                Comment


                • #9
                  Mihai
                  As I explained in my previous message the issue you reported initially in this thread ie that of multiple BARSTATE_CURRENTBAR executions has been fixed.
                  As a reminder here is a quote from a previous post of yours in which you describe the issue

                  Originally posted by mbuta
                  Jason,
                  <SNIP>
                  Please note that there is one reference to "1S" sub-interval, but is is disabled.

                  I show three distinct situations:
                  Note: first, please note tha just by adding my efs, the number of extraticks in other studies increased [?!?!?]

                  Case 1: First load, brand new symbol [never used in this session]. Note that my efs is executed 2x600+1 times. No "CURRENTBAR" detected.

                  Case 2: Previously used symbol. All panes execute the same with 5 extra tick and "CURRENTBAR" is detected [see the yellow line].
                  Note that EFS engine "remembers" the "1S" data series.

                  Case 3: Subsequent reloads, using my buttons. There are no extraticks. Total number of calls is 600 x ReloadEfs.
                  <SNIP>
                  Following is an animation captured using version 8.x (build 782) using a very simple script set to detect if a BARSTATE_CURRENTBAR occurs .
                  In the animation I run through the three cases you listed (see above quote) and as you can see I can in fact replicate all three cases (reported in both the Formula Output window and in the Performance Monitor)



                  The following animation was instead captured using the same Page running in version 10.2. Even in this case I run through the three cases you listed. As you can see BARSTATE_CURRENTBAR is now no longer occurring hence my statement that the issue you reported initially has been fixed is correct.



                  Now, with regards to the additional execution you are seeing in the Performance Monitor when using version 10.2 this is unrelated to the additional BARSTATE_CURRENTBAR problem you reported initially in this thread and it is not a bug but is instead due to the requirement of the efs engine to establish the necessary dependencies as clearly explained by Dion Loy in this post
                  In the animation enclosed below I am using the same efs used in the prior animations with the only difference that I am now calling an external interval and checking for BARSTATE_ALLBARS (the latter to illustrate the point).
                  Notice that the additional execution occurs even the first time that the symbol is called however it does not occur at CURRENTBAR but at ALLBARS. As explained by Dion calling an external symbol and/or interval will cause a restart of the efs after all the dependencies have been established hence the two executions of BARSTATE_ALLBARS and the additional calls reported by the Performance Monitor.
                  To conclude the two issues being discussed here are different and while the first one was a bug which -as I have said before - has been fixed the second one is not a bug but an intrinsic part of how the efs engine works.
                  Alex




                  Originally posted by mbuta
                  The information that the problem was fixed in v10 is incorrect and here the proof.
                  Same extra ticks [1 for price pane and 3 for the others] and the same 600 calls for the "1S" data series in each pane.
                  The only diference: the execution time is a lot longer.

                  I invite the eSignal specialists to respond to this issue, which is very important to me.

                  Thank you.

                  Comment

                  Working...
                  X