@ -138,8 +138,7 @@ handleEvent({mWriteLog, Message}, #state{fBName = _FBName, level = Level, shaper
_ - >
ReportStr = eFmt : format ( < < " lgBkdFile dropped ~p messages in the last second that exceeded the limit of ~p messages/sec " > > , [ Drop , NewShaper #lgShaper.hwm ] ) ,
NowMs = lgTime : nowMs ( ) ,
NowStr = lgUtil : msToBinStr ( NowMs ) ,
ReportMsg = #lgMsg { severity = ? llvWarning , pid = self ( ) , node = node ( ) , module = ? MODULE , function = ? FUNCTION_NAME , line = ? LINE , metadata = [ ] , datetime = NowStr , timestamp = NowMs , message = ReportStr , destinations = [ ] } ,
ReportMsg = #lgMsg { severity = ? llvWarning , pid = self ( ) , node = node ( ) , module = ? MODULE , function = ? FUNCTION_NAME , line = ? LINE , metadata = [ ] , timestamp = NowMs , message = ReportStr , destinations = [ ] } ,
writeLog ( State , NowMs , ? llvWarning , FmtTer : format ( ReportMsg , FmtCfg ) )
end ,
{ noreply , writeLog ( TemState #state { shaper = NewShaper } , Timestamp , Severity , FmtTer : format ( Message , FmtCfg ) ) } ;
@ -166,8 +165,7 @@ handleInfo({mShaperExpired, FBName}, #state{shaper = Shaper, fBName = FBName, fm
Dropped - >
ReportStr = eFmt : format ( < < " lgBkdFile dropped ~p messages in the last second that exceeded the limit of ~p messages/sec " > > , [ Dropped , Shaper #lgShaper.hwm ] ) ,
NowMs = lgTime : nowMs ( ) ,
NowStr = lgUtil : msToBinStr ( NowMs ) ,
ReportMsg = #lgMsg { severity = ? llvWarning , pid = self ( ) , node = node ( ) , module = ? MODULE , function = ? FUNCTION_NAME , line = ? LINE , metadata = [ ] , datetime = NowStr , timestamp = NowMs , message = ReportStr , destinations = [ ] } ,
ReportMsg = #lgMsg { severity = ? llvWarning , pid = self ( ) , node = node ( ) , module = ? MODULE , function = ? FUNCTION_NAME , line = ? LINE , metadata = [ ] , timestamp = NowMs , message = ReportStr , destinations = [ ] } ,
writeLog ( State , NowMs , ? llvWarning , FmtTer : format ( ReportMsg , FmtCfg ) )
end ,
{ noreply , State #state { shaper = Shaper #lgShaper { dropped = 0 } } } ;