Project

General

Profile

Actions

Task #1159

closed

Faster delete of logging events

Added by Alena Peterová about 4 years ago. Updated about 4 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Ondřej Kopr
Category:
Logging
Target version:
Start date:
06/28/2018
Due date:
% Done:

90%

Estimated time:

Description

Version 8.1.2
I have millions of logging events and a slow environment. I tried to delete logs by RemoveOldLogsTaskExecutor, but it was too slow (around 100 of events per second).

Could you please provide some faster delete of logging events, which deletes all events and doesn't have to retrieve it from the database first?
(Consulted with Zdeněk - the application should delete logs by some direct SQL query, not one by one in Java)

Actions #1

Updated by Alena Peterová about 4 years ago

  • Description updated (diff)
Actions #2

Updated by Ondřej Kopr about 4 years ago

  • Assignee changed from Radek Tomiška to Ondřej Kopr
Actions #4

Updated by Ondřej Kopr about 4 years ago

  • Status changed from New to Needs feedback
  • Assignee changed from Ondřej Kopr to Alena Peterová
  • Target version set to Lapis (8.2.0)
  • % Done changed from 0 to 90

I update behavior for remove old logs. Now is removing much faster than before. I'm little bit fighting with creating test for this feature, because logback db appender doesn't support h2 connection.

commit: https://github.com/bcvsolutions/CzechIdMng/commit/88159c78dcbc6741b399f7ac0d9b2db673930490 (branch: okopr/1159-update-remove-logs)

In commit exists also flyway script before merge is necessary check last script in develop branch.

Please Alca could you made a review? Thank you :)

Actions #5

Updated by Ondřej Kopr about 4 years ago

  • Assignee changed from Alena Peterová to Radek Tomiška
Actions #6

Updated by Vít Švanda about 4 years ago

  • Assignee changed from Radek Tomiška to Vít Švanda
Actions #7

Updated by Vít Švanda about 4 years ago

I did review and test:

  • Delete of 4500000 logs takes about 2 mins now.

Thanks for that

Actions #8

Updated by Vít Švanda about 4 years ago

  • Status changed from Needs feedback to Resolved
  • Assignee changed from Vít Švanda to Ondřej Kopr
Actions #9

Updated by Radek Tomiška about 4 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF