Fastly delivers more than a million log events per second. Setting it is up is easy, but there are many features you might not be using to their full extent.
This workshop will cover setting up logging to various endpoints, dealing with structured data, and getting real-time insights into your customers’ behavior.
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Altitude SF 2017: Logging at the edge
1. Logging at the Edge
Chris Jackel
Solutions Architect | Fastly
Mehran Nazir | Google
2. • How Fastly’s logs work What to log
• Set up a service and log endpoint
• What to Log
• JSON logging
• Fun with logs
• Serverless Applicationless Edge Logging
Agenda
3. • Log endpoint configured
• Customized Fastly log string
• JSON formatted
• BigQuery data import
Expectations at the end
22. Somewhat limited support for Apache log format variables
VCL variables can just dropped in
No (good) support for string literals, let alone things like JSON
Log format v1
23. Full support for Apache log format variables
Some will never return a value
VCL variables (or code) through Fastly specific extension: %{...}V
Supports string literals, and thus JSON is much easier to do
Default for all newly created endpoints
Legacy endpoints can be upgraded to v2
Log format v2
26. Originally hardcoded syslog prefix
Now 4 options:
syslog classic syslog prefix, RFC 3164 (default)
loggly modern syslog structured prefix, RFC 5424
logplex Heroku style prefix
blank no prefix, good for JSON and CSV
Currently available through API — and through the Portal TODAY
See https://docs.fastly.com/guides/streaming-logs/changing-log-line-formats
Prefixes