Convert manual services to application services using API

  • Release version: Xanadu
  • Updated August 1, 2024
  • 2 minutes to read
  • Summarize
    Summarized using AI
    This content was generated using new OpenAI-powered functionality. Results are provided on an as is basis and are not guaranteed to be accurate or complete.

    Summary of Convert manual services to application services using API

    ServiceNow has replaced manual services with application services, which are essential for Event Management to monitor service performance and identify health issues. Manual services are now unsupported, so existing manual services must be converted to application services using a JavaScript API. This conversion retains the original service attributes and configuration items (CIs), enabling a smoother transition while ensuring service monitoring capabilities.

    Show full answer Show less

    Conversion Process and Considerations

    • The conversion moves manual service records from the Manual Services [cmdbciservicemanual] table to the Mapped Application Service [cmdbciservicediscovered] table by changing the record class.
    • All original attributes (name, owner, operational status) and CIs are preserved.
    • After conversion, the system queries the CMDB for the latest CI changes and applies CI impact rules.
    • The sa.service.maxciservicepopulation system property controls the maximum number of CI connections added during conversion, defaulting to 1,000 to avoid performance issues. This value can be adjusted but exceeding it causes the operation to fail.
    • It is recommended to convert services in small batches (~10 at a time) to easily identify any issues.
    • Certain CI types are not supported in application services and must be removed before conversion: cmdbciendpoint, cmdbcitranslationrule, cmdbciconfigfile, cmdbciqualifier, cmdbciapplicationcluster. These should be replaced with supported CIs after conversion.
    • If domain separation is enabled, conversion will fail if a manual service contains CIs from multiple domains. Only CIs from the same domain will be included in the converted service.
    • Ensure any automation related to manual services (business rules, scheduled jobs) is built and tested before conversion.

    API Usage

    Use the JavaScript API BusinessServiceManager.migrateManualToApplicationService(String serviceid) to convert a manual service by its sysid.

    ParameterTypeDescription
    serviceidStringsysid of the manual service to convert
    Return TypeDescription
    Booleantrue if conversion succeeds, false if it fails

    Example script to convert a manual service with sysid 451047c6c0a8016400de0ae6df9b9d76:

    var bsManager = new SNC.BusinessServiceManager();var res = bsManager.migrateManualToApplicationService("451047c6c0a8016400de0ae6df9b9d76");

    Practical Impact for ServiceNow Customers

    • Converting manual services to application services is necessary to maintain service monitoring and health insights within Event Management.
    • The API facilitates automated, controlled conversion while preserving key service data and CMDB relationships.
    • Understanding CI limitations and domain separation constraints helps avoid conversion failures.
    • Adjusting system properties and processing services in batches improves performance and troubleshooting.

    You can use a JavaScript API to convert existing manual services to application services. Event Management can use application services to monitor service performance and identify health issues.

    Manual services are no longer supported and this service type, as well as discovered services, have been replaced by application services. Any existing manual services must be converted to application services. Ensure that any automation of manual services (such as business rules or scheduled jobs) have been built and tested before converting to application services.
    Note:
    Manual services are static and retain their original structure after conversion to application services. To update imported manual services with the existing CMDB state, either populate the original manual services to ensure that all CIs are assigned to the correct service, or run the update with CMDB changes option after the conversion.
    During the conversion process:
    • The manual service record is moved from the Manual Services [cmdb_ci_service_manual] table to the Mapped Application Service [cmdb_ci_service_discovered] table by changing the record class.
    • All the original manual service attributes, such as, name, owner, and operational status, are retained in the application services.
    • The configuration items (CIs) of the manual service are retained in the application services after the conversion.
    • The system queries the CMDB for the latest CI changes and applies CI impact rules.
    The maximum number of CI connections added to application services during this operation is controlled by the sa.service.max_ci_service_population property. By default, the value is 1,000 (one thousand connections). Increasing the number of CI connections may cause performance issues. To adjust the maximum number of added CI connections, add the sa.service.max_ci_service_population property, as described in Add a system property.

    Attempting to process more CIs than the value specified in the sa.service.max_ci_service_population property causes the operation to fail.

    Run the conversion process in small chunks of approximately 10 at a time, to make it easier to pinpoint the problematic service in the event of a conversion problem.

    Application services do not support these CI types:
    • cmdb_ci_endpoint
    • cmdb_ci_translation_rule
    • cmdb_ci_config_file
    • cmdb_ci_qualifier
    • cmdb_ci_application_cluster
    If the preceding CI types are used in the manual service that you want to convert, the conversion fails. CIs of this type should be removed before conversion. They can be replaced by adding new CIs to the application services after conversion.

    If your ServiceNow instance uses domain separation, the conversion fails if CIs from multiple domains are in the same service. Replace or remove relevant CIs before conversion. The converted application services contains only CIs assigned to the same domain as the application services.

    The JavaScript API is:

    BusinessServiceManager.migrateManualToApplicationService(String service_id)
    Table 1. Parameters
    Name Type Description
    service_id String sys_id of the manual service to be converted
    Table 2. Returns
    Type Description
    Boolean true for a successful conversion, false for a conversion that failed
    Where the sys_id of an existing manual service is 451047c6c0a8016400de0ae6df9b9d76, run the following API to convert it to an application services:
    var bsManager = new SNC.BusinessServiceManager();
    var res = bsManager.migrateManualToApplicationService("451047c6c0a8016400de0ae6df9b9d76");