(OFBIZ-9411)
As discussed on user ML (https://s.apache.org/xjFj) rename "loadAll"
the "loadDefault" Gradle task.
This moves the README.md.html file from the unique separated branch tools
I used the documentation subfolder to put the README.md.hmlt file which is then
used in the https://cwiki.apache.org/confluence/display/OFBIZ/From+Ant+to+Gradle
page. So only the trunk version is used in this page. I'll rather put the
README.md.hmlt file in the root directory (at least for now, maybe a
documentation page would fit better notably in relation with my proposition
at https://s.apache.org/mpRV where README.md.hmlt files would more used)
and create a separated version for the R11 branch
(README.md.hmlt file and wiki page)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1798859 13f79535-47bb-0310-9956-ffa450edef68
India has 29 states and 7 Union Territory. Need to update data as in data Union Territory also added as STATE,
used TERRITORY as GeoTypeId for Union Territories.
Applied patch from jira issue
- Updated geoTypeId for 7 union territory from STATE to TERRITORY
- Update geoName for Andaman And Nicobar it should be Andaman and Nicobar Islands
- Corrected geoName and gooId and other detail for Delhi union territory
- Corrected to the name for Jammu and Kashmir (And should be in lower camel case)
- Corrected name for Odisha (Orissa>> Odisha)
- Corrected geoName for Puducherry, also added wellKnownText = "Pondicherry"
- Corrected geoName for Tamil Nadu (Tamilnadu >> Tamil Nadu)
- Added data for new state Telangana
- Corrected geoName for Uttarakhand (Uttaranchal >> Uttarakhand)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1798796 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-9385)
This is an improvement only because no cases were reported. But obviously in
case of unlucky exception after the EntityListIterator creation and before it's
closed the EntityListIterator remains in memory.
It should be closed in EntityListIterator.finalize() but the less happens there
the better.
The solution is to use try-with-ressources when possible
This completes OFBIZ-9385, there are no other cases left.
There are few methods like FindServices.executeFind() or performFindParty
service which can't be improved because they return an EntityListIterator.
So methods using them must be carefully crafted to close the EntityListIterator.
Most where already documented (in the framework). I completed few in
applications at r1798495
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1798566 13f79535-47bb-0310-9956-ffa450edef68
transaction in place
(OFBIZ-9286)
While working on OFBIZ-9385 "EntityListIterator closed but not in case of
exception" I forgot that you must begin the transaction before the
try-with-resources, this fixes last cases, lesson learned the hard way!
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1798353 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-9385)
This is an improvement only because no cases were reported. But obviously in
case of unlucky exception after the EntityListIterator creation and before it's
closed the EntityListIterator remains in memory.
It should be closed in EntityListIterator.finalize() but the less happens there
the better.
The solution is to use try-with-ressources
The getProductSearchResults() method was public but only used in the class.
I made it private
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1798300 13f79535-47bb-0310-9956-ffa450edef68
As noted in code the EntityListIterator was not closed for a "good" reason: it
might be used later by the framework though not passed as a var. I think I found
1 case where it's closed after the returned list have been used (in
EntityAnd.getChildren() in ModelTree.java); but I have to check the whole thing
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1798086 13f79535-47bb-0310-9956-ffa450edef68
Replaces EntityListIterator.close() in finally by try-with-ressource
With, mmm..., some refactoring. For instance I don't like re-throwing an
exception
and I'm not alone
https://martinfowler.com/articles/replaceThrowWithNotification.html
In case of event I prefer when we use something like
request.setAttribute("_ERROR_MESSAGE_", errMsg);
like also suggests Martin Fowler
So I did that, of course it's tested, as similar changes done already
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1797792 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-9385)
This is an improvement only because no cases were reported. But obviously in
case of unlucky exception after the EntityListIterator creation and before it's
closed the EntityListIterator remains in memory.
It should be closed in EntityListIterator.finalize() but the less happens there
the better.
The solution is to use try-with-ressources
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1797791 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-9385)
This is an improvement only because no cases were reported. But obviously in
case of unlucky exception after the EntityListIterator creation and before it's
closed the EntityListIterator remains in memory.
It should be closed in EntityListIterator.finalize() but the less happens there
the better.
The solution is to use try-with-ressources
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1797790 13f79535-47bb-0310-9956-ffa450edef68
Improved: Writer closed but not in case of exception
(OFBIZ-9388)
This is an improvement only because no cases were reported. But obviously in
case of unlucky exception after the Writer creation and before it's closed the
Writer remains in memory.
The solution is to use try-with-ressources when possible.
This also improves the way the EntityListIterator is closed, using
try-with-ressources instead of closing in case of exception
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1797744 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-9388)
This is an improvement only because no cases were reported. But obviously in
case of unlucky exception after the Writer creation and before it's closed the
Writer remains in memory.
The solution is to use try-with-ressources when possible, even when finally was
used (no problems then).
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1797742 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-9385)
This is an improvement only because no cases were reported. But obviously in
case of unlucky exception after the EntityListIterator creation and before it's
closed the EntityListIterator remains in memory.
It should be closed in EntityListIterator.finalize() but the less happens there
the better.
I noticed Groovy has no try-with-ressources statement. I put a comment in
the description of OFBIZ-9296 "Update Gradle to 2.4.10" Maybe a solution would
be to use streams but really WTF! It seems Gradle 2.5 has autocloseable...
This contains also some refactoring and code cleaning
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1797373 13f79535-47bb-0310-9956-ffa450edef68
Improves EntityListIterator.close() warning
It was something like
ContentAssoc] has already been closed, not closing again.
It's now properly
This EntityListIterator for Entity [ContentAssoc] has already been closed,
not closing again.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1797356 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-9296)
While working to see if we can somehow use a mechanism like try-with-ressources
in Groovy I found that apart for streams it's not available. It seems
autocloseable is available in 2.5 but I did not dig enough
In the meantime this updates Groovy to 2.4.10.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1797226 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-9385)
This is an improvement only because no cases were reported. But obviously in
case of unlucky exception after the EntityListIterator creation and before it's
closed the EntityListIterator remains in memory.
It should be closed in EntityListIterator.finalize() but the less happens there
the better.
The solution is to use try-with-ressources
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1797160 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-9385)
This is an improvement only because no cases were reported. But obviously in
case of unlucky exception after the EntityListIterator creation and before it's
closed the EntityListIterator remains in memory.
It should be closed in EntityListIterator.finalize() but the less happens there
the better.
The solution is to use try-with-ressources
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1797159 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-9385)
This is an improvement only because no cases were reported. But obviously in
case of unlucky exception after the EntityListIterator creation and before it's
closed the EntityListIterator remains in memory.
It should be closed in EntityListIterator.finalize() but the less happens there
the better.
The solution is to use try-with-ressources
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1797158 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-7406)
Steps to regenerate issue:
1. Go to PROJECTS component
2. Click on sub-menu "Projects"
3. Click on find button
________________________________________________
#Browse the link:
https://localhost:8443/projectmgr/control/FindProject
This is similar with OFBIZ-9385 but the case is one of the convoluted.
The fix is though rather simple: use try-with-ressources and refactor around
Thanks: Vaibhav Jain for report
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1797079 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-9385)
This is an improvement only because no cases were reported. But obviously in
case of unlucky exception after the EntityListIterator creation and before it's
closed the EntityListIterator remains in memory.
It should be closed in EntityListIterator.finalize() but the less happens there
the better.
The solution is to use try-with-ressources
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1797074 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-9145)
I encounter a problem when try to re-enter orders originally created in another
system (not ofbiz). And I found some cases when it's not possible to reproduce
it exactly due to some promo rules triggered in this another system.
But I must. Difference .01 is important.
Solution would be if I can change the unit price in an existing order using
value with 3 digits after decimal point. I found that if I add new order item
and check "Override" price I am able to enter more precise values.
But if I update unit price in an existing order item I am not, updateOrderItems
rounds it to 2 digits. Exactly the same intention but works differently.
This makes me think we can remove rounding in second case.
I believe if user want to change the unit price he knows why.
jleroux: despite slightly changing the behaviour of updateOrderItems, I see no
crucial reasons why we would not do that. The consistency aspect is here
important.
Thanks: Oleg Andreyev
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1797066 13f79535-47bb-0310-9956-ffa450edef68
Related to task OFBIZ-9350 Deprecate Mini Lang, convert services createPartyAcctgPreference, getPartyAccountingPreferences, setAcctgCompany, updateFXConversion and getFXConversion from mini-lang to groovyDSL
Commited slightly modified patch from Leila, implementing Jacques and Deepak recommendations.
Thanks to Jacques and Deepak for the review, Leila for the provided patch.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1796731 13f79535-47bb-0310-9956-ffa450edef68
related to task OFBIZ-9350 Deprecate Mini Lang, convert service updateRateAmount, deleteRateAmount updatePartyRate and deletePartyRate from mini-ang to groovyDSL
Thanks to Deepak for the review
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1796428 13f79535-47bb-0310-9956-ffa450edef68
from given freqCount raster.
(OFBIZ-9374)
If a job is scheduled using TemporalExpressions.Frequency the start time of the
job will gradually move forward when the excecution of the job is delayed by one
or more units of the frequency type.
Example: Job is set up to start at 2017-01-01 00:00:00 and run every ten
minutes. One month later due to some circumstances the job starts at
2017-02-01 00:01:01 which results in the next execution to be scheduled at
2017-02-01 01:11:00 in stead of 2017-02-01 01:10:00.
The reason behind this behaviour is the TemporalExpressions.Frequency#prepareCal
function. It has the purpose to jump from the first starting time to the latest
possible execution of the job. But instead it just sets it to the current time
(with the precision of the chosen frequency type) and calculates the next
execution time from this point.
Thanks: Tobias Laufkötter for reporting and providing the patch.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1796047 13f79535-47bb-0310-9956-ffa450edef68