Skip to content

NIFI-3133: Ensure correct checks against Remote Group Ports#1297

Closed
mcgilman wants to merge 9 commits intoapache:masterfrom
mcgilman:NIFI-3133
Closed

NIFI-3133: Ensure correct checks against Remote Group Ports#1297
mcgilman wants to merge 9 commits intoapache:masterfrom
mcgilman:NIFI-3133

Conversation

@mcgilman
Copy link
Contributor

@mcgilman mcgilman commented Dec 5, 2016

  • Ensuring that Remote Group Ports are always authorized according to their Remote Process Group.

- Ensuring that Remote Group Ports are always authorized according to their Remote Process Group.
- Using getSourceAuthorizable() when accessing flow files and content.
@JPercivall
Copy link
Contributor

Reviewing

- Decouple local and remote connectable's to avoid ambiguity with self referencing RPGs.

final RemoteGroupPort remoteGroupPort = getRootGroup().findRemoteGroupPort(remoteGroupPortId);
if (remoteGroupPort == null) {
throw new ResourceNotFoundException("The component that generated this event is no longer part of the data flow.");
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think there is a bit of copy paste error with this Exception message. My understanding is that this method is not limited to an "event".

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With the refactoring it is just events. However, there is still one spot that is unused that can now be removed. I'll update.

}

final RemoteGroupPort remoteGroupPort = root.findRemoteGroupPort(dto.getComponentId());
if (connectable != null) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like a copy/paste error, this should check "remoteGroupPort"

- Addressing comments from the PR.
- Fixed check verifying source/destination when creating a connection.
- Only showing the go to link when the source component is not a remote port.
- Removing unnecessary checking of remote group port authorization since it's handled by the parent RPG.
- Fixing issue showing the connection details dialog when the source component is a RPG.
- Ensuring the local connectable was found.
@JPercivall
Copy link
Contributor

+1

Visually verified code and did a contrib-check build. In a secure 3 node cluster ran through a number of tests involving RPGs, Input/Output ports and policies. I also ran a standalone instance to verify nothing there regressed. Everything worked as expected.

Thanks @mcgilman I will squash and merge.

@asfgit asfgit closed this in 2d6bba0 Dec 6, 2016
dstreev pushed a commit to dstreev/nifi-1 that referenced this pull request Dec 9, 2016
…ccording to their Remote Process Group.

NIFI-3133:
- Using getSourceAuthorizable() when accessing flow files and content.

NIFI-3133:
- Decouple local and remote connectable's to avoid ambiguity with self referencing RPGs.

NIFI-3133:
- Addressing comments from the PR.

NIFI-3133:
- Fixed check verifying source/destination when creating a connection.

NIFI-3133:
- Only showing the go to link when the source component is not a remote port.

NIFI-3133:
- Removing unnecessary checking of remote group port authorization since it's handled by the parent RPG.

NIFI-3133:
- Fixing issue showing the connection details dialog when the source component is a RPG.

NIFI-3133:
- Ensuring the local connectable was found.

This closes apache#1297

Signed-off-by: jpercivall <JPercivall@apache.org>
dstreev pushed a commit to dstreev/nifi-1 that referenced this pull request Dec 9, 2016
…ccording to their Remote Process Group.

NIFI-3133:
- Using getSourceAuthorizable() when accessing flow files and content.

NIFI-3133:
- Decouple local and remote connectable's to avoid ambiguity with self referencing RPGs.

NIFI-3133:
- Addressing comments from the PR.

NIFI-3133:
- Fixed check verifying source/destination when creating a connection.

NIFI-3133:
- Only showing the go to link when the source component is not a remote port.

NIFI-3133:
- Removing unnecessary checking of remote group port authorization since it's handled by the parent RPG.

NIFI-3133:
- Fixing issue showing the connection details dialog when the source component is a RPG.

NIFI-3133:
- Ensuring the local connectable was found.

This closes apache#1297

Signed-off-by: jpercivall <JPercivall@apache.org>
asfgit pushed a commit that referenced this pull request Dec 15, 2016
…ccording to their Remote Process Group.

NIFI-3133:
- Using getSourceAuthorizable() when accessing flow files and content.

NIFI-3133:
- Decouple local and remote connectable's to avoid ambiguity with self referencing RPGs.

NIFI-3133:
- Addressing comments from the PR.

NIFI-3133:
- Fixed check verifying source/destination when creating a connection.

NIFI-3133:
- Only showing the go to link when the source component is not a remote port.

NIFI-3133:
- Removing unnecessary checking of remote group port authorization since it's handled by the parent RPG.

NIFI-3133:
- Fixing issue showing the connection details dialog when the source component is a RPG.

NIFI-3133:
- Ensuring the local connectable was found.

This closes #1297

Signed-off-by: jpercivall <JPercivall@apache.org>
@mcgilman mcgilman deleted the NIFI-3133 branch January 4, 2017 14:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants