You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by Jacopo Cappellato <ja...@hotwaxmedia.com> on 2013/11/04 11:48:38 UTC

About the recent upgrade to the latest Groovy release

Hi all,

recently (in rev. 1537086 for trunk and rev. 1537092 for 13.07) I have upgraded the Groovy jar bundled in OFBiz from 1.8.6 to the latest release 2.1.9.
I would like to highlight a specific enhancement included in this release, that was actually the main reason I did the upgrade, because it may improve the performance of OFBiz instances exposed to medium/high load.

At HotWax Media we regularly develop and run a series of load tests on OFBiz instances, and we have some procedures to analyze the OFBiz performance under various conditions and loads; when we spot bottlenecks, bugs or just parts of the system that can be improved we enhance the system.
Some time ago a group of our load tests indicated that after a few hours of medium/heavy load, the system's response time started to increase and the system started to become unresponsive; I did some research and realized that the problem was not in OFBiz code but instead was in the code bundled in the Groovy distribution that OFBiz was using; I got the source code from the Groovy site, analyzed it and discovered that the issue was due to a sub optimal implementation of thread safety in one of the Groovy classes (ClassLoaderForClassArtifacts): for anyone interested, the details are described in the ticket I have submitted to the Groovy community:
 
http://jira.codehaus.org/browse/GROOVY-6364

The problem was not actually limited to the 1.8 Groovy branch that OFBiz was using: it was present in all groovy branches including the trunk.
I have then implemented a solution for the same (where I have refactored the implementation of thread safety in the class) and submitted a git pull request to see the changes included in the releases:

https://github.com/groovy/groovy-core/pull/256

The contribution has been well accepted and was made available since Groovy 2.1.8, as you can see from the release notes:

http://jira.codehaus.org/secure/ReleaseNote.jspa?projectId=10242&version=19570

If you are running an OFBiz instance that may be exposed to medium/high load I would recommend that you upgrade to a Groovy release greater or equal to 2.1.8; or, if you are running Groovy 1.8.* and you want to stick to that release branch, just wait for the bug fix release 1.8.10 that will be the first that include the aforementioned fix (however I don't know when it will be released, you will have to ask to the Groovy community); alternatively, you can get the source code and backport my fix (see https://github.com/groovy/groovy-core/pull/256), it should be rather easy to do this.

I hope it helps,

Jacopo


Re: About the recent upgrade to the latest Groovy release

Posted by Jacques Le Roux <ja...@les7arts.com>.
Thumb up indeed, thanks Jacopo and the HWM team for this effort and shared info.

It's great to know that somewhere load tests are rountinely run and monitored!

Jacques

Adrian Crum wrote:
> Jacopo,
> 
> Congrats on the fix and thank you for the update.
> 
> Adrian Crum
> Sandglass Software
> www.sandglass-software.com
> 
> On 11/4/2013 2:48 AM, Jacopo Cappellato wrote:
>> Hi all,
>> 
>> recently (in rev. 1537086 for trunk and rev. 1537092 for 13.07) I have upgraded the Groovy jar bundled in OFBiz from 1.8.6 to
>> the latest release 2.1.9. 
>> I would like to highlight a specific enhancement included in this release, that was actually the main reason I did the upgrade,
>> because it may improve the performance of OFBiz instances exposed to medium/high load. 
>> 
>> At HotWax Media we regularly develop and run a series of load tests on OFBiz instances, and we have some procedures to analyze
>> the OFBiz performance under various conditions and loads; when we spot bottlenecks, bugs or just parts of the system that can be
>> improved we enhance the system.  
>> Some time ago a group of our load tests indicated that after a few hours of medium/heavy load, the system's response time
>> started to increase and the system started to become unresponsive; I did some research and realized that the problem was not in
>> OFBiz code but instead was in the code bundled in the Groovy distribution that OFBiz was using; I got the source code from the
>> Groovy site, analyzed it and discovered that the issue was due to a sub optimal implementation of thread safety in one of the
>> Groovy classes (ClassLoaderForClassArtifacts): for anyone interested, the details are described in the ticket I have submitted
>> to the Groovy community:     
>> 
>> http://jira.codehaus.org/browse/GROOVY-6364
>> 
>> The problem was not actually limited to the 1.8 Groovy branch that OFBiz was using: it was present in all groovy branches
>> including the trunk. 
>> I have then implemented a solution for the same (where I have refactored the implementation of thread safety in the class) and
>> submitted a git pull request to see the changes included in the releases: 
>> 
>> https://github.com/groovy/groovy-core/pull/256
>> 
>> The contribution has been well accepted and was made available since Groovy 2.1.8, as you can see from the release notes:
>> 
>> http://jira.codehaus.org/secure/ReleaseNote.jspa?projectId=10242&version=19570
>> 
>> If you are running an OFBiz instance that may be exposed to medium/high load I would recommend that you upgrade to a Groovy
>> release greater or equal to 2.1.8; or, if you are running Groovy 1.8.* and you want to stick to that release branch, just wait
>> for the bug fix release 1.8.10 that will be the first that include the aforementioned fix (however I don't know when it will be
>> released, you will have to ask to the Groovy community); alternatively, you can get the source code and backport my fix (see
>> https://github.com/groovy/groovy-core/pull/256), it should be rather easy to do this.    
>> 
>> I hope it helps,
>> 
>> Jacopo

Re: About the recent upgrade to the latest Groovy release

Posted by Adrian Crum <ad...@sandglass-software.com>.
Jacopo,

Congrats on the fix and thank you for the update.

Adrian Crum
Sandglass Software
www.sandglass-software.com

On 11/4/2013 2:48 AM, Jacopo Cappellato wrote:
> Hi all,
>
> recently (in rev. 1537086 for trunk and rev. 1537092 for 13.07) I have upgraded the Groovy jar bundled in OFBiz from 1.8.6 to the latest release 2.1.9.
> I would like to highlight a specific enhancement included in this release, that was actually the main reason I did the upgrade, because it may improve the performance of OFBiz instances exposed to medium/high load.
>
> At HotWax Media we regularly develop and run a series of load tests on OFBiz instances, and we have some procedures to analyze the OFBiz performance under various conditions and loads; when we spot bottlenecks, bugs or just parts of the system that can be improved we enhance the system.
> Some time ago a group of our load tests indicated that after a few hours of medium/heavy load, the system's response time started to increase and the system started to become unresponsive; I did some research and realized that the problem was not in OFBiz code but instead was in the code bundled in the Groovy distribution that OFBiz was using; I got the source code from the Groovy site, analyzed it and discovered that the issue was due to a sub optimal implementation of thread safety in one of the Groovy classes (ClassLoaderForClassArtifacts): for anyone interested, the details are described in the ticket I have submitted to the Groovy community:
>
> http://jira.codehaus.org/browse/GROOVY-6364
>
> The problem was not actually limited to the 1.8 Groovy branch that OFBiz was using: it was present in all groovy branches including the trunk.
> I have then implemented a solution for the same (where I have refactored the implementation of thread safety in the class) and submitted a git pull request to see the changes included in the releases:
>
> https://github.com/groovy/groovy-core/pull/256
>
> The contribution has been well accepted and was made available since Groovy 2.1.8, as you can see from the release notes:
>
> http://jira.codehaus.org/secure/ReleaseNote.jspa?projectId=10242&version=19570
>
> If you are running an OFBiz instance that may be exposed to medium/high load I would recommend that you upgrade to a Groovy release greater or equal to 2.1.8; or, if you are running Groovy 1.8.* and you want to stick to that release branch, just wait for the bug fix release 1.8.10 that will be the first that include the aforementioned fix (however I don't know when it will be released, you will have to ask to the Groovy community); alternatively, you can get the source code and backport my fix (see https://github.com/groovy/groovy-core/pull/256), it should be rather easy to do this.
>
> I hope it helps,
>
> Jacopo
>

Re: About the recent upgrade to the latest Groovy release

Posted by Hans Bakker <ma...@antwebsystems.com>.
Thank you Jacopo for this important addition.

Regards,
Hans

On 11/04/2013 05:48 PM, Jacopo Cappellato wrote:
> Hi all,
>
> recently (in rev. 1537086 for trunk and rev. 1537092 for 13.07) I have upgraded the Groovy jar bundled in OFBiz from 1.8.6 to the latest release 2.1.9.
> I would like to highlight a specific enhancement included in this release, that was actually the main reason I did the upgrade, because it may improve the performance of OFBiz instances exposed to medium/high load.
>
> At HotWax Media we regularly develop and run a series of load tests on OFBiz instances, and we have some procedures to analyze the OFBiz performance under various conditions and loads; when we spot bottlenecks, bugs or just parts of the system that can be improved we enhance the system.
> Some time ago a group of our load tests indicated that after a few hours of medium/heavy load, the system's response time started to increase and the system started to become unresponsive; I did some research and realized that the problem was not in OFBiz code but instead was in the code bundled in the Groovy distribution that OFBiz was using; I got the source code from the Groovy site, analyzed it and discovered that the issue was due to a sub optimal implementation of thread safety in one of the Groovy classes (ClassLoaderForClassArtifacts): for anyone interested, the details are described in the ticket I have submitted to the Groovy community:
>   
> http://jira.codehaus.org/browse/GROOVY-6364
>
> The problem was not actually limited to the 1.8 Groovy branch that OFBiz was using: it was present in all groovy branches including the trunk.
> I have then implemented a solution for the same (where I have refactored the implementation of thread safety in the class) and submitted a git pull request to see the changes included in the releases:
>
> https://github.com/groovy/groovy-core/pull/256
>
> The contribution has been well accepted and was made available since Groovy 2.1.8, as you can see from the release notes:
>
> http://jira.codehaus.org/secure/ReleaseNote.jspa?projectId=10242&version=19570
>
> If you are running an OFBiz instance that may be exposed to medium/high load I would recommend that you upgrade to a Groovy release greater or equal to 2.1.8; or, if you are running Groovy 1.8.* and you want to stick to that release branch, just wait for the bug fix release 1.8.10 that will be the first that include the aforementioned fix (however I don't know when it will be released, you will have to ask to the Groovy community); alternatively, you can get the source code and backport my fix (see https://github.com/groovy/groovy-core/pull/256), it should be rather easy to do this.
>
> I hope it helps,
>
> Jacopo
>