I am trying to upload logs to a log analysis workspace by following your tutorial. I am currently stuck at the Create data collection rule section because the documentation is wrong and/or outdated.
Because your documentation says that it's an option, I would prefer not to create a DCE and instead send logs directly to the DCR (via the DCR endpoint).
Problem 1: Wrong deployment template code
I am pretty sure your documentation accidentally got the template code mixed up. The code in the "DCR endpoint" tab should instead be in the "DCE" tab and vice versa. A DCR endpoint is not supposed to need a data collection endpoint ID.
Screenshot 1: the DCR endpoint isn't supposed to have an endpointResourceId
Screenshot 2: the "DCE" template is supposed to have the dataCollectionEndpointId instead
Problem 2: Wrong template schema
So I tried deploying the code in the "DCE" tab but Azure complained that the template schema version is not supported.
Problem 3: No ingestion endpoint
To get around that problem, I changed the schema version to 2019-08-01 and managed to deploy my DCR successfully. Now the problem is that when I look at the JSON view of the created DCR, then there is no logsIngestion endpoint there. I suspect this might have happened because I changed the template schema version, but I'm not sure how to get around this problem.