AnsweredAssumed Answered

Javascript Calculator: Does Introscope stop a JavaScript if the execution time is too long or longer than the defined frequency

Question asked by MatthiasNovaTec on Nov 27, 2014
Latest reply on Dec 8, 2014 by MatthiasNovaTec

Hello guys,


at one of our customers we will use a JavaScript Calculator in the near future. The Calculator is executed every 15 seconds and we assume that the processing will always be less than 2 - 3 seconds. Nevertheless, the customer and I would like to know how Introscope behaves if the Calculator needs more time. That's why I included a small hack in the script that simulates a longer execution time. I assumed that Introscope will log something if the script needs longer than the frequency, here 15 seconds. However, even if I delay the execution by 2 minutes Introscope does not stop the script from running. There is nothing written in the log. Maybe it takes quite some iterations. I will run it the next days on a test instance to see if Introscope stops executing the script.


The Calculator writes some metric back to Introscope. It looks like that Introscope just uses the provided metric value for all passed script iterations, meaning if value 10 is returned after 2 minutes execution time, I can see the value 10 for that metric for start, start + 15s, start + 30s, ... end of script (~2 minutes). Quite interesting this behaviour.


Does anyone know how Introscope deals with long lasting JavaScript Calculators? Yet, I could find something in the forum or documentation.


Thanks for your responses.