Bug 1017707 - 6 hour and 24 hour metrics expire too soon
Summary: 6 hour and 24 hour metrics expire too soon
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: RHQ Project
Classification: Other
Component: Monitoring
Version: 4.9
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
: RHQ 4.10
Assignee: John Sanda
QA Contact: Mike Foley
URL:
Whiteboard:
Depends On:
Blocks: 951619 1017710
TreeView+ depends on / blocked
 
Reported: 2013-10-10 11:19 UTC by John Sanda
Modified: 2014-04-23 12:31 UTC (History)
2 users (show)

Fixed In Version:
Clone Of:
: 1017710 (view as bug list)
Environment:
Last Closed: 2014-04-23 12:31:25 UTC
Embargoed:


Attachments (Terms of Use)
diff.png (163.30 KB, image/png)
2013-10-11 10:29 UTC, Armine Hovsepyan
no flags Details

Description John Sanda 2013-10-10 11:19:47 UTC
Description of problem:
We use Cassandra's time to live (TTL) feature to let metric data age out automatically without having to explicitly delete it. Both 6 hour and 24 hour data are getting stored with the 1 hour data TTLs. Here are the prepared statements used to store the respective data,

insertSixHourData = storageSession.prepare("INSERT INTO " + MetricsTable.SIX_HOUR + "(schedule_id, time, " +
            "type, value) VALUES (?, ?, ?, ?) USING TTL " + configuration.getOneHourTTL());

insertTwentyFourHourData = storageSession.prepare("INSERT INTO " + MetricsTable.TWENTY_FOUR_HOUR + "(schedule_id, " +
            "time, type, value) VALUES (?, ?, ?, ?) USING TTL " + configuration.getOneHourTTL());


They are both using configuration.getOneHourTTL(), but it should be configuration.getSixHourTTL() and configuration.getTwentyFourHourTTL() respectively.

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


How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 John Sanda 2013-10-10 11:25:47 UTC
Fix pushed to master.

commit hash: c115ca0dc5d1

Comment 2 John Sanda 2013-10-10 13:33:57 UTC
Previous commit missed the the 6 hour ttl. It has been fixed and committed to master.

commit hash: fc05a8514

Comment 3 Armine Hovsepyan 2013-10-11 10:27:14 UTC
verified the mehtod in of source diff. . 
please get attached the screen-shot

Comment 4 Armine Hovsepyan 2013-10-11 10:29:06 UTC
Created attachment 810973 [details]
diff.png

Comment 5 Heiko W. Rupp 2014-04-23 12:31:25 UTC
Bulk closing of 4.10 issues.

If an issue is not solved for you, please open a new BZ (or clone the existing one) with a version designator of 4.10.


Note You need to log in before you can comment on or make changes to this bug.