# Element: actions

## Location

/[patterndb](../../../../../docs/axosyslog-core/chapter-parsers/chapter-patterndb/reference-parsers-pattern-databases/reference-patterndb-schemes/patterndb-scheme-patterndb/index.md)/[ruleset](../../../../../docs/axosyslog-core/chapter-parsers/chapter-patterndb/reference-parsers-pattern-databases/reference-patterndb-schemes/patterndb-scheme-ruleset/index.md)/_actions_

## Description

OPTIONAL — A container element for actions that are performed if a message is recognized by the pattern. For details on actions, see [Triggering actions for identified messages](../../../../../docs/axosyslog-core/chapter-parsers/chapter-patterndb/patterndb-triggers-actions/index.md).

## Attributes

N/A

## Children

  * _action_



## Example

## Example: Generating messages for pattern database matches

When inserted in a pattern database rule, the following example generates a message when a message matching the rule is received.
```
 
       <actions>
            <action>
                <message>
                    <values>
                        <value name="MESSAGE">A log message from ${HOST} matched rule number $.classifier.rule_id</value>
                    </values>
                </message>
            </action>
        </actions>
    
```

To inherit the properties and values of the triggering message, set the `inherit-properties` attribute of the `<message>` element to TRUE. That way the triggering log message is cloned, including name-value pairs and tags. If you set any values for the message in the `<action>` element, they will override the values of the original message.

## Example: Generating messages with inherited values

The following action generates a message that is identical to the original message, but its $PROGRAM field is set to `overriding-original-program-name`
```
 
       <actions>
            <action>
                <message inherit-properties='TRUE'>
                    <values>
                        <value name="PROGRAM">overriding-original-program-name</value>
                    </values>
                </message>
            </action>
        </actions>
    
```

Last modified June 27, 2023: [Update paths to follow-up moving the files (6585a5b1)](<https://github.com/axoflow/axosyslog-core-docs/commit/6585a5b156244e39bb831bf4e8289529f30dea0f>)