From 05dfa5fee15b191c3ee1afae0010b70733b1a35b Mon Sep 17 00:00:00 2001
From: neil_a_wilson <neil_a_wilson@localhost>
Date: Mon, 25 Jun 2007 15:51:57 +0000
Subject: [PATCH] Update the pre-parse and pre-operation plugin results to add the ability to skip core processing without skipping post-operation plugins.  Also, make sure that post-response plugins are always invoked for all operations that get far enough in their processing to have called the pre-parse plugins.

---
 opends/src/server/org/opends/server/core/CompareOperation.java |   17 +++++++++++++++++
 1 files changed, 17 insertions(+), 0 deletions(-)

diff --git a/opends/src/server/org/opends/server/core/CompareOperation.java b/opends/src/server/org/opends/server/core/CompareOperation.java
index 1b156de..30bf972 100644
--- a/opends/src/server/org/opends/server/core/CompareOperation.java
+++ b/opends/src/server/org/opends/server/core/CompareOperation.java
@@ -575,6 +575,7 @@
 
         logCompareRequest(this);
         logCompareResponse(this);
+        pluginConfigManager.invokePostResponseComparePlugins(this);
         return;
       }
       else if (preParseResult.sendResponseImmediately())
@@ -583,6 +584,11 @@
         logCompareRequest(this);
         break compareProcessing;
       }
+      else if (preParseResult.skipCoreProcessing())
+      {
+        skipPostOperation = false;
+        break compareProcessing;
+      }
 
 
       // Log the compare request message.
@@ -595,6 +601,7 @@
         indicateCancelled(cancelRequest);
         processingStopTime = System.currentTimeMillis();
         logCompareResponse(this);
+        pluginConfigManager.invokePostResponseComparePlugins(this);
         return;
       }
 
@@ -643,6 +650,7 @@
         indicateCancelled(cancelRequest);
         processingStopTime = System.currentTimeMillis();
         logCompareResponse(this);
+        pluginConfigManager.invokePostResponseComparePlugins(this);
         return;
       }
 
@@ -992,6 +1000,7 @@
           indicateCancelled(cancelRequest);
           processingStopTime = System.currentTimeMillis();
           logCompareResponse(this);
+          pluginConfigManager.invokePostResponseComparePlugins(this);
           return;
         }
 
@@ -1010,6 +1019,7 @@
 
           processingStopTime = System.currentTimeMillis();
           logCompareResponse(this);
+          pluginConfigManager.invokePostResponseComparePlugins(this);
           return;
         }
         else if (preOpResult.sendResponseImmediately())
@@ -1017,6 +1027,11 @@
           skipPostOperation = true;
           break compareProcessing;
         }
+        else if (preOpResult.skipCoreProcessing())
+        {
+          skipPostOperation = false;
+          break compareProcessing;
+        }
 
 
         // Get the base attribute type and set of options.
@@ -1114,6 +1129,7 @@
       indicateCancelled(cancelRequest);
       processingStopTime = System.currentTimeMillis();
       logCompareResponse(this);
+      pluginConfigManager.invokePostResponseComparePlugins(this);
       return;
     }
 
@@ -1132,6 +1148,7 @@
 
         processingStopTime = System.currentTimeMillis();
         logCompareResponse(this);
+        pluginConfigManager.invokePostResponseComparePlugins(this);
         return;
       }
     }

--
Gitblit v1.10.0