LOG.debug("createOutput [{0}] [{1}] [{2}]", name, context, path);
if (fileExists(name)) {
throw new IOException("File [" + name + "] already exists found.");
}
final FSDataOutputStream outputStream = fileSystem.create(getPath(name));
return new BufferedIndexOutput() {
@Override
public long length() throws IOException {
return outputStream.getPos();
}