Commit Graph
1462 Commits
Author SHA1 Message Date
Marco Risaliti 4074ec00db Remove some warning in ModelViewEntity (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1078212 13f79535-47bb-0310-9956-ffa450edef68
2011-03-04 23:19:24 +00:00
Marco Risaliti e156beeb76 Remove some warning in SqlJdbcUtil (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1078211 13f79535-47bb-0310-9956-ffa450edef68
2011-03-04 23:18:33 +00:00
Marco Risaliti 88cda83037 Remove some warning in ModelFieldType (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1078210 13f79535-47bb-0310-9956-ffa450edef68
2011-03-04 23:18:16 +00:00
Erwan de Ferrieres f1f6fbc85e When displaying a view, using at first the default-resource and the view entity-name for entitylabels then the entity. Before only the entity was read
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1077951 13f79535-47bb-0310-9956-ffa450edef68
2011-03-04 14:05:03 +00:00
Erwan de Ferrieres cfe25142ae When using a view and fields with different names than in the original entity, the model was taking the original names so this could lead to warnings
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1077940 13f79535-47bb-0310-9956-ffa450edef68
2011-03-04 13:36:11 +00:00
Marco Risaliti fed87a3cbd Remove a warning in EntityUtil (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1076851 13f79535-47bb-0310-9956-ffa450edef68
2011-03-03 22:31:42 +00:00
Marco Risaliti 06f4d340a8 Remove some warning in XmlSerializer (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1076843 13f79535-47bb-0310-9956-ffa450edef68
2011-03-03 22:22:59 +00:00
Marco Risaliti 55d029ee2c Remove some warning in EntityConditionPlanner (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1076841 13f79535-47bb-0310-9956-ffa450edef68
2011-03-03 22:21:31 +00:00
Marco Risaliti d067c65f81 Remove some warning/unused variable in EntityPlanner (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1076840 13f79535-47bb-0310-9956-ffa450edef68
2011-03-03 22:20:56 +00:00
Marco Risaliti abb3c8b436 Remove some warning in EntitySelectPlan (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1076837 13f79535-47bb-0310-9956-ffa450edef68
2011-03-03 22:19:03 +00:00
Scott Gray c9ec4ae824 Add inline-jdbc attribute idle-maxsize for greater control over the max idle connections that should remain in the pool. Previously it was always set to half of pool-maxsize (and still defaults to this value)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1076114 13f79535-47bb-0310-9956-ffa450edef68
2011-03-02 06:31:38 +00:00
Marco Risaliti 2b1f993292 Remove some warning in EntityFinderUtil (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1075521 13f79535-47bb-0310-9956-ffa450edef68
2011-02-28 20:36:29 +00:00
Marco Risaliti 8fc1103633 Add some @SuppressWarning("serial") in EntityFinderUtil (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1075512 13f79535-47bb-0310-9956-ffa450edef68
2011-02-28 20:13:30 +00:00
Marco Risaliti 321e1ef08d Remove an unused variable in GenericDAO (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1075510 13f79535-47bb-0310-9956-ffa450edef68
2011-02-28 20:02:07 +00:00
Marco Risaliti f729c27c2d Remove an unused import in GenericDelegator (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1075507 13f79535-47bb-0310-9956-ffa450edef68
2011-02-28 19:53:15 +00:00
Marco Risaliti a14d03ccde Remove an unused import in EntityComparisonOperator (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1075506 13f79535-47bb-0310-9956-ffa450edef68
2011-02-28 19:51:42 +00:00
Sascha Rodekamp 40f52ad764 Improvement - if-regexp conditions in Minilang and Screens not thread safe (https://issues.apache.org/jira/browse/OFBIZ-4107). I added another getTestPattern Method to support case insensitive tests. The case insensitive testPattern is needed from the UtilHttp.checkURLforSpiders.
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
2011-02-28 13:43:23 +00:00
David E. Jones bcae85b5f4 Reduced logging of an exception that is just rethrown, still logs error but not full stack trace
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1073196 13f79535-47bb-0310-9956-ffa450edef68
2011-02-22 01:18:55 +00:00
David E. Jones 3b20b9c06f Reversing accidental commit in rev 1072292
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1072301 13f79535-47bb-0310-9956-ffa450edef68
2011-02-19 10:38:13 +00:00
David E. Jones 2d28cc3d66 VUA-429 full implementation to add a path through the screens for creating a sales order for a contact and add a customer for the contact in the process
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1072292 13f79535-47bb-0310-9956-ffa450edef68
2011-02-19 10:13:50 +00:00
Marco Risaliti 714b091780 Remove an unused variable/import in EntityDataAssert (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1069072 13f79535-47bb-0310-9956-ffa450edef68
2011-02-09 20:36:18 +00:00
Marco Risaliti 8db113dee2 Add a @SuppressWarning("serial") in EntityFindOptions (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1068649 13f79535-47bb-0310-9956-ffa450edef68
2011-02-08 22:34:48 +00:00
Marco Risaliti 650214e0fe Add a @SuppressWarning("serial") in ByteWrapper (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1068647 13f79535-47bb-0310-9956-ffa450edef68
2011-02-08 22:34:11 +00:00
Marco Risaliti 402fa9441d Add a @SuppressWarning("serial") in GenericTransactionException (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1068646 13f79535-47bb-0310-9956-ffa450edef68
2011-02-08 22:33:24 +00:00
Marco Risaliti d5eb73c6ac Remove unused import in SQLUtil (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1068644 13f79535-47bb-0310-9956-ffa450edef68
2011-02-08 22:32:51 +00:00
Marco Risaliti b0087a4e99 Add a @SuppressWarning("serial") in SerializeException (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1068643 13f79535-47bb-0310-9956-ffa450edef68
2011-02-08 22:31:47 +00:00
Marco Risaliti a5bfa1cca0 Add a @SuppressWarning("serial") in ModelRelation (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1068642 13f79535-47bb-0310-9956-ffa450edef68
2011-02-08 22:30:59 +00:00
Marco Risaliti 860fbdff0e Add a @SuppressWarning("serial") in ModelKeyMap (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1068641 13f79535-47bb-0310-9956-ffa450edef68
2011-02-08 22:30:33 +00:00
Marco Risaliti 378c121813 Remove unused import in ModelInfo (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1068638 13f79535-47bb-0310-9956-ffa450edef68
2011-02-08 22:29:53 +00:00
Marco Risaliti ced181c8c3 Add a @SuppressWarning("serial") in ModelIndex (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1068637 13f79535-47bb-0310-9956-ffa450edef68
2011-02-08 22:29:12 +00:00
Marco Risaliti b8b31afa17 Add a @SuppressWarning("serial") in ModelGroupReader (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1068634 13f79535-47bb-0310-9956-ffa450edef68
2011-02-08 22:28:41 +00:00
Marco Risaliti 228b5d5815 Add a @SuppressWarning("serial") in ModelField (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1068633 13f79535-47bb-0310-9956-ffa450edef68
2011-02-08 22:28:00 +00:00
Marco Risaliti b4aa415419 Add a @SuppressWarning("serial") in ModelChild (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1068632 13f79535-47bb-0310-9956-ffa450edef68
2011-02-08 22:27:32 +00:00
Marco Risaliti fc0618e392 Remove unnecessary suppress of warnings in ModelEntity (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1068631 13f79535-47bb-0310-9956-ffa450edef68
2011-02-08 22:27:10 +00:00
Marco Risaliti bbda8564c7 Add a @SuppressWarning("serial") in DatabaseUtil (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1068628 13f79535-47bb-0310-9956-ffa450edef68
2011-02-08 22:24:38 +00:00
Marco Risaliti abbd231d81 Add a @SuppressWarning("serial") in some Entity exception (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1068625 13f79535-47bb-0310-9956-ffa450edef68
2011-02-08 22:23:28 +00:00
Marco Risaliti e986ee1d2e Remove an unused private method of EntityConfigUtil instead of suppress it as unused (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1068508 13f79535-47bb-0310-9956-ffa450edef68
2011-02-08 18:31:48 +00:00
Marco Risaliti e66e04690e Remove compilation warnings of an unused private method in EntityConfigUtil (OFBIZ-4102)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1068132 13f79535-47bb-0310-9956-ffa450edef68
2011-02-07 21:03:38 +00:00
David E. Jones 3502196c12 To avoid unnecessary synchronization for the fairly large number of calls that result in returning false instead of beginning a transaction moved the setTransactionTimeout and begin calls into a separate synchronized method and removed synchronized from the begin method
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1066327 13f79535-47bb-0310-9956-ffa450edef68
2011-02-02 05:07:54 +00:00
Jacques Le Roux c2ea70f355 A slightly modified patch from Pierre Smits "Enhancement to create new tenants easier" (https://issues.apache.org/jira/browse/OFBIZ-3971) - OFBIZ-3971
This patch enables users to create new tenants via the ANT process.
Users can enter:
    * Tenant ID
    * Tenant Name
    * Data to load on creation of the tenant db (e.g.seed, seed-ext, demo)
    * Database Platform (Derby, MySQL, Oracle, PostgreSQL) remark: You can NOT mix platforms)
    * IP address of the database (you can add a port if needed)
    * User-ID for the database
    * Password for the database

Based on the data provided the process will:
    * Create a new row in the Tenant table
    * Create a new row in the TenantDataSource table
    * Create new tables in the new tenant database and fill with initial data (seed, seed-ext, demo)
    * Create a new admin id for the tenant (based on Tenant ID followed by '-admin')
    * Set the initial password for the tenant admin id (initial 'ofbiz', must be changed on first login)

This patch has been tested against: Derby, MySQL, PostgreSQL. This has not been tested against other db platforms.

Prior to running the ANT task the user
    * has to modify 'general.properties' in framework/common/config to reflect multi tenancy (multitenant=Y)
    * has to have appropriate db driver(s) in place
    * has to create the databases first in function of the entityengine.xml datasource-names (not for Derby, applicable for MySQL and PostgreSQL.)


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1065144 13f79535-47bb-0310-9956-ffa450edef68
2011-01-29 23:35:01 +00:00
Jacques Le Roux c054c7ed6e Formatting, no functional changes
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1062866 13f79535-47bb-0310-9956-ffa450edef68
2011-01-24 16:38:32 +00:00
Jacques Le Roux f28b0343e1 A patch from Deyan "Allow attributes enable-lock, no-auto-stamp, auto-clear-cache, never-cache and sequence-bank-size in <extend-entity> tag in entitydef.xml fields " (https://issues.apache.org/jira/browse/OFBIZ-3882) - OFBIZ-3882
Allow attributes
enable-lock
no-auto-stamp
auto-clear-cache
never-cache
sequence-bank-size

in <extend-entity> tag in entitydef.xml fiels

Example: <extend-entity entity-name="Person" enable-lock="true" sequence-bank-size="1" />

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1062863 13f79535-47bb-0310-9956-ffa450edef68
2011-01-24 16:33:16 +00:00
Jacques Le Roux 1dab0c10f2 Update copyright from 2010 to 2011, BTW this closes "update files from 2009 to 2010" (https://issues.apache.org/jira/browse/OFBIZ-3783) - OFBIZ-3783
I have changed ModelInfo.getCopyright() in order to automatize (I believe the copyright is always valid so we don't care about the date really used, if you disagree please let me know, I have a doubt about this...)

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1061886 13f79535-47bb-0310-9956-ffa450edef68
2011-01-21 16:33:22 +00:00
Jacques Le Roux 65ab7533f0 A patch from Jeroen van der Wal "When audit log is enabled it creates log transactions even when there are no changes" (https://issues.apache.org/jira/browse/OFBIZ-4076) - OFBIZ-4076
The createEntittyAuditLogSingle function creates a record in the AuditLog entity even when there's no change. This patch only logs new, changed and deleted values. Also, all changes in the same transaction will get the same change date.

After applying this patch the overhead of the AuditEntityLog is recuded from 32% to 25%.

There's even more room for performance increase: a findOne search for the previous entity is done for every field that's enabled.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1056973 13f79535-47bb-0310-9956-ffa450edef68
2011-01-09 16:36:40 +00:00
Andrew Zeneski ad997886c7 changed the sql generated from the table-type field (used to specify the table type in mysql) from TYPE (deprecated in 4.1 and removed in 5.5.8 (maybe prior) to use the ENGINE keyword instead; creating tables in mysql 5.5.8 now working again
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1053722 13f79535-47bb-0310-9956-ffa450edef68
2010-12-29 20:00:36 +00:00
Erwan de Ferrieres a7b967d48b Using ivy for downloading PostgreSQL driver
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1050927 13f79535-47bb-0310-9956-ffa450edef68
2010-12-19 18:14:50 +00:00
Erwan de Ferrieres 9502bf228d Upgrading to the latest Apache Derby version (10.7.1.1) - changelog is at http://db.apache.org/derby/releases/release-10.7.1.1.cgi
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1049712 13f79535-47bb-0310-9956-ffa450edef68
2010-12-15 21:13:46 +00:00
Scott Gray 2ecc4b2494 Removed unnecessary SuppressWarnings annotations
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1044932 13f79535-47bb-0310-9956-ffa450edef68
2010-12-12 21:31:51 +00:00
Scott Gray 47f43a302a Remove unnecessary casts
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1044931 13f79535-47bb-0310-9956-ffa450edef68
2010-12-12 21:31:27 +00:00
Scott Gray 75b0b1c1e3 Remove unnecessary semicolons
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1044917 13f79535-47bb-0310-9956-ffa450edef68
2010-12-12 20:43:03 +00:00