From 206d7ab908459c047b6e284983178b7a16d379e0 Mon Sep 17 00:00:00 2001 From: sjing Date: Wed, 8 Feb 2012 02:27:37 +0000 Subject: [PATCH] add the logic if the daemon has already processed git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@11507 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-server/lib/xcat/plugins/hmc.pm | 8 ++++++++ xCAT-server/lib/xcat/plugins/ivm.pm | 8 ++++++++ 2 files changed, 16 insertions(+) diff --git a/xCAT-server/lib/xcat/plugins/hmc.pm b/xCAT-server/lib/xcat/plugins/hmc.pm index 2d0e8ad2f..96262b421 100644 --- a/xCAT-server/lib/xcat/plugins/hmc.pm +++ b/xCAT-server/lib/xcat/plugins/hmc.pm @@ -36,6 +36,14 @@ sub handled_commands { ########################################################################## sub preprocess_request { my ($arg1, $arg2, $arg3) = @_; + + #if already preprocessed, go straight to request + if ((defined($arg1->{_xcatpreprocessed})) + && ($arg1->{_xcatpreprocessed}->[0] == 1)) + { + return [$arg1]; + } + if ($arg1->{command}->[0] eq "gethmccon") { #Can handle it here and now my $node = $arg1->{noderange}->[0]; my $callback = $arg2; diff --git a/xCAT-server/lib/xcat/plugins/ivm.pm b/xCAT-server/lib/xcat/plugins/ivm.pm index 449a34b12..34e50e6a7 100644 --- a/xCAT-server/lib/xcat/plugins/ivm.pm +++ b/xCAT-server/lib/xcat/plugins/ivm.pm @@ -36,6 +36,14 @@ sub handled_commands { ########################################################################## sub preprocess_request { my ($arg1, $arg2, $arg3) = @_; + + #if already preprocessed, go straight to request + if ((defined($arg1->{_xcatpreprocessed})) + && ($arg1->{_xcatpreprocessed}->[0] == 1)) + { + return [$arg1]; + } + if ($arg1->{command}->[0] eq "gethmccon") { #Can handle it here and now my $node = $arg1->{noderange}->[0]; my $callback = $arg2;