title: What would cause AWS Lambda not to write to Cloudwatch?
body: <p>I have a simple AWS Lambda function that runs but does not always write to the cloudwatch log.</p>
  <p>I've added a counter to the function to track when it logs and when it doesn't and can see that most of the time the first invocation is not recorded, but subsequent ones are (the counter starts at 0, so below is the result of me invoking the function for the second time:</p>
  <p><a href="https://i.stack.imgur.com/g7ONX.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/g7ONX.png" alt="enter image description here" /></a></p>
  <p>I assumed that it was something that I was doing in code but got this result where the &quot;START RequestId&quot; entry was missing (yes I have hit the top retry link):</p>
  <p><a href="https://i.stack.imgur.com/7197r.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/7197r.png" alt="enter image description here" /></a></p>
  <p>As far as I know there is absolutely nothing that I can do to stop the AWS infrastructure from recording the start and end of a request as this gets managed outside of my code. The code also runs and returns correctly, but it just doesn't always create a log, and other times doesn't create a whole log.</p>
  <p>The only real difference to this from existing lambdas is that I am calling this from a Lambda Function Url.</p>
  <p>Any ideas on why I'm seeing this and how to resolve? I'm pretty certain that its not a coding issue.</p>