public static boolean isValidPortsSet(int brokerPort, int brokerTlsPort,
            int brokerWebPort, StringBuilder strBuff,
            ProcessResult result) {
        if (brokerPort == brokerWebPort || brokerTlsPort == brokerWebPort) {
            result.setFailResult(DataOpErrCode.DERR_ILLEGAL_VALUE.getCode(),
                    strBuff.append(DataOpErrCode.DERR_CONFLICT_VALUE.getDescription())
                            .append(", the value of ")
                            .append(WebFieldDef.BROKERPORT.name).append(" or ")
                            .append(WebFieldDef.BROKERTLSPORT.name)
                            .append(" cannot be the same as the value of ")
                            .append(WebFieldDef.BROKERWEBPORT.name).toString());
            strBuff.delete(0, strBuff.length());
            return result.isSuccess();
        }
        return true;
    }
Compare the configured ports for conflicts

@param brokerPort     broker port
@param brokerTlsPort  broker tls port
@param brokerWebPort  broker web port
@param strBuff        string buffer
@param result     check result of parameter value
@return   true for valid, false for invalid
inlong-tubemq/tubemq-server/src/main/java/org/apache/inlong/tubemq/server/common/utils/WebParameterUtils.java