Skip to content

enhance: Remove docker acquis internal timer use docker events #3598

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 13 commits into
base: master
Choose a base branch
from

Conversation

LaurenceJJones
Copy link
Contributor

Instead of polling the api every one second, we can instead use the events hook in docker this is a continuous event stream that notify us of a container event. We filter for start and die which is crate and remove, to which we then trigger a function call to get all containers and update the state.

This means this should be less intensive since we dont have to constantly poll for all containers and only do so when we actually get a notification to do so.

Copy link

@LaurenceJJones: There are no 'kind' label on this PR. You need a 'kind' label to generate the release automatically.

  • /kind feature
  • /kind enhancement
  • /kind refactoring
  • /kind fix
  • /kind chore
  • /kind dependencies
Details

I am a bot created to help the crowdsecurity developers manage community feedback and contributions. You can check out my manifest file to understand my behavior and what I can do. If you want to use this for your project, you can check out the BirthdayResearch/oss-governance-bot repository.

Copy link

@LaurenceJJones: There are no area labels on this PR. You can add as many areas as you see fit.

  • /area agent
  • /area local-api
  • /area cscli
  • /area appsec
  • /area security
  • /area configuration
Details

I am a bot created to help the crowdsecurity developers manage community feedback and contributions. You can check out my manifest file to understand my behavior and what I can do. If you want to use this for your project, you can check out the BirthdayResearch/oss-governance-bot repository.

@LaurenceJJones
Copy link
Contributor Author

/kind enhancement
/area agent

Copy link

codecov bot commented Apr 30, 2025

Codecov Report

Attention: Patch coverage is 30.55556% with 75 lines in your changes missing coverage. Please review.

Project coverage is 57.70%. Comparing base (764deee) to head (4cea22c).
Report is 7 commits behind head on master.

Files with missing lines Patch % Lines
pkg/acquisition/modules/docker/docker.go 30.55% 71 Missing and 4 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #3598      +/-   ##
==========================================
+ Coverage   57.66%   57.70%   +0.04%     
==========================================
  Files         395      395              
  Lines       44010    44117     +107     
==========================================
+ Hits        25378    25458      +80     
- Misses      16490    16527      +37     
+ Partials     2142     2132      -10     
Flag Coverage Δ
bats 42.60% <0.00%> (+<0.01%) ⬆️
unit-linux 32.91% <30.55%> (+0.04%) ⬆️
unit-windows 22.41% <30.55%> (+0.04%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@LaurenceJJones LaurenceJJones added this to the 1.6.9 milestone Apr 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/agent kind/enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant