I created a service that takes data from our historian (IP.21) and caches into a Thingworx Data Table. The table has 761 Columns. When creating a service to populate the table -- I had approximately 850 lines of JavaScript code. Is there a maximum limit to the allowable size of a javascript service?
I keep getting error: syntax check failed:
Encountered code generation error while compiling script: Program too complex: too big jump offset at line 1 column 0 source: /null
What does the "Program too complex" error mean?
Hi Shawn, could you email me your script please?
Thanks!
The 3rd party implementation we use for script handling/validation has a 70KB script size limit. The error is awful. We'll try and wrap it and display a more informative message in a future release.
In general script > than 70KB is huge. It's best to break it up. Makes it easier to maintain and debug. Personally I try to keep to a 1000 line limit when writing javascript. Even that makes some js zealots cringe.