Search Engine: Elastic

Article ID: 121202, created on Apr 21, 2014, last review on May 10, 2016


I need to change Endpoint URI of Application Instance, but there is no way of direct changing in Operations Automation PCP.


Nowadays it can be done either through APS Bus or via Operations Automation database.


The recommended way is to change it through APS Bus, but do not hurry up to apply. It has some limitation due to OSA issue #APS-14030 and requires additional manual update in OSA database. Therefore, we would recommend just to review it and jump to the second way ("Changing via OSA Database") to save the time:

1. Changing through APS Bus

Get Application Instance Token with pem.APS.getApplicationInstanceToken Public API method:

<?xml version='1.0'?>

Update Endpoint URI by sending a PUT request to APS Controller:

curl -ik "https://OSA_MN_IP:6308/aps/2/application/" -X PUT --data '{ "aps": { "endpoint": "NEW_APP_ENDPOINT_URI"} }' -H "APS-Token:APPLICATION_INSTANCE_TOKEN"

OSA_MN_IP - IP address or hostname of Operations Automation Management Node

NEW_APP_ENDPOINT_URI - typically it has a following format:

APPLICATION_INSTANCE_TOKEN - is the token you received at step 1.

As it was mentined above, due to issue #APS-14030, APS Controller does not update aps_application_instances table, in result the old Endpoint URI still shown in Application Instance settings in Operations Automation PCP. It needs to be updated manually, instructions are below.

2. Changing via OSA Database

Login to Operations Automation Management Node via SSH and access its database:

# psql -h`hostname` -Uplesk plesk

Update two tables:

plesk=> begin;
plesk=> update aps_application_instances set uri='NEW_APP_ENDPOINT_URI' where app_instance_id=ID;
plesk=> update aps_application set endpoint_uri='NEW_APP_ENDPOINT_URI' where uid='APP_INSTANCE_UID';
plesk=> commit;

app_instance_id=ID - can be obtained from Operations Automation PCP > Applications > Application name > Instances

APP_INSTANCE_UID - shown in the output of a select below

plesk=> select uuid aps_application_instances where app_instance_id=ID;

Email subscription for changes to this article
Save as PDF