title: Laravel, logging and Cloudwatch - why isn't this working?
body: <p>I'm currently using Laravel 6.16.0. </p>
  
  <p>We are trying to get extensive logging on our application. The Package we have installed is: <a href="https://github.com/maxbanton/cwh" rel="nofollow noreferrer">https://github.com/maxbanton/cwh</a>, and I'm using this to implement it: <a href="https://stackoverflow.com/a/51790656/12978881">https://stackoverflow.com/a/51790656/12978881</a></p>
  
  <p>We're using Stacks for our logging, which includes Slack, Sentry, Laravel logs and CW.</p>
  
  <p>For some reason it just isn't outputting anything to CloudWatch which we want to be the main output.</p>
  
  <p>In the CloudWatchLoggerFactory.php I've even tried throwing any AWS errors like so:</p>
  
  <pre><code>try {
        $handler = new CloudWatch($client, $groupName, $streamName, $retentionDays, 10000, $tags);
  } catch(\Exception $e) {
        print_r($e);
  }
  </code></pre>
  
  <p>However nothing is even getting that far. </p>
  
  <p>The code is definitely being invoked as it exits with a simple <code>die('test.');</code></p>
  
  <p>No errors relating to AWS are being output to the log at all.
  The AWS keys are valid and have the correct permissions.</p>
  
  <p>Has anyone had a similar experience, and how did you sort it?</p>