()
| 24 | |
| 25 | #[tokio::main] |
| 26 | async fn main() -> Result<(), Error> { |
| 27 | tracing_subscriber::fmt() |
| 28 | .with_env_filter( |
| 29 | EnvFilter::builder() |
| 30 | .with_default_directive(LevelFilter::INFO.into()) |
| 31 | .from_env_lossy(), |
| 32 | ) |
| 33 | // disable printing the name of the module in every log line. |
| 34 | .with_target(false) |
| 35 | // disabling time is handy because CloudWatch will add the ingestion time. |
| 36 | .without_time() |
| 37 | .init(); |
| 38 | |
| 39 | run(service_fn(function_handler)).await |
| 40 | } |