title: How to create a custom event pattern in aws cloudwatch rule?
body: <p>I'm having <strong>CloudWatchLogs</strong> as the source and I'm having a lambda function to invoke the event as the target.</p>
  
  <p>In the current approach, whenever a log stream get's created the lambda fires up. But what I want is, to write a custom event pattern in the <em>Cloudwatch rule</em> so that, only whenever the log message contains Exception or Error, it should fire the lambda. Is this possible?</p>
  
  <p>Cos currently the event I get from <strong>CloudwatchLogs</strong> in lambda, does not contain any details with regards to log message. Hence how can I create a custom pattern to fire lambda only when a log contains the word <strong>Exception</strong> in the rule itself? </p>