AnsweredAssumed Answered

Alert trimming using lua

Question asked by MartinNepolean on Mar 8, 2016
Latest reply on Mar 9, 2016 by MartinNepolean

Hi All,

 

I am new to LUA and my requirement is to extract first 50 characters of the alert generated from ntevl probe.I wrote the below script to place it in AO profile. Please go through it and let me know if i can modify anything to improve the script execution speed(it takes atleast 3 secs to trim the alert) or is there a better way to achieve the alert trimming

 

al=alarm.list("message","Test%")

if al ~= nil then

  for i = 1,#al do 

      a=al[i]

      msg=left(a.message,15)

      a.message = msg

      alarm.set(a)

end

end

Outcomes