NIFI-7600 - Defining JMS attribute types breaks due to invalid charac…#4385
NIFI-7600 - Defining JMS attribute types breaks due to invalid charac…#4385dazhitchman wants to merge 1 commit into
Conversation
|
@dazhitchman Thanks for this! I was just thinking about this over the weekend and it's definitely needed. One question: should it be so broad as to remove anything ending in '.type' or would it make sense to do something more narrow? E.g., I always see this with |
| } else { | ||
| // not a special attribute handled above, so send it as a property using the specified property type | ||
| String key=entry.getKey(); | ||
| if (key.endsWith(".type")){ |
There was a problem hiding this comment.
If we go broad and apply this to anything ending in '.type' I think it deserves a WARN.
|
Hi Joey
I think that opens up others issues. NIFI uses attributes for both data (to augment content) and metadata to control behaviour. In the JMS example, there is no valid JMS field for “JMS_IBM_Encoding.type” , it is just used to help the processor build the headers so it shouldn’t leak from the processor. The mime type however is used by downstream applications like a web/email server so they should be passed along. I am new to NIFI though so happy to take advice.
Darren
… On 7 Jul 2020, at 5:23 am, Joey ***@***.***> wrote:
@jfrazee commented on this pull request.
In nifi-nar-bundles/nifi-jms-bundle/nifi-jms-processors/src/main/java/org/apache/nifi/jms/processors/JMSPublisher.java <#4385 (comment)>:
> @@ -108,6 +108,13 @@ void setMessageHeaderAndProperties(final Session session, final Message message,
}
} else {
// not a special attribute handled above, so send it as a property using the specified property type
+ String key=entry.getKey();
+ if (key.endsWith(".type")){
If we go broad and apply this to anything ending in '.type' I think it deserves a WARN.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub <#4385 (review)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AOLUPLLFJR7ULDX764J72EDR2IQC5ANCNFSM4ORGHSFQ>.
|
|
We're marking this PR as stale due to lack of updates in the past few months. If after another couple of weeks the stale label has not been removed this PR will be closed. This stale marker and eventual auto close does not indicate a judgement of the PR just lack of reviewer bandwidth and helps us keep the PR queue more manageable. If you would like this PR re-opened you can do so and a committer can remove the stale tag. Or you can open a new PR. Try to help review other PRs to increase PR review bandwidth which in turn helps yours. |
…ters
Thank you for submitting a contribution to Apache NiFi.
Please provide a short description of the PR here:
Description of PR
fixes bug NIFI-7600. _
Removed '.type' attributes being added to JMS properties. These attributes act only as meta data and cause JMS Exceptions as they contain invalid characters (e.g. the dot)
In order to streamline the review of the contribution we ask you
to ensure the following steps have been taken:
For all changes:
Is there a JIRA ticket associated with this PR? Is it referenced
in the commit message?
Does your PR title start with NIFI-XXXX where XXXX is the JIRA number you are trying to resolve? Pay particular attention to the hyphen "-" character.
Has your PR been rebased against the latest commit within the target branch (typically
master)?Is your initial contribution a single, squashed commit? Additional commits in response to PR reviewer feedback should be made on this branch and pushed to allow change tracking. Do not
squashor use--forcewhen pushing to allow for clean monitoring of changes.For code changes:
mvn -Pcontrib-check clean installat the rootnififolder?LICENSEfile, including the mainLICENSEfile undernifi-assembly?NOTICEfile, including the mainNOTICEfile found undernifi-assembly?.displayNamein addition to .name (programmatic access) for each of the new properties?For documentation related changes:
Note:
Please ensure that once the PR is submitted, you check GitHub Actions CI for build issues and submit an update to your PR as soon as possible.