Add Logs Ingestion API scenario with synthetic sample data - #296
Open
Austin McCollum (austinmccollum) wants to merge 4 commits into
Open
Add Logs Ingestion API scenario with synthetic sample data#296Austin McCollum (austinmccollum) wants to merge 4 commits into
Austin McCollum (austinmccollum) wants to merge 4 commits into
Conversation
There was a problem hiding this comment.
Pull request overview
Adds a new “Logs Ingestion API” scenario under Scenarios/How to collect data with the Logs Ingestion API/ to provide synthetic Apache access-log data and a generator script that can be used with the Azure Monitor Logs Ingestion API portal tutorial.
Changes:
- Added a scenario README that links to the portal tutorial and explains how to use/generate sample access logs.
- Added a PowerShell generator (
Generate-SampleAccessLog.ps1) to create synthetic Apache Combined Log Format entries. - Added a pre-generated
sample_access.log(200 entries) intended to be tutorial-ready.
Reviewed changes
Copilot reviewed 2 out of 3 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
Scenarios/How to collect data with the Logs Ingestion API/README.md |
Scenario documentation and usage instructions for the sample/generator. |
Scenarios/How to collect data with the Logs Ingestion API/Generate-SampleAccessLog.ps1 |
Synthetic log generator (currently has determinism/privacy mismatches vs PR description). |
Scenarios/How to collect data with the Logs Ingestion API/sample_access.log |
Pre-generated sample log (currently contains real-domain UA URLs and many 10.0.* IPs). |
Suppressed comments (1)
Scenarios/How to collect data with the Logs Ingestion API/Generate-SampleAccessLog.ps1:178
- The
$random = [System.Random]::new(42)variable is never used, so the generator output is not actually reproducible even though the script/comment claims a fixed seed. Switching the per-field selections (method/path/status/UA/referer and time delta) to use the seeded helper will make reruns deterministic.
$random = [System.Random]::new(42) # Fixed seed for reproducibility
$entries = [System.Collections.Generic.List[string]]::new($Count)
$currentTime = $StartDate
for ($i = 0; $i -lt $Count; $i++) {
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Co-authored-by: Copilot Autofix powered by AI <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a new scenario under
Scenarios/How to collect data with the Logs Ingestion API/to support the Logs Ingestion API portal tutorial.Problem
The tutorial's inline sample data (~200 lines of Apache access logs) contained references to a real website (
almhuette-raith.at), real page paths, and real user-agent strings — a privacy concern for published documentation.Changes
README.mdGenerate-SampleAccessLog.ps1198.51.100.x,203.0.113.x),contoso.example.comdomains, and weighted response codessample_access.logDesign decisions
198.51.100.x,203.0.113.x) and RFC 2606 domains (example.com) — reserved for documentation, guaranteed non-routablewhere ResponseCode != 200KQL filter produces meaningful output