Commit Graph
1143 Commits
Author SHA1 Message Date
Mathieu Lirzin eeabe69813 Improved: Use ‘depends-on’ attribute instead of “component-load.xml” (OFBIZ-11296)
We currently have two ways to define component loading order. Either
by using ‘depends-on’ attribute in “component-config.xml” or by adding
a “component-load.xml” file at the root of a component directory.

“depends-on” is more flexible because it handles partial ordering when
“component-load.xml” defines a total order which is not necessarily
meaningful, so it is better to rely only “depends-on”.

This removes the usage of “component-load.xml” to use ‘depends-on’
instead. The dependency declarations correspond to the total ordering
previously defined but will need to be refined in the future to relax
unnecessary dependency declarations.

Only “framework/base/config/component-load.xml” which defines the
top-level directories order (framework, applications, themes and
plugins) is kept.
2019-11-25 15:28:54 +01:00
Samuel Trégouët 889769593e Improved: Remove ‘ServiceEventHandler#checkSecureParameter’
(OFBIZ-11260)

There is no security reason justifying to prevent the invocation of
service event handlers with URI parameters if we accept request body
parameters.  As a consequence it is preferable to unconditionally
accept URI parameters and remove the
‘service.http.parameters.require.encrypted’ configuration property.
2019-11-04 22:52:16 +01:00
Samuel Trégouët f93b9ea29a Improved: Lint ‘ServiceEventHandler’ class
(OFBIZ-11260)
2019-11-04 22:50:14 +01:00
Jacques Le Roux 2af71198d4 Fixed: content/control/WebSiteCms?webSiteId=CmsSite fails
(OFBIZ-11266)

I did not notice that I unintentionally removed a line
while fixing OFBIZ-11259
2019-11-04 15:24:23 +01:00
Jacques Le Roux 34d30421dc Fixed: SOAPService does not work
(OFBIZ-11259)

This was broken by r1839451 committed at the bottom of OFBIZ-10438
A simple fix is to allow "webtools/control/SOAPService/serviceName?WSDL" scheme. 


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1869155 13f79535-47bb-0310-9956-ffa450edef68
2019-10-30 09:41:14 +00:00
Mathieu Lirzin bc2747dd67 Fixed: Fix javadoc build
(OFBIZ-11007)

This fixes the javadoc errors introduced in revision 1868963.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1869039 13f79535-47bb-0310-9956-ffa450edef68
2019-10-27 15:29:10 +00:00
Mathieu Lirzin 59efa181d2 Improved: Lint unit tests
This makes no behavioral changes, only coding style fixes.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1869037 13f79535-47bb-0310-9956-ffa450edef68
2019-10-27 12:51:08 +00:00
Mathieu Lirzin b1aaad3af6 Implemented: Handle URI templates in request maps
(OFBIZ-11007)

It is now possible to use segmented paths by using URI templates like
‘/foo/bar/{baz}’ in the ‘uri’ attribute of <request-map> elements.

Thanks: Artemiy Rozovyk for your contribution.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1868963 13f79535-47bb-0310-9956-ffa450edef68
2019-10-25 21:49:35 +00:00
Mathieu Lirzin b9d9f6144c Improved: Lint ‘ControlServlet’ partially
(OFBIZ-11007)


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1868962 13f79535-47bb-0310-9956-ffa450edef68
2019-10-25 21:43:02 +00:00
Mathieu Lirzin 4cc9ba8968 Fixed: Format ‘XmlRpcEventHandler’
(OFBIZ-10284)

This removes coding style errors introduced in revision 1868611.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1868621 13f79535-47bb-0310-9956-ffa450edef68
2019-10-19 13:20:01 +00:00
Jacques Le Roux 1ef831206d Improved: Handling tenant in XmlRpcEventHandler
(OFBIZ-10284)

The XMLRPC service does not support tenants. Even if the tenant domain is 
included in the HTTP request the call does not affect the correct tenant. 
The issue and fix has been discussed in  in the thread
https://markmail.org/message/bz4dofrxqp6i7ove

jleroux: I was able to port the R16 patch provided by Rajesh to the trunk. 

Thanks: Rajesh Kumar Mallah

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1868611 13f79535-47bb-0310-9956-ffa450edef68
2019-10-19 06:42:07 +00:00
Jacques Le Roux 0bd6bf919b Fixed: NotSerializableException after uploading images to an order
(OFBIZ-11123)

I found that using in r1866259 the same fix than Si Chen used in OFBIZ-750 was 
wrong. The code just above this fix is

{code:java}
if (obj instanceof Serializable) {
    reqAttrMap.put(name, obj);
}
{code}

The problem with this code is that if does not handle inner Maps which may 
contain a non Serializable Object. So the solution is rather to get one level
deeper and apply the same. We can then remove the harcoded lines with 
"uploadedFile" and "_REQUEST_HANDLER_" below. Then all possible cases are handled
as long as we have not inner-inner-Maps




git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1868298 13f79535-47bb-0310-9956-ffa450edef68
2019-10-11 16:45:16 +00:00
Jacques Le Roux abb30935e8 Improved: Unknown request [d.png]; this request does not exist or cannot be
called directly.
(OFBIZ-11199)

I suppose this issue is similar to OFBIZ-11152. So I'm handling it the same.
It's not an end to the underneath issue but at least it can reassure user about 
things being handled...

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1866855 13f79535-47bb-0310-9956-ffa450edef68
2019-09-12 15:36:38 +00:00
Jacques Le Roux 7d7a441715 Fixed: Any ecommerce user has the ability to reset anothers password
(including admin) via "Forget Your Password"
(OFBIZ-4361)

Currently, any user (via ecommerce "Forget Your Password") has the ability to 
reset another users password, including "admin" without permission.  
By simply entering "admin" and clicking "Email Password", the following is 
displayed:

The following occurred:
A new password has been created and sent to you. Please check your Email.

This now forces the user of the ERP to change their password.  
It is also possible to generate a dictionary attack against ofbiz because there 
is no capta code required.  This is serious security risk.

I have modified the patch following comments I made in the Jira, notably
  Removed unused Java variables
  Removed a check in LoginEvents::forgotPassword which prevented to show error
    messages
  Changed fr and en SecurityExtPasswordSentToYou 
    + SecurityExtThisEmailIsInResponseToYourRequestToHave labels 
    + template PasswordEmail.ftl
    + loginservices.token_incorrect labels
  Added fr and en SecurityExtIgnoreEmail + SecurityExtLinkOnce labels
  Removed changes in general.properties
  I did not remove the 2 GetSecurityQuestion.ftl files (webpos one was still in)

There is still room for improvement. I'll discuss them on the Jira and dev
ML. But this version is already strong enough to not wait that the patch is 
inapplicable!

Thanks: mz4wheeler (Mike Z) for the Jira, Nicolas Malin for the patch, I guess 
with some Gil's help, and all others for comments and ideas

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1866478 13f79535-47bb-0310-9956-ffa450edef68
2019-09-05 15:56:46 +00:00
Jacques Le Roux 899bc6f27d Fixed: NotSerializableException after uploading images to an order
(OFBIZ-11123)

In a lot of services we use the ByteBuffer object to upload files. 
When a such service is used with the redirect-parameter in a controller the 
ByteBuffer needs to be serialized. Unfortunately ByteBuffer (in our case its
subclass HeapByteBuffer) is not serializable. So that can't work.

Fortunately no redirect-parameter concerns uploadedFile so we can safely remove
it from reqAttrMap in RequestHandler

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1866259 13f79535-47bb-0310-9956-ffa450edef68
2019-09-02 07:32:48 +00:00
Jacques Le Roux 24ae8bed84 Improved: Unknown request [images]; this request does not exist or cannot be
called directly.
(OFBIZ-11152)

Gives an advice to reassure users about the seriousness of the issue

This issue can be easily reproduced by going to example/control/FormWidgetExamples
Other backend components are less concerned but it happens sometimes in them too.
It's quite hard to understand what's happening.
This is a sequel of OFBIZ-10895

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1866255 13f79535-47bb-0310-9956-ffa450edef68
2019-09-02 07:05:08 +00:00
Jacques Le Roux ed3e9c661b Improved: Give nested requests related with checkLogin a propper Error-Message
in log
(OFBIZ-11154)

An error appears in log due to the nested request that can not be resolved 
properly.  

We should not worry about nested requests, they continue to work, and we should 
simply not show an error message from RequestHandler in case of nested request.

Thanks: Initialy spotted by Benjamin Jugl in OFBIZ-9379

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1865902 13f79535-47bb-0310-9956-ffa450edef68
2019-08-26 05:58:44 +00:00
Mathieu Lirzin b50bc07bb9 Improved: Add missing override annotation
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1865846 13f79535-47bb-0310-9956-ffa450edef68
2019-08-24 12:59:03 +00:00
Mathieu Lirzin cf79277608 Improved: Remove redundant "dtd" directory from classpath
(OFBIZ-11161)

the "dtd" directories are already present as resources distributed
inside OFBiz jar, so there is no need to augment the classpath to find
the XML schema inside those directories.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1865796 13f79535-47bb-0310-9956-ffa450edef68
2019-08-24 00:29:41 +00:00
Jacques Le Roux 4250ca79db Improved: Add the component name in " Request Begun/Done" lines in log
(OFBIZ-11153)

It's sometimes useful to know from which component a request has been sent, 
eg to differentiate main requests, but not only.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1865685 13f79535-47bb-0310-9956-ffa450edef68
2019-08-22 14:18:27 +00:00
Nicolas Malin 4a511be1cc Implemented: Homogenize displaying number with multiple format
(OFBIZ-7532)

To display a number we had different possibilities :
 * on ftl use the template <@ofbizAmount and <@ofbizCurrency
 * by java call a function UtilFormatOut.formatAmount, UtilFormatOut.formatPrice, UtilFormatOut.formatQuantity, etc..
 * by form widget, use <display type=accounting-number for accounting but nothing for other

To simplify and homogenize all, I implemented a number type purpose :
   * default: display a number by default, use when no purpose is present
   * quantity: display a number as a quantity
   * amount: display a number as an amount (like price without currency)
   * spelled: litteral displaying for a number (use on <@ofbizAmount ftl only before)
   * percentage: display a number as a percentage
   * accounting: diplay a number for accounting specific

Each purpose can be associate to a number for displaying it :
   * on ftl <@ofbizNumber number=value format=purpose/>
   * on java UtilFormatOut.formatNumber(value, purpose, delegator, locale)
   * on form widget <display type=number format=purpose/>

The format use by a purpose is define on framework/common/config/number.properties with the template
    .displaying.format = ##0.00

With this, you can surchage a configuration, create your own purpose or surchage only one through entity SystemProperty.

Concerning the backware compatibility: 
 * For the ftl the template <@ofbizAmount is now a link to '<@ofbizNumber format=amount'
 * For java all previous function call UtilFormatOut.formatNumber with the matching purpose
 * For form xml accounting-number is managed as an exection

Last point, display a currency is different that a number, so I didn't refactoring some code for this case (only move properties from general to number for centralize de configuration on the same file)

Thanks Charles Steltzlen to start the refactoring

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1864832 13f79535-47bb-0310-9956-ffa450edef68
2019-08-09 20:37:11 +00:00
Mathieu Lirzin 2c2340db0a Improved: Use ‘java.util.Base64’
(OFBIZ-11142)

Since Java 8 a standard Base64 encoder/decoder is available. As a
consequence we can remove our embedded implementation and use it
instead.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1863504 13f79535-47bb-0310-9956-ffa450edef68
2019-07-20 18:39:57 +00:00
Mathieu Lirzin 54f210a866 Improved: Inline ‘UtilGenerics#checkCollection(Object)’
(OFBIZ-11141)


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1863502 13f79535-47bb-0310-9956-ffa450edef68
2019-07-20 16:36:12 +00:00
Mathieu Lirzin e9a56a78e5 Improved: Inline ‘UtilGenerics#checkList’
(OFBIZ-11141)


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1863501 13f79535-47bb-0310-9956-ffa450edef68
2019-07-20 16:35:13 +00:00
Mathieu Lirzin 83fd20607b Improved: Inline ‘UtilGenerics#checkMap’
(OFBIZ-11141)


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1863500 13f79535-47bb-0310-9956-ffa450edef68
2019-07-20 16:32:34 +00:00
Mathieu Lirzin 1720a2ff62 Improved: Refactor ‘UtilHttp#makeParamValueFromComposite’
(OFBIZ-11138)

Use ‘LocalDateTime’ instead of ‘Calendar’ and
‘HttpServletRequest#getParameterMap’ instead of
‘HttpServletRequest#getParameterNames’.

The tests and callers has been adapted to remove the ‘locale’ arguments which
made sense only for ‘Calendar’.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1863439 13f79535-47bb-0310-9956-ffa450edef68
2019-07-19 22:06:48 +00:00
Mathieu Lirzin e1d132a6b2 Improved: Use ‘HttpServletRequest#getParameterMap’ when possible
It is better to avoid using obsolete ‘Enumeration’ class when possible
so the calls to ‘HttpServletRequest#getParameterNames’ has been
replaced by ‘HttpServletRequest#getParameterMap’.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1863404 13f79535-47bb-0310-9956-ffa450edef68
2019-07-19 14:34:03 +00:00
Mathieu Lirzin abf0a9ac4b Improved: Use a predicate in ‘UtilHttp#getParameterMap’
(OFBIZ-11138)


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1863401 13f79535-47bb-0310-9956-ffa450edef68
2019-07-19 14:29:31 +00:00
Mathieu Lirzin a71766e929 Improved: Rewrite ‘loadHandlerMap’
(OFBIZ-10453)

This retrieves the attribute "class" instead of "className" which was
mistakenly used in revision 1862323.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1862343 13f79535-47bb-0310-9956-ffa450edef68
2019-06-30 12:12:31 +00:00
Mathieu Lirzin c51b0693fc Improved: Factorize collecting events defined in “controller.xml”
(OFBIZ-10453)


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1862342 13f79535-47bb-0310-9956-ffa450edef68
2019-06-30 12:08:53 +00:00
Jacques Le Roux 1519900ed5 Reverted: Mathieu's changes in ConfigXMLReader.java from yesterday
OFBiz was crashing 

Reverts rev. 1862324, 1862323, 1862322




git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1862333 13f79535-47bb-0310-9956-ffa450edef68
2019-06-30 08:38:58 +00:00
Mathieu Lirzin 946f6558f5 Fixed: Add missing import
(OFBIZ-10453)


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1862324 13f79535-47bb-0310-9956-ffa450edef68
2019-06-29 18:30:38 +00:00
Mathieu Lirzin 760ab05112 Improved: Rewrite ‘loadHandlerMap’
(OFBIZ-10453)


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1862323 13f79535-47bb-0310-9956-ffa450edef68
2019-06-29 18:10:36 +00:00
Mathieu Lirzin 6e3490d735 Improved: Factorize collecting events defined in “controller.xml”
(OFBIZ-10453)


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1862322 13f79535-47bb-0310-9956-ffa450edef68
2019-06-29 18:10:15 +00:00
Mathieu Lirzin 3fcf744748 Improved: Remove useless ‘null’ check in ‘EventFactory’
(OFBIZ-10911)


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1862321 13f79535-47bb-0310-9956-ffa450edef68
2019-06-29 18:09:21 +00:00
Mathieu Lirzin 4d7e598257 Improved: Refactor ‘trackStats’ and ‘trackVisit’
(OFBIZ-11130)

This Factorizes their implementation which was copy-pasted. The remaining
issue concerning the undesirable re-implementation of ‘resolveURI’ has been
explained in a comment.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1862315 13f79535-47bb-0310-9956-ffa450edef68
2019-06-29 15:13:30 +00:00
Jacques Le Roux 30a03b771f Improved: no functional change, just formating to check INFRA-18664
I can no longer find ofbiz-bot on Freenode because the good old qwebirc based 
webchat, was moving to a new Kiwi IRC based solution: https://freenode.net/


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1862311 13f79535-47bb-0310-9956-ffa450edef68
2019-06-29 14:19:03 +00:00
Mathieu Lirzin 2a24e0ecc1 Improved: Add ‘RequestHandler#from’ static method
(OFBIZ-11129)

Avoid some boiler-plate when retrieving the request handler inside a
servlet context.
--this line, and those below, will be ignored--

M    applications/content/src/main/java/org/apache/ofbiz/content/cms/CmsEvents.java
M    applications/order/src/main/java/org/apache/ofbiz/order/task/TaskEvents.java
M    applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/SeoTransform.java
M    applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/UrlRegexpTransform.java
M    applications/product/src/main/java/org/apache/ofbiz/product/product/ProductSearchSession.java
M    framework/webapp/src/main/java/org/apache/ofbiz/webapp/control/RequestHandler.java
M    framework/webapp/src/main/java/org/apache/ofbiz/webapp/event/CoreEvents.java
M    framework/webapp/src/main/java/org/apache/ofbiz/webapp/ftl/OfbizUrlTransform.java
M    framework/widget/src/main/java/org/apache/ofbiz/widget/model/IterateSectionWidget.java
M    framework/widget/src/main/java/org/apache/ofbiz/widget/renderer/html/HtmlTreeRenderer.java
M    framework/widget/src/main/java/org/apache/ofbiz/widget/renderer/macro/MacroFormRenderer.java
M    framework/widget/src/main/java/org/apache/ofbiz/widget/renderer/macro/MacroMenuRenderer.java
M    framework/widget/src/main/java/org/apache/ofbiz/widget/renderer/macro/MacroScreenRenderer.java
M    framework/widget/src/main/java/org/apache/ofbiz/widget/renderer/macro/MacroTreeRenderer.java


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1862295 13f79535-47bb-0310-9956-ffa450edef68
2019-06-28 23:04:54 +00:00
Mathieu Lirzin 21135cb104 Improved: Use ‘ServletRequest#getServletContext’ when possible
(OFBIZ-11129)

Avoid unecessary casts by using ‘ServletRequest#getServletContext’
instead of ‘ServletRequest#getAttribute’. This method is available
since Servlet specification 3.0.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1862294 13f79535-47bb-0310-9956-ffa450edef68
2019-06-28 23:04:03 +00:00
Mathieu Lirzin ffe2e7ffdf Improved: Add missing ‘static’ modifier for private methods
(OFBIZ-11098)

In order to make it clear when a method is not depending on the
internal state of an object, it is a good practice to declare it as
static.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1860937 13f79535-47bb-0310-9956-ffa450edef68
2019-06-10 12:27:40 +00:00
Jacques Le Roux 402db94e61 Fixed: Duplicate entries in paramWithSuffix
(OFBIZ-11056)

when using string-list-suffix attribute for service definition, invoke method 
(from associated event handler) will try to parse parameters from both request 
variable and rawParameterMap which was also built from request. 
So we end up with duplicates in resulting list.

This behaviour seems to be introduced with OFBIZ-5048.


Thanks: Samuel Trégouët for report and fix 

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1859972 13f79535-47bb-0310-9956-ffa450edef68
2019-05-25 14:08:48 +00:00
Jacques Le Roux 69587ffec2 Fixed: Replace request-redirect w/ no redirect-param attribute by
request-redirect-noparam
(OFBIZ-9997)

Reverts all the rest from r1816180, and, after reading carefully the code used 
for "request-redirect" in RequestHandler (and downward), fixes the documentation 
in site-conf.xsd


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1859800 13f79535-47bb-0310-9956-ffa450edef68
2019-05-23 16:36:37 +00:00
Mathieu Lirzin b37e315aef Improved: Use the ‘@Override’ annotation
(OFBIZ-10939)

The ‘@Override’ annotation helps readers understand that the method at
hand is overriding a super class or implementing an interface.
Additionally it allows the compiler to check if the methods annotated
with ‘@Override’ are actually implementing an abstract method.

Using that annotation makes ‘@see foo.bar.ParentClass#myMethod’
comments useless, so those they have been removed for the newly
annotated methods.

Thanks Jacques Le Roux and Swapnil M Mane for acknowledging the commit.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1858295 13f79535-47bb-0310-9956-ffa450edef68
2019-04-27 19:34:25 +00:00
Jacques Le Roux 010083250f Reverted: Unknown request [images]; this request does not exist or cannot be
called directly.
(OFBIZ-10895)

Partially revert r1858094, just replaces "rmaps == null" by "rmaps.isEmpty()"

As Mathieu mentioned in dev:
<<Checking for ‘null’ here is not a solution since ‘resolveURI’ contract
it to return a non-nullable collection.
This commit is only bypassing the error handling.>>

As I said in r1858094:
<<This has been somehow broken by OFBIZ-10438 but actually it was already broken 
before but not for the same reason.>>

We need now to review/check how it worked in R15 where it's OK, and possibly 
implements the same

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1858180 13f79535-47bb-0310-9956-ffa450edef68
2019-04-26 08:33:30 +00:00
Jacques Le Roux 8ef84cff72 Fixed: Unknown request [images]; this request does not exist or cannot be called
directly.
(OFBIZ-10895)

This has been somehow broken by OFBIZ-10438 but actually it was already broken 
before but not for the same reason. Finally r1838081 (for OFBIZ-10438) allows to 
easy fix it when in previous versions (pre R18) it would need another fix. 
Since it's only annoying text in log I'll let users search the solution for 
pre R18 versions and will fix it only for trunk and R18.

Replaces rmaps.isEmpty() by rmaps == null as it was before R16 (R15 has not this
issue)
Also includes Eclipse automated imports sorting


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1858092 13f79535-47bb-0310-9956-ffa450edef68
2019-04-25 08:25:30 +00:00
Gil Portenseigne 9cec8c6443 Fixed: User depersonation do not clean out impersonated user session.
(OFBIZ-10942)

Thank you Leila Mekika for reporting and providing the patch.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1857991 13f79535-47bb-0310-9956-ffa450edef68
2019-04-23 07:31:10 +00:00
Mathieu Lirzin 3b6782981f Fixed: Remove unnecessary declared exceptions in ‘RequestHandlerTests’
(OFBIZ-10938)


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1857912 13f79535-47bb-0310-9956-ffa450edef68
2019-04-21 13:58:46 +00:00
Mathieu Lirzin 990c8a3aab Improved: Remove redundant specification of type arguments
(OFBIZ-10937)

Since Java 1.7, when defining generic types it is unnecessary to
redefine those types in the constructor when it is done in the
declared type.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1857906 13f79535-47bb-0310-9956-ffa450edef68
2019-04-21 12:49:52 +00:00
Mathieu Lirzin d5e3c2d3d4 Improved: Remove redundant null checks (OFBIZ-10911)
Redundant null checks detected by Eclipse has been removed.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1857896 13f79535-47bb-0310-9956-ffa450edef68
2019-04-21 09:37:49 +00:00
Jacques Le Roux f85a480f01 Improved: Using try-with-resources with File IO Objects.
(OFBIZ-9855)

Uses try with resources for File IO objects like ObjectInputStream and other 
objects. File classes have the AutoCloseable interface.

jleroux: this is only a part of the 2nd patch. The 1st patch will be committed
soon too...

All tests pass

Thanks: Pradhan Yash Sharma

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1857099 13f79535-47bb-0310-9956-ffa450edef68
2019-04-08 09:17:55 +00:00