Opened 3 years ago

Last modified 3 years ago

#4526 new defect

Cassandra: lease expiration implementation is sub-optimal

Reported by: tomek Owned by:
Priority: medium Milestone: Outstanding Tasks
Component: database-all Version: git
Keywords: cassandra Cc:
CVSS Scoring: Parent Tickets:
Sensitive: no Defect Severity: N/A
Sub-Project: DHCP Feature Depending on Ticket:
Estimated Difficulty: 0 Add Hours to Ticket: 0
Total Hours: 0 Internal?: no


When there are expired leases to be deleted, the code does the following (pseudo code):

deleteExpiredReclaimedLeases{4,6} calls DELETE_LEASE{4,6}_STATE_EXPIRED, which does not delete anything, but rather returns a list of leases. Then for each lease returned there's a separate deleteLease call.

On the other hand, MySQL and PostgreSQL backends do the expriation with one call.

There may be some limitations on what Cassandra can and cannot do. If we can, the code should be improved to do the work in single query. If this is not possible, the code should be extended with appropriate comment that explains the details.


Change History (2)

comment:1 Changed 3 years ago by tomek

  • Keywords cassandra added

comment:2 Changed 3 years ago by hschempf

  • Milestone changed from Kea-proposed to Outstanding Tasks

Per June 23 team meeting, move to Outstanding. Tomek will communicate w/ DT (Razvan) to explain that this ticket was created, and say that we've opted not to work on it until after 1.1.

Note: See TracTickets for help on using tickets.