Bug 1023434

Summary: KPIs with dates not displaying on Oracle DB
Product: [Retired] JBoss BPMS Platform 6 Reporter: Jan Hrcek <jhrcek>
Component: BAMAssignee: David Gutierrez <dgutierr>
Status: CLOSED CURRENTRELEASE QA Contact: Jan Hrcek <jhrcek>
Severity: medium Docs Contact:
Priority: high    
Version: 6.0.0CC: pzapataf
Target Milestone: ER5   
Target Release: 6.0.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-08-06 20:07:15 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Error in KPI panel
none
Server log with UNEXPECTED ERROR none

Description Jan Hrcek 2013-10-25 12:04:11 UTC
Created attachment 816125 [details]
Error in KPI panel

Description of problem:
When you use Oracle 11g R2 as underlying datasource and in business central you navigate to built-in jBPM Dashboard, the KPIs containing date-based data are not displayed. Instead these panels have error dislayed "An unexpected error occured which has generated the follogin error log" (se screenshot attached).
The following KPIs are concerned:
-process completed / initiated by date
-tasks completed / started by date

The underlying exception in all these cases is same:
java.lang.ClassCastException: oracle.sql.TIMESTAMP cannot be cast to java.lang.Comparable



Version-Release number of selected component (if applicable):
BPMS 6.0.0 ER4
Oracle 11g R2
Firefox 17


How reproducible:
Always


Steps to Reproduce:
1. Deploy BPMS (business-central + jbpm-dashboard webapps) on EAP 6.1 with Oracle 11g R2 as an underlying datasource
2. start some processes to fill in underlying datasource with some process/task data
3. go to jbpm dashboard and check KPIs mentioned above

Actual results:
Error is displayed as mentioned above

Expected results:
KPIs should be displayed correctly

Comment 1 Jan Hrcek 2013-10-25 12:05:44 UTC
Created attachment 816127 [details]
Server log with UNEXPECTED ERROR

Comment 2 David Gutierrez 2013-11-06 10:38:57 UTC
Fixed. TIMESTAMP columns in Oracle are fetched as instances of the class oracle.sql.TIMESTAMP. This class is not suitable for dashbuilder as it does not implement java.lang.Comparable. We have added a transformation method to get the real java.util.Date instance instead of the proprietary one.

Github commit (master): https://github.com/droolsjbpm/dashboard-builder/commit/92516607a56b4cf1802d230b7a21d8a3d630bd3a

Github commit (6.0.x): https://github.com/droolsjbpm/dashboard-builder/commit/babec2e156a387e4ef5a801e3341c044e40dcd76

Comment 3 Jan Hrcek 2013-11-29 13:41:49 UTC
This issue can't be verified with BPMS 6.0.0 ER5, because it is blocked by BZ 1035114. We are currently unable to deploy dashbuilder on oracle11gR2 to test it.

Comment 4 Jan Hrcek 2013-12-23 07:03:43 UTC
Ok, verified with BPMS 6.0.0 ER6 deployed on EAP 6.1.1