Skip to content

Commit

Permalink
add temp solution for async slack notifications
Browse files Browse the repository at this point in the history
  • Loading branch information
kirillshevch committed Jul 22, 2019
1 parent 5513a30 commit 32d6a7e
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 4 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# v0.0.4 2019-07-22

Added temp solution for async slack notifications. ([kirillshevch](https://github.com/kirillshevch/query_track/pull/5))

# v0.0.3 2019-07-22

Added backtrace filters. ([kirillshevch](https://github.com/kirillshevch/query_track/pull/3))
Expand Down
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
query_track (0.0.3)
query_track (0.0.4)
activesupport
dry-configurable
slack_hook
Expand Down
2 changes: 1 addition & 1 deletion lib/query_track/notifications/slack.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ def call

payload = { blocks: blocks(trace) }

slack_hook.post(payload)
Thread.new { slack_hook.post(payload) }
end

private
Expand Down
2 changes: 1 addition & 1 deletion lib/query_track/version.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module QueryTrack
VERSION = '0.0.3'
VERSION = '0.0.4'
end
2 changes: 1 addition & 1 deletion spec/query_track/notifications/slack_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@

it 'should post notification to slack' do
allow(SlackHook::Incoming).to receive(:new).and_return(slack_stub)
expect(slack_stub).to receive(:post)
expect(Thread).to receive(:new)
subject.call
end
end
Expand Down

0 comments on commit 32d6a7e

Please sign in to comment.