flagr
flagr copied to clipboard
Notifier interface, generic webhooks and slack webhooks
Description
- Related to issue #214
- Add a generic webhook to push updates to flags to a user specified endpoint
- Add a slack specific webhook to push updates to a slack channel like this:


Motivation and Context
We needed notifications around who was doing what with the flags we had active, when they were enabled / disabled etc
How Has This Been Tested?
Manually and with automated tests
Types of changes
- [ ] Bug fix (non-breaking change which fixes an issue)
- [x] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to change)
Checklist:
- [x] My code follows the code style of this project.
- [x] My change requires a change to the documentation.
- [ ] I have updated the documentation accordingly.
- [x] I have added tests to cover my changes.
- [x] All new and existing tests passed.
Thanks, this is awesome! I will take a look soon
Codecov Report
Merging #240 into master will decrease coverage by
1.22%
. The diff coverage is73.79%
.
@@ Coverage Diff @@
## master #240 +/- ##
=========================================
- Coverage 82.62% 81.4% -1.23%
=========================================
Files 25 29 +4
Lines 1439 1667 +228
=========================================
+ Hits 1189 1357 +168
- Misses 192 234 +42
- Partials 58 76 +18
Impacted Files | Coverage Δ | |
---|---|---|
pkg/handler/crud.go | 91.34% <100%> (+0.35%) |
:arrow_up: |
pkg/util/util.go | 94.28% <33.33%> (-5.72%) |
:arrow_down: |
pkg/notify/client.go | 56.97% <56.97%> (ø) |
|
pkg/notify/notify.go | 68.96% <68.96%> (ø) |
|
pkg/notify/webhook.go | 78.94% <78.94%> (ø) |
|
pkg/notify/slack.go | 89.61% <89.61%> (ø) |
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact)
,ø = not affected
,? = missing data
Powered by Codecov. Last update c3ef755...2f05693. Read the comment docs.
thanks, I will fix up
@zhouzhuojie - have thrown retryable http into the mix as well as timeouts and everything else you've suggested bar the templates, mind giving some input to the direction?
Sorry for the delayed response I have been away.
I'll get this stuff fixed up this week!
@j4k sorry to bother you, are you going to be able to complete this? this is something that we can use too
I was about to add the same functionality to flagr so awesome work! Is there a way to also notify on a flag that's rolled out 100% for x time straight (1 week) so we know it's ready and can clean the code? this would be really helpful
I'm also really interesed in this feature, is there something we can do to help out to give it the final push to master? Thanks!
We started to work on this, and we're continuing this here, so I'm solving the last requests you made before, and I'll we can discuss pending feedback in the meantime
Stale pull request message