public HadoopPigJob(String jobid, Props sysProps, Props jobProps, Logger log) throws IOException {
    super(jobid, sysProps, jobProps, log);

    HADOOP_SECURE_PIG_WRAPPER = HadoopSecurePigWrapper.class.getName();

    getJobProps().put(CommonJobProperties.JOB_ID, jobid);
    shouldProxy = getSysProps().getBoolean(HadoopSecurityManager.ENABLE_PROXYING, false);
    getJobProps().put(HadoopSecurityManager.ENABLE_PROXYING, Boolean.toString(shouldProxy));
    obtainTokens = getSysProps().getBoolean(HadoopSecurityManager.OBTAIN_BINARY_TOKEN, false);
    userPigJar = getJobProps().getBoolean("use.user.pig.jar", false);

    if (shouldProxy) {
      getLog().info("Initiating hadoop security manager.");
      try {
        hadoopSecurityManager = HadoopJobUtils.loadHadoopSecurityManager(getSysProps(), log);
      } catch (RuntimeException e) {
        throw new RuntimeException("Failed to get hadoop security manager!" + e);
      }
    }
  }