Skip to content

Viewing Event Logs

Use event log information to troubleshoot application problems. Use search criteria to find specific log records and statements.

Typically, one event log is captured per business operation. However for complex business processes, such as those for Offline and SAP Mobile Cards, data is collected throughout an operation, and written along with the general event log message. The multiple messages are associated using the Correlation ID, and provide you with more detailed information to better isolate a problem.

You can enable detailed logging at the application level as described in Enabling Event Logs at the App Level. Note that detailed logging is used for troubleshooting, not for monitoring, so the log is reset after 24 hours. You can manually enable detailed logging again if you need more time for troubleshooting.

You can subscribe to event logs, and manage them using My Alerts. If you create a condition for the subscription using the SAP Alert Notification service, you can continue to receive alert notifications for three months. You can extend the subscription for another three months using My Alerts.

For some services, you can enable or disable detailed logging either at the application or settings level. In these cases, when you disable detailed logging, error logging is still done. To enable detailed logging for applications, see Managing Apps. For the Cloud Build standalone service you can enable detailed event logging and default purge settings via Settings > Cloud Build. To see the detailed event log related to build process for the cloud build, you need to enable the detailed event log for cloud build feature at the application level (using Enable Detailed Event Logging).

Note

If you disable detailed logging, error logging is still done.

To view event logs:

  1. In SAP mobile service cockpit, select Analytics > Logs.

  2. (Optional) You can narrow the focus of event logs to view by setting filters such as Application ID, logging Level, Correlation ID, Feature Name, Time Frame (UTC+0000) (either a predefined time frame, or a custom time frame using the calendar date-picker to define a range), and User Name; and selecting Go. Select Reset Filter to clear your filter entries.

    • To view event log messages for a specific level, select Level, then select the logging level. Leave blank to include all levels.

      Logging Levels

      Log Level Description
      Debug For debugging purposes, includes extensive and low-level information.
      Info Informational text, used mostly for echoing what has been performed.
      Warn The application can recover from the anomaly, and fulfill the task, but requires attention from the developer or operator.
      Error The application can recover from the error, but cannot fulfill the task due to the error.
    • To view event log messages for specific components, select Feature Name, then select the service names (or leave blank to include all services). Select Go.

      System Logging Service Names

      Service Name Description
      Mobile App Catalog Logs system messages that are related to managing the app catalog.
      Mobile App Update Logs messages that are related to application versioning services.
      Mobile Application Logs messages that are related to Native/MDK applications.
      Mobile Augmented Reality Manage client augmented reality resources that can be accessed from mobile applications.
      Mobile Client Log Upload Logs messages that are related to uploading client application log files for analysis on the server.
      Mobile Client Resources Logs messages that are related to resources that can be accessed from mobile applications.
      Mobile Client Usage and User Feedback Logs messages that are related to uploading client usage and user feedback data for analysis on the server.
      Mobile Cloud Build Logs system messages that are related to the cloud build service.
      Mobile Cockpit Logs system messages that are related to SAP Mobile Services administration.
      Mobile Discovery Logs messages that are related to discovery services.
      Mobile Micro App Logs messages that are related to micro applications.
      Mobile Network Trace Logs messages that are related to network trace.
      Mobile Offline Access Logs system messages that are related to offline access to data on the mobile device.
      Mobile Push Notification Logs system messages that are related to native push actions for iOS and Android devices.
      Mobile Sample OData ESPM Logs system messages that are related to the OData sample service, which can be used during development and testing.
      Mobile Setting Exchange Logs system messages that are related to device registration and the exchange general settings between mobile client and server.
      mobile transaction bridge OData Logs system messages that are related to mobile transaction bridge processes.
      mobile transaction bridge Storage Logs system messages that are related to mobile transaction bridge storage.
    • To limit the results within a time frame, select the time frame; or set the time manually by selecting Custom Defined, entering a date range, and selecting OK.

    • To view log messages for requests initiated by a specific user, enter a user name.

    Logging information is based on your search criteria.

    Column Description
    Time The time and date stamp of the log entry.
    Level Level value, typically ERROR or WARN or INFO or DEBUG.
    Service Name Lists services by name.
    User Name The name of the user associated with the application ID.
    Message The link to detailed log information associated with the execution request.
  3. (Optional) To download a text version of the event log file to the Downloads directory, select one or more rows, and click the Download icon.

  4. (Optional) To create a subscription to an event log, select Subscribe. Fill out the settings in Subscribe Event Log, as described in Subscribe to Event Log Alerts.

    Once you save the subscription, you can manage it in My Alerts. If you manually create a condition in the Alert Notification service, you can continue to receive alert notifications based on the subscription. See Managing my Alerts and Subscribe to Event Log Notices for information.

  5. (Optional) To view event log messages, select a row, and click the icon. Under Event Log Details and Application and User Details view a summary of event-related information.

    Under Related Events the event message appears. If you see a single event message, with a Seconds Before (-) After (+) value of 0, there are no correlated events. Multiple event messages, with a range of Seconds Before (-) After (+) values indicate that there are several correlated events. Use the values to establish the timeline of what happened leading up to and after the event.

    Related Events

    Field Value
    Seconds Before (-) After (+) Indicates when the message occurred:
    • - (minus) ‒ the message occurred before the reported event.
    • 0 ‒ the event.
    • + (plus) ‒ the message occurred after the reported event.
    Level The logging level set for the component.
    Feature Name The component reporting the event.
    Message The message reported.

Enabling Event Logs at the App Level

For apps that have been migrated to the single-service model, you can enable detailed event logging at the application level.

You can specify the services to include, as well as Mobile Application. This gives you more control over the event log information you want to see at the app level.

Note

Detailed logging is used for troubleshooting, not for monitoring, so logging is terminated after 24 hours. You can manually enable detailed event logging for another 24 hours.

For applications that have not been migrated to the single-service model, you must enable detailed event logs at the service level. You still view the event logs for the application as described in Viewing Event Logs.

To enable event logs at the application level:

  1. In SAP mobile service cockpit, select Mobile Applications > Native/MDK (or Mobile Applications > SAP Mobile Cards or Mobile Applications > Micro App).

  2. Select an application, then select the Log Settings tab. (If Log Settings does not appear, it means the app has not been migrated to the single service model).

    Under Detailed Event Log Settings, the features that are assigned to the application are listed.

    Settings Description
    Feature Name All features that are assigned to the application appear, as well as the additional feature, Mobile Application.
    Included in Detailed Event Log Whether the feature is included in the detailed event log for the selected application.
  3. Select edit .

  4. In Enable Detailed Event Log Settings, select the features to include in the detailed event log for the application. Only features assigned to the app are available, plus Mobile Application.

  5. Click Enable. Changes appear under Included in Detailed Event Log.

Subscribe to Event Log Alerts

You can subscribe to event logs at the tenant level to receive notifications, and manage the subscriptions through My Alerts.

When you subscribe to event log alerts from SAP mobile service cockpit, you can configure the option to send the alerts to the SAP Alert Notification service. This option enables you to control how often and when to send events from SAP mobile service cockpit to the Alert Notification service. You can set a threshold value for when to send events (for example, after one alert, or after five alerts), or set a schedule for when to send events (for example, every hour, every eight hours, or every 24 hours). This reduces the number of repetitive alerts that are sent, so that the Alert Notification service is not overwhelmed.

The actual condition for notifications must be created using the SAP Alert Notification service. If you create a condition for the subscription via the Alert Notification service, you can continue to receive alert notifications for three months. You can extend the subscription for another three months using My Alerts.

  1. In SAP mobile service cockpit, select Analytics > Logs.

  2. You can narrow the focus of event logs to view by selecting filters, such as Application ID, logging Level, Correlation ID, Feature Name, Time Frame (UTC+0000), and User Name. Select Go to search.

  3. To subscribe to the filtered event log, select Subscribe.

    In Subscribe Event Log, assign a subscription name and review or edit the subscription. The entries reflect the original filters you selected, but you can modify them.

    Event Log Subscription

    Setting Description
    Subscription Name Enter a subscription name that is meaningful to you, such as "com.sap.v2.logout".
    Category Event Log
    Application ID The application identifier.
    Level The log level, such as ERROR.
    Feature Name One or more features that are included in the event log.
    Send to ANS Whether to send event log alerts to the Alert Notification service. Select this option if you plan to configure a condition for alert notifications in the Alert Notification service. If you enable the Send to ANS option, two additional fields appear. They are used to configure how often and when to send events to the Alert Notification service.
    Threshold (ANS) If you enable the Send to ANS checkbox, you can provide a Threshold for when alerts are sent, such as 0, 1, or 5. If the event count number is greater than the threshold number, an alert notification is sent to the Alert Notification service.
    Schedule (ANS) If you enable the Send to ANS checkbox, you can select a schedule, such as Every Hour, Every 8 Hours, and Every 24 Hours. Alert notifications are sent to the Alert Notification service periodically based on your selection.
    Alert Notification service If you enable the Send to ANS checkbox, note the Alert Notification service information. You'll need this to manually create the condition in the Alert Notification service.
  4. Select Save.

    Once you save, the subscription appears in My Alerts. The alert subscription remains until you delete it.

  5. To receive ongoing alert notifications for the subscription, create a condition in the Alert Notification service. See Subscribe to Event Log Notices.

    With the condition, you receive alert notifications for three months. You can extend alert notifications for another three months using My Alerts. See Managing My Alerts. Sample Alert Notification service conditions:

    To receive alert notifications for a specific event log subscription:

    1
    2
    3
    4
    5
    ```text
    Key: tags.mobile_event_log_alert
    Predicate: Is Equal To
    Value: MyEventLogSubscription
    ```
    

    To receive alert notifications for all event log subscriptions in the space/tenant:

    1
    2
    3
    4
    5
    ```text
    Key: eventType
    Predicate: Is Equal To
    Value: MobileServicesEventLogAlert
    ```
    

Last update: August 12, 2022