summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--grpc/grpc-server/src/main/java/org/open/infc/grpc/server/OpenInterfaceGrpcServer.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/grpc/grpc-server/src/main/java/org/open/infc/grpc/server/OpenInterfaceGrpcServer.java b/grpc/grpc-server/src/main/java/org/open/infc/grpc/server/OpenInterfaceGrpcServer.java
index 0c2f00b5..79d761d6 100644
--- a/grpc/grpc-server/src/main/java/org/open/infc/grpc/server/OpenInterfaceGrpcServer.java
+++ b/grpc/grpc-server/src/main/java/org/open/infc/grpc/server/OpenInterfaceGrpcServer.java
@@ -211,12 +211,14 @@ public class OpenInterfaceGrpcServer {
if (!cmd.isRpc()) {
String printOut = cmd.getResult().print();
Builder reply = Output.newBuilder();
- reply.setSuccess(true);
reply.putAttrs(OnapCommandConstants.ERROR, "{}");
if (executionStoreContext != null)
reply.putAddons("execution-id", executionStoreContext.getExecutionId());
+ // use the status from the plugin.
+ reply.setSuccess(cmd.getResult().isPassed());
+
try {
reply.putAttrs(OnapCommandConstants.RESULTS, new ObjectMapper().readTree(printOut).toString());
} catch (IOException e) {