Serverless App Services and deployments
Build and runtime logs
Read a deployment's build output, and search or tail its server logs from the last 7 days.
Both are on the deployment's page in Cloud and need the logs:read scope, which every role has. Cloud → Logs and a Serverless App Service's Logs tab show runtime logs too, for a deployment you choose (the current production deployment first).
Build logs
The Build Logs tab shows the build's output from the first step marker (::step source) on, up to 2,000 lines. The page refreshes itself while the deployment is building. See The build pipeline for the steps.
Runtime logs
The Runtime Logs tab shows what the deployment's server function logged, newest first, 500 lines at a time. Static deployments have no server function and no runtime logs.
- Range: the last hour (default), 6 hours, 24 hours or 7 days. Function logs are kept for at least 7 days.
- Filter matches messages case-insensitively (up to 200 characters).
- Load older events continues past the first 500 lines.
- Live adds new lines every 3 seconds, newest on top, until you pause it. A very busy function can log more than one request carries; the tab then says some lines were skipped.
- Refresh loads the latest lines.
Levels
Each line gets a level, from the first of these that applies:
- Lambda's own lines (
START,END,REPORT,INIT_STARTand similar) are platform lines, shown without a level. - JSON messages with a
level,severityorlvlfield use it:error,err,fatal,critical,crit,alert,emergandemergencyare errors;warnandwarningare warnings;debug,traceandverboseare debug; anything else is info. Numeric pino levels map too (50 and up error, 40 warn, 30 info, below that debug). - Otherwise the Node.js log level applies:
console.erroris an error,console.warna warning,console.debugandconsole.tracedebug, andconsole.loginfo.
Messages longer than 4,000 characters are cut and marked.
Structured logs read well here:
console.log(JSON.stringify({ level: "warn", msg: "payment.retry", orderId, attempt }))