Today, I found there’s a way to set the job name for your pig script.
PigServer pig=*new* PigServer(ExecType.*MAPREDUCE*);
This is useful when you share cluster with other people, or you want to
submit more than one scripts to cluster. Providing job name can help you
monitor your job in jobtracker easier.
Hope this is useful for you.