Bug 588507

Summary: WAR file deployed against Tomcat shows an incorrect installation date.
Product: [Other] RHQ Project Reporter: Corey Welton <cwelton>
Component: PluginsAssignee: Jirka Kremser <jkremser>
Status: CLOSED CURRENTRELEASE QA Contact: Mike Foley <mfoley>
Severity: medium Docs Contact:
Priority: low    
Version: 4.4CC: ahovsepy, jkremser, mazz, mharvey, spinder
Target Milestone: ---   
Target Release: RHQ 4.5.0   
Hardware: All   
OS: Windows   
See Also: https://bugzilla.redhat.com/show_bug.cgi?id=564539
https://bugzilla.redhat.com/show_bug.cgi?id=589173
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-08-31 06:14:59 EDT Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
Bug Depends On:    
Bug Blocks: 683054, 577051, 586123, 625146    
Attachments:
Description Flags
deploy content none

Description Corey Welton 2010-05-03 16:24:40 EDT
Description of problem:
Adter deploying a .war file, the installation date seems way off

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.  Inventory an EWS server and assure is has gone green.
2.  Navigate to your virtual host within the tree, and deploy something, i.e., counter.war
3.  Navigate to your war resource in the tree (i.e., counter/) and click the Content tab
4. View resulting table

 
Actual results:
I have an installation date of "14732 days, 20 hours ago"

Expected results:

* It probably shouldn't read "Installation Date" if it is a "how long ago" sort of measurement
* The installation time measure is way, way off.  Maybe this is package create date?

Additional info:
Comment 1 Simeon Pinder 2010-06-10 11:18:35 EDT
I've run into this problem and looked into it as well and it turns out that the Content -> Deployed Content list uses InstallledPackage.installationDate, while the actual Package Version(fixed in 589173) uses the PackageVersion.fileCreationTime.  

These appear to serve the same purpose but exist on two different objects and tables. Not completely sure why.

Proposed fix, change named query InstalledPackage.QUERY_FIND_PACKAGE_LIST_ITEM_COMPOSITE to use the PackageVersion details.

As a result of BZ 589173, almost all packages(excluding webapps deployed exploded before rhq) now have the fileCreated date set if it's obtainable.

Queries of rhq_package_version show almost full population of timestamp, excluding case above, while queries of rhq_installed_package are almost devoid of timestamp information.

This should fix many places in the code where timestamp simply displays epoch/computer zero time.
Comment 2 Paul Nittel 2011-01-13 17:17:30 EST
This bug also manifests itself when EDS VDBs are deployed to a server. We're seeing 14987 days 22 hours, and the like.
Comment 3 Charles Crouch 2012-02-07 10:30:31 EST
Speaking to Stefan, this is no related to his content fixes, so unassigning from that tracker BZ
Comment 4 Charles Crouch 2012-02-07 10:31:15 EST
Reassigning to jon3.1.0. It would be good to fix, as per its priority
Comment 6 Jirka Kremser 2012-06-19 16:34:54 EDT
http://git.fedorahosted.org/git/?p=rhq/rhq.git;a=commitdiff;h=f2ab06c

git log master
time:    Tue Jun 19 10:50:45 2012 +0200
commit:  f2ab06c2f62a77655d37ddcdce82eb16fe06fd91
author:  Jirka Kremser - jkremser@redhat.com
message: [BZ 588507 - WAR file deployed against Tomcat shows an incorrect installation date] Instalation date is now taken from InstalledPackage instance instead of PackageVersion instance
Comment 7 Armine Hovsepyan 2012-08-01 05:05:57 EDT
Created attachment 601691 [details]
deploy content

verified.

installation date under TomcatVirtualHost->localhost->deployedWar->Content is set correct.
Comment 8 Heiko W. Rupp 2013-08-31 06:14:59 EDT
Bulk close of old bugs in VERIFIED state.