Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0038671
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] A. Platformminorrandom2018-05-31 13:402019-09-27 15:08
ReporterALopeteguiView Statuspublic 
Assigned Toalostale 
PrioritynoneResolutionfixedFixed in Version3.0PR19Q4
StatusclosedFix in branchFixed in SCM revision734a9b482068
ProjectionnoneETAnoneTarget Version
OS@0@DatabaseAnyJava version
OS VersionDatabase versionAnt version
Product Version3.0PR17Q2SCM revision 
Review Assigned Tocaristu
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0038671: random NPE getting data for some date/datetime fields

DescriptionNull Pointer getting data for several columns in FormInitializationComponent

There are Several colums getting nullPointer exception:

Created
DateAcct
DateInvoiced
Dateordered
DateOrdered
DatePromised
EM_OBBUTF_Agio
EM_OBBUTF_CommissionAmt
EM_OBBUTF_ComPercentage
EM_Obbutf_Finalamount
EM_OBBUTF_FirstPaymentDate
EM_OBBUTF_FundedAmount
EM_OBPOS_App_Cashup_ID
em_poss_businessdate
End_Date
End_Time
Documentdate
DueDate
EM_OBBUTF_FirstPaymentDate
Paymentdate
Statementdate
Status
Taxdate
......
Steps To ReproduceAttached some logs
TagsNo tags attached.
Attached Filestxt file icon issue152.txt [^] (47,146 bytes) 2018-05-31 13:40 [Show Content]
? file icon Openbravo.properties [^] (7,393 bytes) 2018-06-19 14:01
txt file icon 38671_log.txt [^] (22,556 bytes) 2018-09-11 11:11 [Show Content]

- Relationships Relation Graph ] Dependency Graph ]
causes defect 0044640 closedcberner Exported grid csv with enabled creation date column value does not match in the application 
causes defect 0044574 closedcberner The date is not displayed correctly in the "Costing Rules" window -> "Fix Backdated Transactions" process 

-  Notes
(0104910)
ALopetegui (reporter)
2018-06-04 12:06

There is another similar log repeating with several colums.
The difference is Couldn't get the value for colum instead of Couldn't get data for column

cdb72c84 2018-06-02 14:23:43,518 [ajp-nio-127.0.0.1-8009-exec-1] ERROR org.openbravo.client.application.window.FormInitializationComponent - Couldn't get the value for column Created
java.lang.NullPointerException
        at org.openbravo.client.kernel.reference.DateTimeUIDefinition.getClassicFormat(DateTimeUIDefinition.java:84)
        at org.openbravo.client.kernel.reference.DateTimeUIDefinition.convertLocalDateTimeToUTC(DateTimeUIDefinition.java:76)
        at org.openbravo.client.kernel.reference.DateTimeUIDefinition.convertToClassicString(DateTimeUIDefinition.java:63)
        at org.openbravo.client.application.window.FormInitializationComponent.setValueOfColumnInRequest(FormInitializationComponent.java:1317)
        at org.openbravo.client.application.window.FormInitializationComponent.setValuesInRequest(FormInitializationComponent.java:1026)
        at org.openbravo.client.application.window.FormInitializationComponent.execute(FormInitializationComponent.java:255)
        at org.openbravo.client.kernel.BaseActionHandler.execute(BaseActionHandler.java:73)
        at org.openbravo.client.kernel.KernelServlet.processActionRequest(KernelServlet.java:314)
        at org.openbravo.client.kernel.KernelServlet.doGet(KernelServlet.java:206)
        at org.openbravo.client.kernel.KernelServlet.doPost(KernelServlet.java:287)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:648)
        at org.openbravo.base.HttpBaseServlet.serviceInitialized(HttpBaseServlet.java:228)
        at org.openbravo.base.secureApp.HttpSecureAppServlet.service(HttpSecureAppServlet.java:461)
        at org.openbravo.client.kernel.BaseKernelServlet.callServiceInSuper(BaseKernelServlet.java:87)
        at org.openbravo.client.kernel.BaseKernelServlet.service(BaseKernelServlet.java:58)
        at org.openbravo.client.kernel.KernelServlet.service(KernelServlet.java:168)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:292)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)
        at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:240)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)
        at org.openbravo.utils.SessionExpirationFilter.doFilter(SessionExpirationFilter.java:66)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:240)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)
        at org.openbravo.utils.CharsetFilter.doFilter(CharsetFilter.java:35)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:240)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)
        at org.openbravo.client.kernel.KernelFilter$1.doAction(KernelFilter.java:62)
        at org.openbravo.dal.core.ThreadHandler.run(ThreadHandler.java:46)
        at org.openbravo.client.kernel.KernelFilter.doFilter(KernelFilter.java:71)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:240)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)
        at org.openbravo.dal.core.DalRequestFilter$1.doAction(DalRequestFilter.java:81)
        at org.openbravo.dal.core.ThreadHandler.run(ThreadHandler.java:46)
        at org.openbravo.dal.core.DalRequestFilter.doFilter(DalRequestFilter.java:103)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:240)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:207)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:212)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:94)
        at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:504)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:141)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:88)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:509)
        at org.apache.coyote.ajp.AbstractAjpProcessor.process(AbstractAjpProcessor.java:877)
        at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:684)
        at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1524)
        at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1480)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
        at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
        at java.lang.Thread.run(Thread.java:745)
(0104914)
alostale (developer)
2018-06-04 13:45

Are date/time formats correctly configured in that instance [1]?

[1] http://wiki.openbravo.com/wiki/Openbravo.properties#Date.2Ftime_format [^]
(0104927)
ALopetegui (reporter)
2018-06-04 19:29

Yes, I think date/time are correctly configured in its four nodes, it has a load balancer and 4 nodes.

I all nodes:

####################
# Date/time format #
####################

dateFormat.js=%d-%m-%Y
dateFormat.sql=DD-MM-YYYY
dateFormat.java=dd-MM-yyyy
dateTimeFormat.java=dd-MM-yyyy HH:mm:ss
dateTimeFormat.sql=DD-MM-YYYY HH24:MI:SS
(0105176)
alostale (developer)
2018-06-15 11:27

Check how those values get into session:
1. Log in as System Admin
2. Open Session Variables window
3. Look for value of #AD_JAVADATETIMEFORMAT object

It also might be useful to provide full Openbravo.properties to try to reproduce
(0105212)
ALopetegui (reporter)
2018-06-19 10:03
edited on: 2018-06-19 10:07

AD_JAVADATETIMEFORMAT
value: dd-MM-yyyy HH:mm:ss
Preference: NO
Global: Yes
Acounting:NO


Attached Openbravo.porperties file

(0105659)
hgbot (developer)
2018-07-06 13:00

Repository: erp/devel/pi
Changeset: 8cdf0c74bec6775d7ff27e873b5840fa7895c561
Author: Asier Lostalé <asier.lostale <at> openbravo.com>
Date: Fri Jul 06 12:52:33 2018 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/8cdf0c74bec6775d7ff27e873b5840fa7895c561 [^]

related with issue 38671: removed unused parameter

  field param in FIC.setValueOfColumnInRequest was always null, so no need to
  have it.

---
M modules/org.openbravo.client.application/src/org/openbravo/client/application/window/FormInitializationComponent.java
---
(0105660)
hgbot (developer)
2018-07-06 13:00

Repository: erp/devel/pi
Changeset: eed99aa47f9b71d8a986718db28ce3ecf76af2e7
Author: Asier Lostalé <asier.lostale <at> openbravo.com>
Date: Fri Jul 06 12:59:08 2018 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/eed99aa47f9b71d8a986718db28ce3ecf76af2e7 [^]

related to bug 38671: added context information to log in case of failure

---
M modules/org.openbravo.client.application/src/org/openbravo/client/application/window/FormInitializationComponent.java
---
(0105663)
alostale (developer)
2018-07-06 13:24

I cannot reproduce this issue with provided properties.

Please apply changesets associated with this issue in order to add more context information to logs when error occurs, in this way we'll be able to understand where the problem is actually happening.
(0106207)
hudsonbot (developer)
2018-08-08 13:06

A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/bfd7a414183a [^]
Maturity status: Test
(0106208)
hudsonbot (developer)
2018-08-08 13:06

A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/bfd7a414183a [^]
Maturity status: Test
(0106680)
ALopetegui (reporter)
2018-09-11 11:10
edited on: 2018-09-11 11:14

Recomended changesets are already applied in production. I attach the log of those errors. 38671_log.txt
There is 3 type of errors related to the issue.

with new log, can we know what the problem is?

(0114743)
hgbot (developer)
2019-09-24 08:32

Repository: erp/devel/pi
Changeset: 734a9b482068f14842bf1d880690d28c8f1e6baf
Author: Asier Lostalé <asier.lostale <at> openbravo.com>
Date: Mon Sep 23 09:58:51 2019 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/734a9b482068f14842bf1d880690d28c8f1e6baf [^]

fixed bug 38671: NPE in FIC getting values for date fields

  When FIC tries to get values for date columns a NPE was trhown in case date
  format was not present in session (?).

  Data format is set in session from Openbravo.properties, so it never changes
  there is no need to retrieve it from session.

---
M modules/org.openbravo.client.kernel/src/org/openbravo/client/kernel/reference/AbsoluteDateTimeUIDefinition.java
M modules/org.openbravo.client.kernel/src/org/openbravo/client/kernel/reference/DateTimeUIDefinition.java
M modules/org.openbravo.client.kernel/src/org/openbravo/client/kernel/reference/DateUIDefinition.java
---
(0114744)
hgbot (developer)
2019-09-24 08:32

Repository: erp/devel/pi
Changeset: c034c6516fc5281da6a28021a1e1b10347683e3d
Author: Asier Lostalé <asier.lostale <at> openbravo.com>
Date: Mon Sep 23 10:02:09 2019 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/c034c6516fc5281da6a28021a1e1b10347683e3d [^]

related to bug 38671: added proper synchronization

  SimpleDateFormat is not threadsafe, it needs to be synchronized for formatting.

---
M modules/org.openbravo.client.kernel/src/org/openbravo/client/kernel/reference/DateTimeUIDefinition.java
---
(0114745)
hgbot (developer)
2019-09-24 08:32

Repository: erp/devel/pi
Changeset: 930f389bdcbf91cc746c9519911d4dc15c18b177
Author: Asier Lostalé <asier.lostale <at> openbravo.com>
Date: Mon Sep 23 11:45:02 2019 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/930f389bdcbf91cc746c9519911d4dc15c18b177 [^]

related to bug 38671: use format in Openbravo.properties in other places

  There were other places that created a SimpleDateFormat directly from format
  stored in session. They have been replaced to use the same mechanism defined
  in DateUIDefinition.

---
M modules/org.openbravo.client.application/src/org/openbravo/client/application/OBBindings.java
M modules/org.openbravo.client.kernel/src/org/openbravo/client/kernel/reference/DateUIDefinition.java
M modules/org.openbravo.client.kernel/src/org/openbravo/client/kernel/reference/UIDefinitionController.java
M modules/org.openbravo.service.datasource/src/org/openbravo/service/datasource/DataSourceServlet.java
M modules/org.openbravo.userinterface.selector/src/org/openbravo/userinterface/selector/SelectorDataSourceFilter.java
---
(0114760)
hudsonbot (developer)
2019-09-24 14:56

A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/fab39d1f8dc5 [^]
Maturity status: Test
(0114761)
hudsonbot (developer)
2019-09-24 14:56

A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/fab39d1f8dc5 [^]
Maturity status: Test
(0114762)
hudsonbot (developer)
2019-09-24 14:56

A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/fab39d1f8dc5 [^]
Maturity status: Test
(0114847)
caristu (developer)
2019-09-27 15:08

Reviewed

- Issue History
Date Modified Username Field Change
2018-05-31 13:40 ALopetegui New Issue
2018-05-31 13:40 ALopetegui Assigned To => platform
2018-05-31 13:40 ALopetegui File Added: issue152.txt
2018-05-31 13:40 ALopetegui Modules => Core
2018-05-31 13:40 ALopetegui Triggers an Emergency Pack => No
2018-05-31 13:51 ALopetegui Description Updated View Revisions
2018-05-31 13:51 ALopetegui Steps to Reproduce Updated View Revisions
2018-06-04 12:06 ALopetegui Note Added: 0104910
2018-06-04 13:45 alostale Note Added: 0104914
2018-06-04 13:45 alostale Assigned To platform => ALopetegui
2018-06-04 13:45 alostale Status new => feedback
2018-06-04 19:29 ALopetegui Note Added: 0104927
2018-06-08 11:41 ALopetegui Assigned To ALopetegui => platform
2018-06-08 11:41 ALopetegui Status feedback => new
2018-06-15 11:27 alostale Note Added: 0105176
2018-06-15 11:27 alostale Status new => feedback
2018-06-15 11:27 alostale Assigned To platform => ALopetegui
2018-06-19 10:03 ALopetegui Note Added: 0105212
2018-06-19 10:05 ALopetegui File Added: Openbravo.properties
2018-06-19 10:07 ALopetegui Assigned To ALopetegui => alostale
2018-06-19 10:07 ALopetegui Status feedback => new
2018-06-19 10:07 ALopetegui Note Edited: 0105212 View Revisions
2018-06-19 13:21 alostale File Deleted: Openbravo.properties
2018-06-19 14:01 ALopetegui File Added: Openbravo.properties
2018-07-06 13:00 hgbot Checkin
2018-07-06 13:00 hgbot Note Added: 0105659
2018-07-06 13:00 hgbot Checkin
2018-07-06 13:00 hgbot Note Added: 0105660
2018-07-06 13:24 alostale Note Added: 0105663
2018-07-06 13:24 alostale Assigned To alostale => ALopetegui
2018-07-06 13:24 alostale Status new => feedback
2018-08-08 13:06 hudsonbot Checkin
2018-08-08 13:06 hudsonbot Note Added: 0106207
2018-08-08 13:06 hudsonbot Checkin
2018-08-08 13:06 hudsonbot Note Added: 0106208
2018-09-11 11:10 ALopetegui Note Added: 0106680
2018-09-11 11:11 ALopetegui File Added: 38671_log.txt
2018-09-11 11:13 ALopetegui Assigned To ALopetegui => hudsonbot
2018-09-11 11:14 ALopetegui Note Edited: 0106680 View Revisions
2019-09-23 11:48 alostale Assigned To hudsonbot => alostale
2019-09-23 11:48 alostale Status feedback => new
2019-09-23 11:48 alostale Severity major => minor
2019-09-23 11:49 alostale Reproducibility have not tried => random
2019-09-23 11:49 alostale OS 5 =>
2019-09-23 11:49 alostale Summary Null Pointer getting data for several columns in FormInitializationComponent => random NPE getting data for some date/datetime fields
2019-09-24 08:32 hgbot Checkin
2019-09-24 08:32 hgbot Note Added: 0114743
2019-09-24 08:32 hgbot Status new => resolved
2019-09-24 08:32 hgbot Resolution open => fixed
2019-09-24 08:32 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/734a9b482068f14842bf1d880690d28c8f1e6baf [^]
2019-09-24 08:32 hgbot Checkin
2019-09-24 08:32 hgbot Note Added: 0114744
2019-09-24 08:32 hgbot Checkin
2019-09-24 08:32 hgbot Note Added: 0114745
2019-09-24 08:33 alostale Review Assigned To => caristu
2019-09-24 08:33 alostale OS 0 =>
2019-09-24 14:56 hudsonbot Checkin
2019-09-24 14:56 hudsonbot Note Added: 0114760
2019-09-24 14:56 hudsonbot Checkin
2019-09-24 14:56 hudsonbot Note Added: 0114761
2019-09-24 14:56 hudsonbot Checkin
2019-09-24 14:56 hudsonbot Note Added: 0114762
2019-09-27 15:08 caristu Note Added: 0114847
2019-09-27 15:08 caristu Status resolved => closed
2019-09-27 15:08 caristu Fixed in Version => 3.0PR19Q4
2020-07-27 07:14 alostale Relationship added causes 0044640
2020-07-27 12:03 alostale Relationship added causes 0044574


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker