git.net

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RS group related hooks


Hi,
I was looking at RSGroupAdminServer#removeRSGroup :

      if (master.getMasterCoprocessorHost() != null) {

        master.getMasterCoprocessorHost().preRemoveRSGroup(name);

      }
However, RSGroupAdminServer#removeRSGroup is called by RSGroupAdminEndpoint
:

        checkPermission("removeRSGroup");
        groupAdminServer.removeRSGroup(request.getRSGroupName());

Meaning, if permission check fails, the pre hook wouldn't be called.

I wonder if the call to preRemoveRSGroup() should be lifted to before
calling checkPermission().

Cheers