Commit Graph
2421 Commits
Author SHA1 Message Date
Jacopo Cappellato e1c2fae001 Forgot to include the jars in my previous commit. Upgraded to the latest, now official, release of Freemarker: 2.3.21 Freemarker is now released under the Apache License 2.0
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1631300 13f79535-47bb-0310-9956-ffa450edef68
2014-10-13 06:53:21 +00:00
Jacopo Cappellato 5e106b124d Upgraded to the latest, now official, release of Freemarker
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1631299 13f79535-47bb-0310-9956-ffa450edef68
2014-10-13 06:45:42 +00:00
Scott Gray 827289c9bc Remove dead code
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1631019 13f79535-47bb-0310-9956-ffa450edef68
2014-10-11 04:52:32 +00:00
Jacopo Cappellato 3b8baced92 Upgraded freemarker to 2.3.21-rc02.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1628130 13f79535-47bb-0310-9956-ffa450edef68
2014-09-29 07:37:46 +00:00
Jacques Le Roux 6e717f7bd0 A patch from Leon for "HttpClient does not support charset name with quotation mark around" https://issues.apache.org/jira/browse/OFBIZ-5787
In RFC2045 (Section 5.1) there is:
"Content-type: text/plain; charset=us-ascii (Plain text)
Content-type: text/plain; charset="us-ascii"
are completely equivalent".

In current revision, if the 'Content-Type' of http response includes the quotation mark around the charset name, HttpClient throws out unsupported encoding exception.

This patch removes quotation marks from charset name extracted from http response header.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1627230 13f79535-47bb-0310-9956-ffa450edef68
2014-09-24 06:40:46 +00:00
Jacopo Cappellato adc41ad5bf Moved the thread pool executor object from GenericDAO to the DatabaseUtil class where it was actually used: this change simplifies the API and allows to shutdown the pool when it is no more needed.
Removed a series of methods that are no more needed after this refactoring or were not used.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1627092 13f79535-47bb-0310-9956-ffa450edef68
2014-09-23 17:04:20 +00:00
Jacopo Cappellato d4c5b5112a Small code enhancement: use FixedThreadPool to run the "pulse" worker threads.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1626993 13f79535-47bb-0310-9956-ffa450edef68
2014-09-23 12:59:13 +00:00
Jacopo Cappellato f14003d799 Removed a bunch of never used classes from the base/concurrent package.
Provided better settings for the thread pools to avoid to keep alive threads that are only needed at startup.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1626977 13f79535-47bb-0310-9956-ffa450edef68
2014-09-23 10:52:29 +00:00
Jacques Le Roux c19e450091 As suggested by Jacopo on dev ML moves the README file related to SSL certificate from framework/base/README to framework/base/config/README
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1626881 13f79535-47bb-0310-9956-ffa450edef68
2014-09-22 19:48:37 +00:00
Jacques Le Roux 6833c2acd4 We agreed with Jacopo that the framework/base/cert directory is more misleading than helping. So this removes it.
I though keep the slightly expurgated README file for the sake of certificates creation history. I move it to framework/base

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1626874 13f79535-47bb-0310-9956-ffa450edef68
2014-09-22 19:17:45 +00:00
Ashish Vijaywargiya 44bc632d5a Applied patch from jira issue - OFBIZ-1524 - Improve the way CreditCard.cardType field is managed.
Thanks Akash Jain for the contribution. 

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1626425 13f79535-47bb-0310-9956-ffa450edef68
2014-09-20 12:16:37 +00:00
Jacopo Cappellato 91573e60fb Attempt to improve the code that setups the Tomcat instance, the engine, hosts and contexts: this is still a work in progress but at least now the Tomcat instance is initialized without warning messages as was before.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1626060 13f79535-47bb-0310-9956-ffa450edef68
2014-09-18 19:48:01 +00:00
Jacques Le Roux 3b118d4842 An excerpt of a patch from Nick Ho for "Add/Revise Traditional Chinese (zh-TW) translations" https://issues.apache.org/jira/browse/OFBIZ-5764
added/revised zh-TW translations in the framework, applications and specialpurpose folders to have consistent, commonly-used meaningful terms in Traditional Chinese.

jleroux: from Nick Ho's patch I have extracted only the Chinese changes, w/o the proposed  dash to underscore changes
This contains notably this 14 "zh" (not "sh-TW") changes:
<value xml:lang="zh">人将由电子邮件接受一个临时密码。</value><!-- was 客户将通过电子邮件收到一个临时密码。 -->
<value xml:lang="zh">合计属于公司: </value>
<value xml:lang="zh"> 完整文本:${fullText}</value>
<value xml:lang="zh">供货商佣金百分比</value>
<value xml:lang="zh">文本大小</value>
<value xml:lang="zh">值</value>
<value xml:lang="zh">算子</value>
<value xml:lang="zh">不能转移已序列化的库存。</value>
<value xml:lang="zh">货运收据</value>
<value xml:lang="zh">获取标识为 ${productStoreShipMethId} 的产品店铺送货方法(ProductStoreShipmentMeth)时出错:${errorString}</value>
<value xml:lang="zh">中国人民币元</value>
<value xml:lang="zh">如果选择"specify other",下拉框旁边会出现文本框。参考form的drop-down元素的other-field-size属性说明</value>
<value xml:lang="zh">文本消息</value>
<value xml:lang="zh">能够收到和解析XML消息,但是BSR->NOUN(买卖关系->名词) ${bsrNoun} 和/或 BSR->VERB(买卖关系->动词) ${bsrVerb} 是空的</value>
I have no competency to judge these changes, but from previous Shi Jinghai's feedback I believe there are OK

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1625816 13f79535-47bb-0310-9956-ffa450edef68
2014-09-17 20:44:07 +00:00
Jacques Le Roux 7241a35012 No functional changes, better JavaDoc only
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1625001 13f79535-47bb-0310-9956-ffa450edef68
2014-09-15 11:47:19 +00:00
Jacques Le Roux 70a364f81c Adds an isFile() method in FileUtil class.
It checks if the specified fileName exists and is a file (not a directory)

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1624996 13f79535-47bb-0310-9956-ffa450edef68
2014-09-15 11:02:35 +00:00
Jacopo Cappellato 1a71a69ea6 Removed the ClassLoaderContainer: it is no more used.
Moved the portOffset field from ClassLoaderContainer to the Start/Config class.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1624700 13f79535-47bb-0310-9956-ffa450edef68
2014-09-13 06:57:02 +00:00
Jacopo Cappellato fa8115dba5 Removed the custom CachedClassLoader and related artifacts in favour of a simpler bootstrap process and a simpler classpath tree; now the classpath tree is made of: bootstrap classloader (primordial+ext) -> system classloader (aka applications or classpath classloader) -> two custom classloaders (one loads the framework/base classes and one loads all the other classes) -> Webapp classloaders (one per web application).
Junit tests are included. The two custom classloaders could be merged into one but this will be addressed in a second phase because it will require some changes to the bootstrap componenr and process.



git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1624549 13f79535-47bb-0310-9956-ffa450edef68
2014-09-12 13:49:17 +00:00
Jacopo Cappellato 189b8a4b34 A series of simplifications, cleanups of old code, and improvements to the code that setup the class paths for the OFBiz classloaders; the former code was setting the same jars (e.g. ofbiz.jar and all the base libs) in both the parent/child classloaders; it was unnecessarily setting the classpath system property when not required/useful.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1623352 13f79535-47bb-0310-9956-ffa450edef68
2014-09-08 10:38:28 +00:00
Jacopo Cappellato 4833915d0d Removed unused jars.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1623042 13f79535-47bb-0310-9956-ffa450edef68
2014-09-07 15:04:31 +00:00
Jacopo Cappellato 3c76aa4b89 Removed unused jars.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1623005 13f79535-47bb-0310-9956-ffa450edef68
2014-09-07 12:35:38 +00:00
Jacopo Cappellato c50eb3abfb Removed three asm jars not used by OFBiz code or any other jars in the OFBiz trunk.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1622996 13f79535-47bb-0310-9956-ffa450edef68
2014-09-07 10:31:29 +00:00
Jacopo Cappellato 75fe5a9107 Removed the old UtilJ2eeCompat util class that was probably created for compatibility with some old application servers.
UtilJ2eeCompat was used to figure out, by checking the servlet container implementation, if the response should be sent using a Writer or a OutputStream; a Writer was used for Tomcat, Websphere, Jetty, Orion, Jrun, Tradecity and an OutputStream was used for all the other servlet containers.

However accordingly to the Servlet api:

ServletResponse.getWriter():
         Returns a PrintWriter object that can send character text to the client.
ServletResponse.getOutputStream():
         Returns a ServletOutputStream suitable for writing binary data in the response.

Based on this getWriter() should always be used (for html pages) in all the containers, not just Tomcat, Websphere, Jetty, Orion, Jrun, Tradecity.



git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1622976 13f79535-47bb-0310-9956-ffa450edef68
2014-09-07 06:32:25 +00:00
Jacopo Cappellato b324c22bcc Misc cleanups to remove dead code (that could never run or was not used), made a series of fields private and/or final, added some comments, formatting fixes.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1622409 13f79535-47bb-0310-9956-ffa450edef68
2014-09-04 06:47:31 +00:00
Jacopo Cappellato 6f112e3ea7 Greatly simplified the UtilJ2eeCompat class by removing a series of variables and methods no more in use.
The class was not thread safe and this didn't cause particular issues probably just because all the threads using it were passing ServletContext with the same server info value (because they were associated to the same servlet container); it was however inefficient.
 Now it is thread safe using the DCL pattern which I usually tend to avoid but is useful here.
 However this class should probably go away but before taking a decision I will start a discussion in the dev list.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1622193 13f79535-47bb-0310-9956-ffa450edef68
2014-09-03 09:10:04 +00:00
Jacopo Cappellato 2b384efa04 Increased the length of the logger column from 20 to 30 characters.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1621701 13f79535-47bb-0310-9956-ffa450edef68
2014-09-01 08:29:28 +00:00
Jacopo Cappellato b20d598a67 Updated freemarker jar to the release candidate 01; waiting for the official release that should happen in mid October 2014.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1621683 13f79535-47bb-0310-9956-ffa450edef68
2014-09-01 06:28:49 +00:00
Adrian Crum d81823384d Small code cleanup in UtilCache.java.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1620249 13f79535-47bb-0310-9956-ffa450edef68
2014-08-25 00:37:24 +00:00
Adrian Crum 227ba5f9db Small improvement to UtilCache - allow a component to specify its own cache settings file.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1620244 13f79535-47bb-0310-9956-ffa450edef68
2014-08-25 00:02:45 +00:00
Jacopo Cappellato 38b7048581 Upgraded two j2ee spec jars from Geronimo.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1619300 13f79535-47bb-0310-9956-ffa450edef68
2014-08-21 07:30:06 +00:00
Jacopo Cappellato d8c412302f OFBIZ-5287: Upgrade to Log4j2
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1618831 13f79535-47bb-0310-9956-ffa450edef68
2014-08-19 10:36:01 +00:00
Adrian Crum aadc814ba3 Updated Commons CSV library to the official release version (the previous version was a release candidate).
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1618332 13f79535-47bb-0310-9956-ffa450edef68
2014-08-16 11:22:36 +00:00
Adam Heath 58c866dfbd Add a simple Future implementation, that returns a constant,
non-changing value.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1617811 13f79535-47bb-0310-9956-ffa450edef68
2014-08-13 19:38:18 +00:00
Adam Heath 61a8dabc7e Add a GLOBAL_BATCH thread pool. This is different than GLOBAL_EXECUTOR,
in that:

* BATCH does not block when all the coreThreads are busy, as would
  happen with EXECUTOR.  When all coreThreads are busy, new threads will
  be spawned.
* Scheduled jobs can *not* be submitted.

You can simulate the first problem, by modifying ExecutionPool, and
force-setting the threadCount to 1.  Then, submit something to the pool,
that will then itself submit more items into the pool.  Dead-lock will
occur.

BATCH should be used when it might be posslbe that more items could be
submitted by code you are calling.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1617810 13f79535-47bb-0310-9956-ffa450edef68
2014-08-13 19:38:12 +00:00
Adam Heath 2aaa234042 Add a global fork-join thread pool, and switch a bunch of stuff over to
it.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1617809 13f79535-47bb-0310-9956-ffa450edef68
2014-08-13 19:38:01 +00:00
Adam Heath 111f90c057 Add a helper method for auto adjusting the threadCount.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1617808 13f79535-47bb-0310-9956-ffa450edef68
2014-08-13 19:37:49 +00:00
Jacopo Cappellato 066d782950 Misc minor cleanups to log messages.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1616744 13f79535-47bb-0310-9956-ffa450edef68
2014-08-08 13:16:46 +00:00
Jacopo Cappellato 37d586c160 Converted some startup messages from "important" to "info".
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1616431 13f79535-47bb-0310-9956-ffa450edef68
2014-08-07 07:52:23 +00:00
Jacopo Cappellato f66ab18d6e Upgrade to Commons DBCP 2; this new version is designed for Java 7 (JDBC 4.1).
Commons DBCP 2 relies on Commons Pool 2 and this commits upgrades that jar too.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1612909 13f79535-47bb-0310-9956-ffa450edef68
2014-07-23 18:26:33 +00:00
Adam Heath ccb36f2238 Fix cobertura-report when source has been generated(aka, when javacc or
jjtree has been used).

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1605838 13f79535-47bb-0310-9956-ffa450edef68
2014-06-26 16:15:15 +00:00
Adam Heath e04a063f21 Fix line-ending differences between windows and unix in UtilIO parsing.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1605837 13f79535-47bb-0310-9956-ffa450edef68
2014-06-26 16:15:09 +00:00
Adrian Crum 714050ef33 Updated build files to use/require Java 7.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1605524 13f79535-47bb-0310-9956-ffa450edef68
2014-06-25 17:59:46 +00:00
Adam Heath 83b70a5643 Fix reversion introduced in StringUtil in r1330955; string maps using
"|" were being parsed correctly.  This fixes OFBIZ-5667.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1605268 13f79535-47bb-0310-9956-ffa450edef68
2014-06-25 05:27:22 +00:00
Adam Heath 455edd3727 Remove sourcepathref from default-javac; in build.xml that did *not*
create a src-dir patternset, the default *empty* src-dir pattern set was
used.  Then, when javac would compile src/**/*.jar, it would *also*
compile any *other* java files it happened to find in the folder.

In other words, if there was an unpacked tree, let's say named 'p', and
there was a set of folders in there that eventually had java files, they
would all get compiled.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1605223 13f79535-47bb-0310-9956-ffa450edef68
2014-06-24 23:21:05 +00:00
Adam Heath 6690816b01 Fix detection of cobertura, for compilation of the hook used by the
runtime container; also fixes the classpath used to define the ant
task.  Now, command-line api tests run underneath cobertura work.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1605216 13f79535-47bb-0310-9956-ffa450edef68
2014-06-24 23:07:39 +00:00
Adam Heath da7504cc2e Revert "Move ant out of the primary classpath; the shell script and batch file"
This reverts commit 24d7bda48e9618691b28cf63ef02354e1c2df2c8.

Conflicts:

	LICENSE

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1605179 13f79535-47bb-0310-9956-ffa450edef68
2014-06-24 20:30:39 +00:00
Adam Heath 55a4cc3023 Remove ant-nodeps, it's no longer part of 1.9.0 apparently.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1605121 13f79535-47bb-0310-9956-ffa450edef68
2014-06-24 16:01:29 +00:00
Adam Heath 702ac6d2f8 Move ant out of the primary classpath; the shell script and batch file
now load it from this out-of-band location.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1605119 13f79535-47bb-0310-9956-ffa450edef68
2014-06-24 16:01:13 +00:00
Jacopo Cappellato 05073f29df Upgrade to the most recent version of Freemarker-2.3-gae: this is not an official release yet but it will be soon; I have committed this work, as discussed in the dev list, in order to get help from the community to test this new improved version of Freemarker and provide feedback to the Freemarker community.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1605029 13f79535-47bb-0310-9956-ffa450edef68
2014-06-24 08:33:04 +00:00
Jacques Le Roux 0f31bcb2a0 Adds a new self signed SSL certificate created on the OFBiz demo VM with own CA following http://httpd.apache.org/docs/current/ssl/ssl_faq.html#realcert
This certificate is valid for 10 years (until May 27 08:43:19 2024 GMT)
Characteristics: C=US, ST=DE, L=Wilmington, O=Apache Software Fundation, OU=Apache OFBiz, CN=ofbiz-vm.apache.org/emailAddress=dev@ofbiz.apache.org
The password is still the same: changeit, I checked: HTTPS works locally

I don't really understand the content and the need of framework/base/cert/ so I only added framework/base/cert/demoCA/newcerts/03.pem and framework/base/cert/README which explains this change


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1598544 13f79535-47bb-0310-9956-ffa450edef68
2014-05-30 10:46:54 +00:00
Jacques Le Roux e3a6768d56 Reverts r1598505, I will also update the files under framework\base\cert to backport all in one shoot
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1598507 13f79535-47bb-0310-9956-ffa450edef68
2014-05-30 09:04:38 +00:00