@Override
    public int update(final RoleDTO roleDTO) {
        final RoleDO before = roleMapper.selectById(roleDTO.getId());
        final RoleDO role = RoleDO.buildRoleDO(roleDTO);
        final int updateCount = roleMapper.updateSelective(role);
        if (updateCount > 0) {
            // add new permission
            roleEventPublisher.onUpdated(role, before, roleDTO.getCurrentPermissionIds());
        }
        return updateCount;
    }
create or update role info.

@param roleDTO {@linkplain RoleDTO}
@return rows
shenyu-admin/src/main/java/org/apache/shenyu/admin/service/impl/RoleServiceImpl.java