Brandon DeVries created NIFI-5713: ------------------------------------- Summary: MergeContent improperly changing mime.type Key: NIFI-5713 URL: https://issues.apache.org/jira/browse/NIFI-5713 Project: Apache NiFi Issue Type: Bug Affects Versions: 1.7.1 Reporter: Brandon DeVries
MergeContent in "Binary Concatenation" mode will replace an existing "mime.type" attribute with "application/octet-stream" unless mime.type is set on the first FlowFile merged, even if "Attribute Strategy" is "Keep All Unique Attributes". Perhaps rather than pulling the mime.type from the "merger"[2], it should check the "bundleAttributes"[3] first. if no mime.type is specified there, then perhaps "octet-stream" is a good default. Additionally, regardless of whatever implementation choices are made in the determination of the mime.type, the "WritesAttribute" documentation should be updated to indicate that mime.type is being set... [1] [https://github.com/apache/nifi/blob/ea9b0db2f620526c8dd0db595cf8b44c3ef835be/nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors/src/main/java/org/apache/nifi/processors/standard/MergeContent.java#L621-L629] [2] [https://github.com/apache/nifi/blob/ea9b0db2f620526c8dd0db595cf8b44c3ef835be/nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors/src/main/java/org/apache/nifi/processors/standard/MergeContent.java#L502] [2] [https://github.com/apache/nifi/blob/ea9b0db2f620526c8dd0db595cf8b44c3ef835be/nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors/src/main/java/org/apache/nifi/processors/standard/MergeContent.java#L501] -- This message was sent by Atlassian JIRA (v7.6.3#76005)