public Copier setPreWriteHandler(PreWriteHandler preWriteHandler) {
            this.preWriteHandler = preWriteHandler;
            return this;
        }
Set the pre-write handler.

@param preWriteHandler  A handler that will be called before we try to write to a
                        directory.
metadata/src/main/java/org/apache/kafka/metadata/properties/MetaPropertiesEnsemble.java