Sending QBCore Logs to Elastic Search System For better logging
- No rate limit like discord, slack
- Better logs filter, finder
- Using your own server with local transport - with zero delay
- Can be using as DataSource for Grafana to display Dashboard 😎
Just using same QB-Logs Event Sample:
TriggerEvent('elk-log:server:elk', PlayerID, Citizenid, "Action", "Action Detail", IsDanger(true/false))
example in inventory:
TriggerEvent('elk-log:server:elk', ''.. GetPlayerName(source) ..'', ''.. Player.PlayerData.citizenid ..'', 'AddItem', '**' .. GetPlayerName(source) .. ' (citizenid: ' .. Player.PlayerData.citizenid .. ' | id: ' .. source .. ')** got item: [slot:' .. slot .. '], itemname: ' .. Player.PlayerData.items[slot].name .. ', added amount: ' .. amount .. ', new total amount: ' .. Player.PlayerData.items[slot].amount)
Example in Players with ELK Logs and Tag in Discord Webhook:
TriggerEvent('elk-log:server:elk', ''.. GetPlayerName(self.PlayerData.source) ..'', ''.. self.PlayerData.citizenid ..'', 'AddMoney', '**' .. GetPlayerName(self.PlayerData.source) .. ' (citizenid: ' .. self.PlayerData.citizenid .. ' | id: ' .. self.PlayerData.source .. ')** $' .. amount .. ' (' .. moneytype .. ') added, new ' .. moneytype .. ' balance: ' .. self.PlayerData.money[moneytype] .. ' reason: ' .. reason, true)
Using ELK Docker in this repository