Posted On: Nov 13, 2023

We are excited to announce regular expression support for Amazon CloudWatch Logs Live Tail filter pattern syntax, making it easier to search and match relevant log events. Customers use filter pattern syntax today in metric filters and subscription filters, and Live Tail’s addition is further enhancing their experience. With today’s launch, customers will be able to customize their filtering to meet their needs with flexible and powerful regular expressions within Live Tail filter patterns. Now customers can define one filter to match multiple IP subnets or HTTP status codes using a regular expression such as ‘{ $.statusCode=%4[0-9]{2}% }’ rather than having to define multiple filters to find exactly what they are looking for in their logs.

Filter patterns make up the syntax that Live Tail uses to match terms in log events similar to metric filters, subscription filters, and filtering log events. Terms can be words, exact phrases, or numeric values. 

Regular expression support for Amazon CloudWatch Logs Live Tail filter pattern syntax is available in all AWS Commercial regions where Amazon CloudWatch Logs is available.

Learn more by reviewing our Filter and Pattern Syntax documentation.