Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
None
-
None
-
None
-
Incompatible change, Reviewed
-
With run/exec command, parameters are now scoped and caller would not see the parameters declared within the callee's scripts.
Description
After PIG-3359, pig param substitution became global in that parameter declared in the pig script called from run or exec would live after that script finishes.
This created an interesting situation.
test1.pig
exec -param output=/tmp/deleteme111 test1_1.pig exec -param output=/tmp/deleteme222 test1_1.pig
test1_1.pig
%default myout '$output.out'; A = load 'input.txt' as (a0:int); store A into '$myout';
Running test1.pig would try to run two jobs that both tries to write to /tmp/deleteme111 and fail. (Second param output=/tmp/deleteme222 is ignored.)