Application Logging by using Web-based Kibana UI in SAP Cloud Foundry
As we know there are many things to explore in SAP Cloud Foundry, and there are many services available in cloud foundry with unique capabilities.
Here in this blog i Just wanted to showcase the capabilities of Application Logging Service in SAP Cloud foundry.
What is Application Logging-
We can use Application logging to Create, store, access and analyze application logs. The SAP Cloud Platform Application Logging service on Cloud Foundry lets you stream logs of bound applications to a central application logging stack.
Application Logging on Cloud Foundry uses Elastic Stack to visualize and store your application log data.
We can see data in form of table as well as in web based Kibana Dashboard.
This service runs in the following environments:
- Neo environment
- Cloud Foundry environment – I am using this approach to show our scenarios
- Structured and rich log messages
Benefit from automatically structured log messages stored in Elasticsearch, harmonized across different runtimes, with meta-data, metrics, and custom values which offer a rich basis for deep analysis.
- Web-based Kibana UI
View, search, and analyze logs via the powerful Kibana technology with predefined dashboards and quickly identify relevant spots via interactive exploration.
- Log libraries for Java and Node.js apps
Use dedicated open source logging libraries for simple log production for Java and Node.js applications in the Cloud Foundry environment.
- Retention period
Exploit the retention period of up to 7 days which lets you do a post-mortem analysis.
Steps to Access-
You have already created an account in SCP Cloud foundry.
You have already few apps deployed, start and available in cloud foundry such as java, node js.
I am using JAVA application to display the logs in Kibana dashboard.
- Create Service Instance for Application logging service
This below help doc will help you to understand Application logging and other related features in more details like how to create instance.
Service Market Place –> Application Logging –> Create instance
- Application Binding
Service Instance –> Select Service and bind app –> select your app
Below helps doc will help you to understand in more details.
- Select Applications page in your dev space.
Select any one Started application, in my case I am selecting last apps Highlighted with green colour which is java app.
After clicking on app, you will reach to another page which would be look like below.
Click on Logs — Highlighted in green color box
You will be able to see logs below.
To open Kibana Dashboard click on “Open Kibana Dashboard Button” Highlighted in Yellow Box it will navigate to login screen
Let me talk about Kibana first –
Kibana is an open source frontend application that sits on top of the Elastic Stack, providing search and data visualization capabilities for data indexed in Elasticsearch. Commonly known as the charting tool for the Elastic Stack , Kibana also acts as the user interface for monitoring, managing, and securing an Elastic Stack cluster — as well as the centralized hub for built-in solutions developed on the Elastic Stack.
You can see total logs, log time, performance, log timeline ,dropped logs, metrics, error code etc. for particular app.
Here whatever information you are able to see it is all related to my Java application which i have used at the time of binding.
You can also create Visualizations
Here in this blog we have talked about the capabilities of Application Logging service in SAP Cloud foundry and integration with KIBANA Web Based UI.
Hope you all will like it.
Keep Exploring and Happy Learning.
Thanks and Regards
Naveen Kumar Jain