Triggers

Triggers in LogHub allow you to automate actions based on specific logging events, making your monitoring and alerting process more proactive and responsive. Triggers can be set up to respond to new logs, log trails, or time measurements, ensuring that you stay informed and take action whenever necessary.

Key Features of Triggers

Automated Actions

With Triggers, you can automate responses when specific events occur in LogHub. For example:

  • When a new log is received.
  • When a new log trail is added.
  • When a time measurement log comes in.

This automation allows you to react immediately to important events or errors without having to manually monitor the system.

Customizable Conditions

Triggers can be finely tuned based on various conditions, allowing you to target the exact type of logs you want to respond to. You can create triggers based on:

  • Log Type: Set triggers to respond to specific types such as ERROR, WARNING, SUCCESS, etc.
  • Function: Focus on logs from a particular function or process within your project.
  • URL: Respond to logs originating from a specific path or endpoint.
  • Message: Use keywords or patterns in the log message to trigger actions.
  • Parent: Create triggers based on logs that are part of a specific log trail or parent log.

This level of control ensures you only trigger actions when the exact conditions you care about are met.

Custom Actions

When a trigger condition is met, you can define various custom actions to take place automatically. These actions might include:

  • Sending an Email: Get an instant notification when a specific log type, such as an ERROR, occurs.
  • Sending a Push Notification: Use services like Pushover to receive real-time push messages on your mobile or desktop devices.
  • Calling a Webhook: Automatically call a webhook URL, triggering external systems or integrating with other services when an event happens.

This flexibility allows you to integrate LogHub with external tools, services, and workflows, ensuring a smooth and responsive alerting system.

Easy Management

Triggers in LogHub are designed to be simple to manage:

  • You can edit trigger conditions and actions at any time to adapt to changes in your project’s needs.
  • Triggers can be easily turned on or off, giving you full control over when and how automated actions are executed.

Adding a trigger

Triggers in LogHub allow you to automate actions based on specific logging events, making your monitoring and alerting process more proactive and responsive. Triggers can be set up to respond to new logs, log trails, or time measurements, ensuring that you stay informed and take action whenever necessary.

To create a new Trigger log into your LogHub account and go to Triggers. Click the button “Create trigger” and configure the following settings:

  • Trigger name: Give the trigger a name. It will be used in the trigger notifications sent to you and help you understand, what the trigger actually does.
  • Set trigger: What triggers the automation to run? You can choose from a new log that comes in to a new log trail that has been added or a new time measurement that just came in.
  • Set the conditions: You have a lot of options to choose from, when it comes to conditions:
    • Log Field: The Log field describes, what kind of information from the log is being checked. It can be the log message itself, the type, function, URL or the parent Log ID
    • Operator: The operator is used to compare the given log field with your input. Use the right operators accordingly and keep in mind, that strings, when checked with mathematical operators, are casted to floats.
      When you want to check if a certain string is in the log message use the string operators like “Contain”, “Starts with”, “Ends with”
    • Value field: This field will be your data to check the log field against.
  • Define the action: As development progresses, we add more and more actions to LogHub. Currently there are 3 possible actions you can choose from:
    • Send Email to all users: Sends an Email to each participating user in this project with the log that triggered the automation.
    • Send Pushover: Sends a Push message to each participating user in this project with the log that triggered the automation. For this action to work you need a valid pushover api key set in your user profile.
    • Call Webhook URL: Calls a Webhook with HTTP/POST with the logs data.

How fast do trigger respond?

When a new log comes in it can take up to 60 seconds will your triggers fires and executes the set actions.

Enable / disable Triggers

You can enable or disable the triggers at any time with the toggle switch on the bottom right.