Fix deregister message timing

Deregister message was not sent in time before participant shutdown

Issue-ID: POLICY-4499
Change-Id: If830299e15d784df589b83d9e3e2e0aa20289df7
Signed-off-by: saul.gill <saul.gill@est.tech>
diff --git a/participant/participant-intermediary/src/main/java/org/onap/policy/clamp/acm/participant/intermediary/handler/ParticipantHandler.java b/participant/participant-intermediary/src/main/java/org/onap/policy/clamp/acm/participant/intermediary/handler/ParticipantHandler.java
index bf9fbbc..ff96779 100644
--- a/participant/participant-intermediary/src/main/java/org/onap/policy/clamp/acm/participant/intermediary/handler/ParticipantHandler.java
+++ b/participant/participant-intermediary/src/main/java/org/onap/policy/clamp/acm/participant/intermediary/handler/ParticipantHandler.java
@@ -172,9 +172,8 @@
     public void sendParticipantDeregister() {
         var participantDeregister = new ParticipantDeregister();
         participantDeregister.setParticipantId(participantId);
-
-        undeployInstancesOnParticipant();
         publisher.sendParticipantDeregister(participantDeregister);
+        undeployInstancesOnParticipant();
     }
 
     private void undeployInstancesOnParticipant() {