Thanks Martin & Dimitri for your effort.
Orig. Msg.:
The Perl5Matcher Perl5Compiler are not thread safe, as mentioned in their documentation: http://jakarta.apache.org/oro/api/org/apache/oro/text/regex/Perl5Compiler.html
A separate instance should be used per thread.
The concrete issue occurred in our system in the createCommContentDataResource service. The service tries to save emails to the database after they have been sent. It failed because of the described issue. This caused the whole email service (sendMailFromScreen) to be rescheduled. So customers got emails twice.
The Perl5Matcher and Perl5Compiler instances are assigned to static fields in the org.ofbiz.minilang.method.ifops.IfRegexp class. So every thread will use the same instance. No synchronization is done currently. Changing the fields to be non-static will not work either, as SimpleMethods are cached. So all calls to the same simple method use the same IfRegexp instance.
We fixed the problem by moving the instantiation of the Perl5Matcher and Perl5Compiler to the exec() method in IfRegexp.
Other classes are most likely affected, too: org.ofbiz.entity.condition.EntityComparisonOperator, org.ofbiz.minilang.method.conditional.RegexpCondition, org.ofbiz.minilang.operation.Regexp, org.ofbiz.widget.menu.ModelMenuCondition$IfRegexp, org.ofbiz.widget.screen.ModelScreenCondition$IfRegexp, org.ofbiz.widget.tree.ModelTreeCondition$IfRegexp
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1075322 13f79535-47bb-0310-9956-ffa450edef68
Orig. Msg.:
Improvement of UtilProperties.java with a new method which returns the Number as an Object of the specified property name from the specified resource/properties file.
If the specified property name or properties file is not found, the defaultObject is returned.
i did update my method "getPropertyNumber" a bit and
as requested i added "getPropertyAsInteger / asLong / AsFloat / AsDouble / AsBigInteger / AsBigDecimal".
In addition i added a "getPropertyAsBoolean".
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1073113 13f79535-47bb-0310-9956-ffa450edef68
* Adds a bunch of external SOAP services, none of them work so far, not sure why, a good exercise for the future...
I have tried to backport to R9.04 the testRemoteSoap change but it does not work there:
2011-02-19 17:26:02,500 (http-0.0.0.0-8443-1) [ Call.java:2469:ERROR] Exception:
org.xml.sax.SAXException: Deserializing parameter 'map-Map': could not find deserializer for type {http://www.w3.org/2001/XMLSchema}anyType
at org.apache.axis.message.RPCHandler.onStartChild(RPCHandler.java:277)
at org.apache.axis.encoding.DeserializationContext.startElement(DeserializationContext.java:1035)
at org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:165)
at org.apache.axis.message.MessageElement.publishToHandler(MessageElement.java:1141)
at org.apache.axis.message.RPCElement.deserialize(RPCElement.java:236)
at org.apache.axis.message.RPCElement.getParams(RPCElement.java:384)
at org.apache.axis.client.Call.invoke(Call.java:2467)
at org.apache.axis.client.Call.invoke(Call.java:2366)
at org.apache.axis.client.Call.invoke(Call.java:1812)
at org.ofbiz.service.engine.SOAPClientEngine.serviceInvoker(SOAPClientEngine.java:137)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1072378 13f79535-47bb-0310-9956-ffa450edef68
Orig. Msg.:
now there is a problem when you click on an example to edit it, the decorator is no more present on the form.
to reproduce
In example component, search all examples the click on an id.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1072303 13f79535-47bb-0310-9956-ffa450edef68
I created a new Screen <link feature. Similar to the Form Lookups a link can be opened in a layered JS Box (see Screenshot in Jira Task). It looks nice and is helpful in some cases.
You can add any screen u want. It's expected that you create a certain screen for the layered link which only contains the information you need.
The layered box doesn't contain any logic it's just a container for the screen which should be opened. So the screen it self can decide what to show. i.e if you load a form, the form itself implement the way how it react on a submit (either reload the site or perform the submit as Ajax request in the background).
There is also an example in the example section. Try to create a new Example on the mainpage.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1071698 13f79535-47bb-0310-9956-ffa450edef68
Orig. Msg.:
I guess that the makeLoginUrl-method in the LoginWorker should return a string with expandedEntites.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1071362 13f79535-47bb-0310-9956-ffa450edef68
Orig. Msg:
The DateTimePicker calculates nearly always in 5m steps and rounds up or down, depending on the nearest result. This means, that you have at 14:11:10 and at 14:12:10 a time of 14:10:10 in the DTP and at 14:13:10 and 14:14:10 already 14:15:10 (so on the one hand you have a "current" time that shows in the future and on the other hand the same time 5 times in the DTP (while the mins. dont increase, the seconds do).
comment to the nearly always: i had exactly one case, where i had xx:01:xx, and i cant recreate it...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1071328 13f79535-47bb-0310-9956-ffa450edef68
UtilValidate.isYear returns true for a blank year which the calling function UtilValidate.isDate(String, String, String) tries to parse. This causes an exception to be thrown
ValidateMethod.java:96 :ERROR] [ValidateMethod.exec] Error in validation method isDateAfterToday of class org.ofbiz.base.util.UtilValidate: null
I found this error when trying to add a new credit card in the eCommerce checkout flow.
1. Add a product to the cart
2. login as any user I used "admin"
3. Checkout Step "Shipping Address" (Step 1: Where shall we ship it?)
* Click Next
4. Checkout Step "Shipping Options" (Step 2: How shall we ship it?)
* Choose "UPS Air"
* Click Next
5. Checkout Step "Payment Options" (Step 3: How shall you pay?)
6. Create "Credit Card"
* Fill Name
* Card Type "Visa"
* Card Number "4111111111111111"
* Expiration Date Month drop-down 01
* Expiration Date Year drop-down leave blank
* Choose billing address
* Click "Save" button
Should see "Error in validation method isDateAfterToday of class org.ofbiz.base.util.UtilValidate: null"
My fix is to change isYear, isMonth, and isDay to return false when a blank value is entered.
After I make my change the message is "The expiration date is before today"
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1070230 13f79535-47bb-0310-9956-ffa450edef68
Adds anchor /cmssite/cms/APACHE_OFBIZ_HTML#CASLDAP so it can use permanent link. (CTR mode: Still to be tested)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1069229 13f79535-47bb-0310-9956-ffa450edef68