Symptoms

On attempt to remove Office365 instance, the following errors can occur:


Case #1

Error message from PCP side

Service can not be removed, it belongs to resource type "XXXXXX Office 365 Global Settings" with ID #XXXXX.


Case #2

The task "Forced unprovisioning "Office365Application" for APS application Office 365"  failed/rescheduled with 

Internal error: SDK::Platform::blob Plesk::SaaS::SaaSManagerTasks_impl::taskExecuteWorkflow(const SDK::Platform::Properties&) : [APSC] Unprovisioning: resource 5555e55e-4d44-3333-8fa8-77d7777ca77 of type 'office365app' (http://www.parallels.com/Office365/Office365app/2.6) for APS application 'Office 365-19.3-315': ERROR: update or delete on table "aps_application" violates foreign key constraint "FK_aps_resource_aps_application" on table "aps_resource"
DETAIL: Key (id)=(24174) is still referenced from table "aps_resource".
._____Common_____1



Cause

Case #1

There are Office 365 resources exist and belong to active Service Plans.


Case #2

Inconsistency from the DB exist due to a cancelled tasks in the past or another reason.

Error in core.log shows

Jan 17 12:08:03.149 : ERR [task:1528042:88034 1:21326:7f1b377be700 SAAS 2074660641]: [ APSC] ApplicationDBO::remove catch APS Controller exception:ERROR:  update or delete on table "aps_application" violates foreign key constraint "FK_aps_resource_aps_application" on table "aps_resource"
DETAIL:  Key (id)=(24174) is still referenced from table "aps_resource".
Jan 17 12:08:03.149 : DBG [task:1528042:88034 1:21326:7f1b377be700 SAAS 2074660641]: [ APSC] Rolling back because of std::uncaught_exception()



Resolution

Case #1

In order to Uninstall Office365 instance, it's required to remove resources:

1) All resources related to Office365 Service Plans that are belong to Office 365 Instance.

2)  XXXX: Office 365 Globa Settings resource.

3) Uninstall the instance.


Case #2

Please contact CloudBlue Technical Support to fix the inconsistency and remove Office 365 instance. 


Internal

Internal llink