mirror of
https://github.com/meineerde/rackstash.git
synced 2025-12-20 07:11:12 +00:00
Use a Concurrent::Array for storing messages in the Buffer
This ensures that we can still concurrently add messages without messing with the internal Array.
This commit is contained in:
parent
e84d372c08
commit
4bbbf25ef8
@ -128,7 +128,7 @@ module Rackstash
|
|||||||
#
|
#
|
||||||
# @return [self]
|
# @return [self]
|
||||||
def clear
|
def clear
|
||||||
@messages = []
|
@messages = Concurrent::Array.new
|
||||||
@fields = Rackstash::Fields::Hash.new(forbidden_keys: FORBIDDEN_FIELDS)
|
@fields = Rackstash::Fields::Hash.new(forbidden_keys: FORBIDDEN_FIELDS)
|
||||||
@tags = Rackstash::Fields::Tags.new
|
@tags = Rackstash::Fields::Tags.new
|
||||||
@timestamp = nil
|
@timestamp = nil
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user