‎27-11-2015 09:22 AM - edited ‎27-11-2015 01:27 PM
Hi All,
We are planning to write our future Macros in Java instead of VBScript.
We have performance issues in VBScript Macros with huge business logic. Does the development of these macrs on java improves the performance?
We have :
1. Macros that run on on some events (meta commands)
2. Macros that run for 1 or 2 minutes (for ex: bulk users creation)
3. Macros that run for more than 5 to 6 hours (Website generation scripts)
Which is more preferabale language to above three types of scripts.
Some specific questions:
1. Is java convinient only for external developments outside Mega (developing external tools connecting to Mega from outside) ?
2. In which scenarios you suggest Java development?
Thanks in advance.
Venky.
Solved! Go to Solution.
‎03-12-2015 04:55 AM
Hi Wim,
Access denied to view that page 😞 .
Regards,
Venkatesh.
‎02-12-2015 10:44 AM
Hi,
Leslie Robinet has made a very usefull blog concerning macro/query performance :
Kind regards,
Wim VdV
‎01-12-2015 07:49 AM - edited ‎01-12-2015 07:53 AM
Hi Colruyt Team,
Using Java will not make a big difference in terms of performance because the VB Script and Java APIs are based on the same internal API.
Here are a few things you can look at to make your code run faster:
- most of the time using collections instead of queries to retrieve objects is faster (it can make a big difference)
- check whether you are using identifiers when accessing metattributes, links and objects
- make sure to release megaobject and megacollection objects when they are no longer in use
also the technical article "All about starting with APIs" contains a lot of information on how to use the API effectively
Best regards
Gregory
‎30-11-2015 09:31 AM
Hello
It is usually considered that
- VB script is appropriate for code with limited volume.
- Java is appropriate when code is voluminous, complex to develop and/or specific user interface is used
For voluminous and complex code, a confortable developpement environment (debugging...) is required, which excludes VB script. This is mainly a maintenance concerne because VB script runs faster than java.
Let us remind that MEGA, as a software editor, uses Java at a significant scale (more that 80 jar components)
Regarding static web site generation, do not expected to reduce the generation time by triggering the generation with another language.
However I am not a development expert. I recommend that communiy users that have a real experience share it with us.
‎27-11-2015 04:48 PM
Hi Colruyt Team, Venky ?
Generally, in MEGA and not especially in MEGA , I think the java apps are slow and unstable. Java is low it is engraved in my mind for my entire life. SAP and other main editors were very disappointed with their willing to provide a GUI based on it ... for complex calculation it is moreover impossible. That's my feedback about JAVA but very oriented.