April 19, 2018 | Written by: Carlos Santana
Categorized: Compute Services | What's New
Share this post:
In serverless applications, functions are small and need to execute in less amount of time in a stateless environment. Logging then becomes a challenge for DevOps to do Root Cause Analysis (RCA) or get insights about the behavior of their applications.
One logging approach is to add code to your functions to send logs to an external API, which can be a painful process for you and the performance of your applications. You don’t want to add complexity to your functions in terms of security, extra endpoints and protocols, as opposed to just concentrating on your business logic scoped to the single function. Because every millisecond counts when using serverless, you don’t want end users waiting while you send logs during action invocation.
IBM Cloud Functions to the IBM Cloud Log Analysis service,
In the case of IBM Cloud Functions, the platform takes care of the complexity, allowing you to collect and analyze logs using the ELK Stack (Elasticsearch, Logstash, and Kibana) as a centralized log management solution. Just print a line to standard out or error and your logs will be available in a secure, scalable way, without worrying about infrastructure for logging.
You can use the logging capabilities in the IBM Cloud to understand the behavior of your Serveless Applications.
- Provide an audit trail for an application
- Detect problems in your application
- Identify vulnerabilities
- Troubleshoot your app
- Trace your app across components in the Cloud Platform
- Detect patterns that you can use to preempt actions that could affect your Serverless Application.
In addition to log lines, IBM Cloud Log Analysis also indexes the results (activation records) generated by IBM Cloud Functions. The results contain rich-metadata relevant for activations, such as their duration or result-code (success, error). All of the fields are queryable, and as such can help you understand how your Cloud Functions Actions are behaving.
Get started with IBM Cloud Functions
For more information make sure you to check out the IBM Cloud Functions documentation.