- MiniCrossStitching Rails app
- Contains a mystery defect
- Create a new Github Codespace
- Run server:
bin/serve - Simulate users:
bin/hammer
bin/setup # Setup the app
bin/serve # Start the server
bin/hammer # Simulate users
bin/errors # Show errors in Solid ErrorsStarting code for logging:
Rails.logger.info(
message: "Added border to preview",
"event.name" => "com.jp.cs.pattern.preview.added",
"com.jp.cs.pattern.width" => width,
"com.jp.cs.pattern.height" => height
)
rescue StandardError => e
Rails.logger.error(
message: "Error adding border to preview",
"event.name" => "com.jp.cs.pattern.preview.added",
"com.jp.cs.pattern.width" => width,
"com.jp.cs.pattern.height" => height,
exception: e,
)
raise eDQL for GROUP BY orientation:
fetch logs
| filter matchesValue(event.name, "com.jp.cs.pattern.preview.added")
| filter isNotNull(com.jp.cs.pattern.orientation)
| summarize count(), by: { loglevel, com.jp.cs.pattern.orientation }