Commit d561cb13 authored by Gary Wong's avatar Gary Wong

When assign fails, spit back all its output as the result of the SES XMLRPC

call.  There's a lot of it, but that's now the user's problem...
parent 73ab2509
...@@ -91,9 +91,15 @@ sub Map($) ...@@ -91,9 +91,15 @@ sub Map($)
print $reqfile $req; print $reqfile $req;
close $reqfile; close $reqfile;
system( "$ASSIGN -q $adfilename -w $reqfilename > /dev/null 2>&1" ) and open( ASSIGN, "$ASSIGN -q $adfilename -w $reqfilename 2>&1 |" )
return GeniResponse->Create( GENIRESPONSE_ERROR, undef, or return GeniResponse->Create( GENIRESPONSE_ERROR, undef,
"Assign process failed" ); "Assign process failed" );
my $assignverbosity = "";
while( <ASSIGN> ) {
$assignverbosity .= $_;
}
close ASSIGN;
unlink $adfilename; unlink $adfilename;
unlink $reqfilename; unlink $reqfilename;
...@@ -103,7 +109,9 @@ sub Map($) ...@@ -103,7 +109,9 @@ sub Map($)
open( ANNOTATED, "<$annfilename" ) or open( ANNOTATED, "<$annfilename" ) or
return GeniResponse->Create( GENIRESPONSE_ERROR, undef, return GeniResponse->Create( GENIRESPONSE_ERROR, undef,
"Could not read assign output" ); "Failed to map topolgy:\n" .
$assignverbosity );
my $xml = ""; my $xml = "";
while ( <ANNOTATED> ) { while ( <ANNOTATED> ) {
$xml .= $_; $xml .= $_;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment