protected File createTemporaryFile() throws AmbariException {
    try {
      return File.createTempFile("tmp", ".tmp", getConfiguredTemporaryDirectory());
    } catch (IOException e) {
      String message = "Failed to create a temporary file.";
      LOG.error(message, e);
      throw new AmbariException(message, e);
    }
  }
Creates a temporary file within the system temporary directory
<p/>
The resulting file is to be removed by the caller when desired.

@return a File pointing to the new temporary file, or null if one was not created
@throws AmbariException if a new temporary directory cannot be created
ambari-server/src/main/java/org/apache/ambari/server/controller/KerberosHelperImpl.java