@Override public Map<String, String> getOutputFormatConfiguration() { if (isExternal) { throw new UnsupportedOperationException( "Output is not supported for external file set '" + spec.getName() + "'"); } Map<String, String> config = new HashMap<>(); config.putAll(FileSetProperties.getOutputProperties(spec.getProperties())); if (outputLocation != null) { config.put(FileOutputFormat.OUTDIR, getFileSystemPath(outputLocation)); } // runtime arguments may override the permissions property Map<String, String> outputArguments = FileSetProperties.getOutputProperties(runtimeArguments); String outputPermissions = FileSetProperties.getFilePermissions(outputArguments); if (outputPermissions == null) { outputPermissions = this.permissions; } if (outputPermissions != null) { config.put(HADOOP_UMASK_PROPERTY, FileUtils.permissionsToUmask(outputPermissions)); } config.putAll(outputArguments); return config; }
@Override public Map<String, String> getOutputFormatConfiguration() { if (isExternal) { throw new UnsupportedOperationException( "Output is not supported for external file set '" + spec.getName() + "'"); } Map<String, String> config = new HashMap<>(); config.putAll(FileSetProperties.getOutputProperties(spec.getProperties())); if (outputLocation != null) { config.put(FileOutputFormat.OUTDIR, getFileSystemPath(outputLocation)); } // runtime arguments may override the permissions property Map<String, String> outputArguments = FileSetProperties.getOutputProperties(runtimeArguments); String outputPermissions = FileSetProperties.getFilePermissions(outputArguments); if (outputPermissions == null) { outputPermissions = this.permissions; } if (outputPermissions != null) { config.put(HADOOP_UMASK_PROPERTY, FileUtils.permissionsToUmask(outputPermissions)); } config.putAll(outputArguments); return config; }
this.outputFormatClassName = secondIfFirstIsNull(FileSetProperties.getOutputFormat(runtimeArguments), FileSetProperties.getOutputFormat(spec.getProperties())); this.permissions = secondIfFirstIsNull(FileSetProperties.getFilePermissions(runtimeArguments), FileSetProperties.getFilePermissions(spec.getProperties()));
this.outputFormatClassName = secondIfFirstIsNull(FileSetProperties.getOutputFormat(runtimeArguments), FileSetProperties.getOutputFormat(spec.getProperties())); this.permissions = secondIfFirstIsNull(FileSetProperties.getFilePermissions(runtimeArguments), FileSetProperties.getFilePermissions(spec.getProperties()));
"Base location for file set '%s' at %s already exists", spec.getName(), baseLocation)); String permissions = FileSetProperties.getFilePermissions(spec.getProperties()); String group = FileSetProperties.getFileGroup(spec.getProperties()); if (group == null) {
"Base location for file set '%s' at %s already exists", spec.getName(), baseLocation)); String permissions = FileSetProperties.getFilePermissions(spec.getProperties()); String group = FileSetProperties.getFileGroup(spec.getProperties()); if (group == null) {