silentbalanceyh/vertx-zero

View on GitHub

Showing 9,050 of 9,050 total issues

Method hashCode has 44 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((this.key == null) ? 0 : this.key.hashCode());

    Method toString has 44 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        @Override
        public String toString() {
            StringBuilder sb = new StringBuilder("EIdentity (");
    
            sb.append(key);

      Method diff has 44 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          static List<XActivityChange> diff(final JsonObject recordO, final JsonObject recordN,
                                            final HAtom atom) {
              final ChangeFlag flag = Ut.aiFlag(recordN, recordO);
              final List<XActivityChange> changes = new ArrayList<>();
              if (ChangeFlag.NONE != flag) {

        Method prepare has 44 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            @SuppressWarnings("all")
            static Criteria prepare(final DataAtom atom, final Criteria criteria) {
                /*
                 * Reference collection
                 * 1. Attribute must be Elementary

          Method argumentT has a Cognitive Complexity of 14 (exceeds 5 allowed). Consider refactoring.
          Open

              private Object argumentT(final ProceedingJoinPoint point) {
                  final Object[] args = point.getArgs();
                  if (1 == args.length) {
                      final Object input = args[0];
                      if (Objects.isNull(input)) {

          Cognitive Complexity

          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

          A method's cognitive complexity is based on a few simple rules:

          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
          • Code is considered more complex for each "break in the linear flow of the code"
          • Code is considered more complex when "flow breaking structures are nested"

          Further reading

          Method complex has a Cognitive Complexity of 14 (exceeds 5 allowed). Consider refactoring.
          Open

              static <T> Future<T> complex(final T input, final Predicate<T> predicate, final Supplier<Future<T>> executor) {
                  if (Objects.isNull(input)) {
                      return To.future(null);
                  } else {
                      if (Objects.isNull(executor)) {
          Severity: Minor
          Found in vertx-gaia/vertx-up/src/main/java/io/vertx/up/unity/Complex.java - About 1 hr to fix

          Cognitive Complexity

          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

          A method's cognitive complexity is based on a few simple rules:

          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
          • Code is considered more complex for each "break in the linear flow of the code"
          • Code is considered more complex when "flow breaking structures are nested"

          Further reading

          Method nativeBridgeMethod has a Cognitive Complexity of 14 (exceeds 5 allowed). Consider refactoring.
          Open

              private static Set<Method> nativeBridgeMethod(final Class<?> clazz) {
                  final Method[] methods = clazz.getDeclaredMethods();
                  final Set<Method> methodSet = new HashSet<>();
                  for (final Method method : methods) {
                      /*
          Severity: Minor
          Found in vertx-gaia/vertx-up/src/main/java/io/vertx/up/unity/Atomic.java - About 1 hr to fix

          Cognitive Complexity

          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

          A method's cognitive complexity is based on a few simple rules:

          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
          • Code is considered more complex for each "break in the linear flow of the code"
          • Code is considered more complex when "flow breaking structures are nested"

          Further reading

          Method invokeMulti has a Cognitive Complexity of 14 (exceeds 5 allowed). Consider refactoring.
          Open

              static Object invokeMulti(final Object proxy,
                                        final Method method,
                                        final Envelop envelop) {
                  /*
                   * One type dynamic here

          Cognitive Complexity

          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

          A method's cognitive complexity is based on a few simple rules:

          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
          • Code is considered more complex for each "break in the linear flow of the code"
          • Code is considered more complex when "flow breaking structures are nested"

          Further reading

          Method to has a Cognitive Complexity of 14 (exceeds 5 allowed). Consider refactoring.
          Open

              @Override
              public Instant to(final Object value, final Class<?> type) {
                  if (Objects.isNull(value)) {
                      /*
                       * Null

          Cognitive Complexity

          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

          A method's cognitive complexity is based on a few simple rules:

          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
          • Code is considered more complex for each "break in the linear flow of the code"
          • Code is considered more complex when "flow breaking structures are nested"

          Further reading

          Method partData has a Cognitive Complexity of 14 (exceeds 5 allowed). Consider refactoring.
          Open

              private void partData(final Envelop envelop) {
                  final JsonObject rawJson = envelop.data();
                  if (!Ut.isNil(rawJson)) {
                      final long counter = rawJson.fieldNames().stream()
                          .filter(KWeb.MULTI.INDEXES::containsValue)

          Cognitive Complexity

          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

          A method's cognitive complexity is based on a few simple rules:

          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
          • Code is considered more complex for each "break in the linear flow of the code"
          • Code is considered more complex when "flow breaking structures are nested"

          Further reading

          Method valueToJson has a Cognitive Complexity of 14 (exceeds 5 allowed). Consider refactoring.
          Open

              static void valueToJson(final ClusterSerializable json, final String field) {
                  if (json instanceof JsonArray) {
                      // Fix: 11
                      final JsonArray array = (JsonArray) json;
                      HIter.itJArray(array).forEach(item -> valueToJson(item, field));
          Severity: Minor
          Found in vertx-gaia/vertx-ams/src/main/java/io/horizon/util/TValue.java - About 1 hr to fix

          Cognitive Complexity

          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

          A method's cognitive complexity is based on a few simple rules:

          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
          • Code is considered more complex for each "break in the linear flow of the code"
          • Code is considered more complex when "flow breaking structures are nested"

          Further reading

          Method toNumeric has a Cognitive Complexity of 14 (exceeds 5 allowed). Consider refactoring.
          Open

              static Object toNumeric(final Cell cell) {
                  if (CellType.NUMERIC == cell.getCellType()) {
                      if (DateUtil.isCellDateFormatted(cell)) {
                          final double cellValue = cell.getNumericCellValue();
                          if (DateUtil.isValidExcelDate(cellValue)) {

          Cognitive Complexity

          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

          A method's cognitive complexity is based on a few simple rules:

          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
          • Code is considered more complex for each "break in the linear flow of the code"
          • Code is considered more complex when "flow breaking structures are nested"

          Further reading

          Method saveEntity has a Cognitive Complexity of 14 (exceeds 5 allowed). Consider refactoring.
          Open

              <T> T saveEntity(final JsonObject data, final ExTable table) {
                  T reference = null;
                  if (Objects.nonNull(table.classPojo()) && Objects.nonNull(table.classDao())) {
                      /*
                       * First, find the record by unique filters that defined in business here.

          Cognitive Complexity

          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

          A method's cognitive complexity is based on a few simple rules:

          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
          • Code is considered more complex for each "break in the linear flow of the code"
          • Code is considered more complex when "flow breaking structures are nested"

          Further reading

          Method values has 14 arguments (exceeds 4 allowed). Consider refactoring.
          Open

              public LStateRecord values(String value1, String value2, String value3, String value4, String value5, Integer value6, String value7, Boolean value8, String value9, String value10, LocalDateTime value11, String value12, LocalDateTime value13, String value14) {

            Method dwarfUniform has a Cognitive Complexity of 14 (exceeds 5 allowed). Consider refactoring.
            Open

                private static <T> void dwarfUniform(final Envelop envelop,
                                                     final T hitted,
                                                     final Set<RegionType> expected,
                                                     final BiConsumer<JsonObject, RegionType> consumer) {
                    if (Objects.nonNull(hitted)) {

            Cognitive Complexity

            Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

            A method's cognitive complexity is based on a few simple rules:

            • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
            • Code is considered more complex for each "break in the linear flow of the code"
            • Code is considered more complex when "flow breaking structures are nested"

            Further reading

            Method values has 14 arguments (exceeds 4 allowed). Consider refactoring.
            Open

                public MyTplRecord values(String value1, String value2, String value3, String value4, String value5, String value6, Boolean value7, String value8, String value9, String value10, LocalDateTime value11, String value12, LocalDateTime value13, String value14) {

              Method values has 14 arguments (exceeds 4 allowed). Consider refactoring.
              Open

                  public MyDesktopRecord values(String value1, String value2, String value3, String value4, String value5, String value6, Boolean value7, String value8, String value9, String value10, LocalDateTime value11, String value12, LocalDateTime value13, String value14) {

                Method values has 14 arguments (exceeds 4 allowed). Consider refactoring.
                Open

                    public FCurrencyRecord values(String value1, String value2, String value3, String value4, Integer value5, Integer value6, String value7, String value8, Boolean value9, String value10, LocalDateTime value11, String value12, LocalDateTime value13, String value14) {

                  Method values has 14 arguments (exceeds 4 allowed). Consider refactoring.
                  Open

                      public MKeyRecord values(String value1, String value2, String value3, String value4, String value5, String value6, String value7, String value8, Boolean value9, String value10, LocalDateTime value11, String value12, LocalDateTime value13, String value14) {

                    Method values has 14 arguments (exceeds 4 allowed). Consider refactoring.
                    Open

                        public MAccRecord values(String value1, String value2, String value3, String value4, String value5, String value6, String value7, String value8, Boolean value9, String value10, LocalDateTime value11, String value12, LocalDateTime value13, String value14) {
                      Severity
                      Category
                      Status
                      Source
                      Language