-
Notifications
You must be signed in to change notification settings - Fork 59
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: further refactoring for code health improvement #406
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ Code Health Quality Gates: OK
- Declining Code Health: 0 findings(s) 🚩
- Improving Code Health: 6 findings(s) ✅
- Affected Hotspots: 1 files(s) 🔥
Recommended Review Level: Lightweight sanity check
View detailed results in CodeScene
✅ Improving Code Health:
- Complex Method SchemaGeneratorMojo.java: execute 🔥
- Complex Method SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: execute 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: setOptions 🔥
- Overall Code Complexity SchemaGeneratorMojo.java 🔥
...en-plugin/src/main/java/com/github/victools/jsonschema/plugin/maven/SchemaGeneratorMojo.java
Show resolved
Hide resolved
...en-plugin/src/main/java/com/github/victools/jsonschema/plugin/maven/SchemaGeneratorMojo.java
Show resolved
Hide resolved
...en-plugin/src/main/java/com/github/victools/jsonschema/plugin/maven/SchemaGeneratorMojo.java
Show resolved
Hide resolved
...en-plugin/src/main/java/com/github/victools/jsonschema/plugin/maven/SchemaGeneratorMojo.java
Show resolved
Hide resolved
...en-plugin/src/main/java/com/github/victools/jsonschema/plugin/maven/SchemaGeneratorMojo.java
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ Code Health Quality Gates: OK
- Declining Code Health: 0 findings(s) 🚩
- Improving Code Health: 6 findings(s) ✅
- Affected Hotspots: 1 files(s) 🔥
Recommended Review Level: Lightweight sanity check
View detailed results in CodeScene
✅ Improving Code Health:
- Complex Method SchemaGeneratorMojo.java: execute 🔥
- Complex Method SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: execute 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: setOptions 🔥
- Overall Code Complexity SchemaGeneratorMojo.java 🔥
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
❌ Code Health Quality Gates: FAILED
- Declining Code Health: 1 findings(s) 🚩
- Improving Code Health: 12 findings(s) ✅
- Affected Hotspots: 1 files(s) 🔥
Recommended Review Level: Lightweight sanity check
View detailed results in CodeScene
🚩 Declining Code Health (highest to lowest):
- Complex Method SchemaGenerationContextImpl.java: collectStaticMembers
✅ Improving Code Health:
- Complex Method SchemaGenerationContextImpl.java: traverseGenericType
- Complex Method SchemaGenerationContextImpl.java: generateArrayDefinition
- Complex Method SchemaGenerationContextImpl.java: collectObjectProperties
- Complex Conditional SchemaGenerationContextImpl.java: traverseGenericType
- Complex Conditional SchemaGenerationContextImpl.java: collectObjectProperties
- Excess Number of Function Arguments SchemaGenerationContextImpl.java: applyReferenceDefinition
- Complex Method SchemaGeneratorMojo.java: execute 🔥
- Complex Method SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: execute 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: setOptions 🔥
- Overall Code Complexity SchemaGeneratorMojo.java 🔥
...src/main/java/com/github/victools/jsonschema/generator/impl/SchemaGenerationContextImpl.java
Show resolved
Hide resolved
...src/main/java/com/github/victools/jsonschema/generator/impl/SchemaGenerationContextImpl.java
Show resolved
Hide resolved
...src/main/java/com/github/victools/jsonschema/generator/impl/SchemaGenerationContextImpl.java
Show resolved
Hide resolved
...src/main/java/com/github/victools/jsonschema/generator/impl/SchemaGenerationContextImpl.java
Show resolved
Hide resolved
private Map.Entry<ObjectNode, Boolean> applyReferencedCustomDefinition(CustomDefinition customDefinition, ResolvedType targetType, | ||
ObjectNode targetNode, boolean isNullable, CustomDefinitionProviderV2 ignoredDefinitionProvider) { | ||
ObjectNode definition = this.generatorConfig.createObjectNode(); | ||
this.putDefinition(targetType, definition, ignoredDefinitionProvider); | ||
this.addReference(targetType, targetNode, ignoredDefinitionProvider, isNullable); | ||
this.markDefinitionAsNeverInlinedIfRequired(customDefinition, targetType, ignoredDefinitionProvider); | ||
logger.debug("applying configured custom definition for {}", targetType); | ||
definition.setAll(customDefinition.getValue()); | ||
return new AbstractMap.SimpleEntry<>(definition, customDefinition.shouldIncludeAttributes()); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ℹ New issue: Excess Number of Function Arguments
applyReferencedCustomDefinition has 5 arguments, threshold = 4
Why does this problem occur?
This function has too many arguments, indicating a lack of encapsulation. Avoid adding more arguments. Read more.
private Map.Entry<ObjectNode, Boolean> applyStandardDefinition(boolean shouldInlineDefinition, TypeScope scope, ObjectNode targetNode, | ||
boolean isNullable, CustomDefinitionProviderV2 ignoredDefinitionProvider) { | ||
ResolvedType targetType = scope.getType(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ℹ New issue: Excess Number of Function Arguments
applyStandardDefinition has 5 arguments, threshold = 4
Why does this problem occur?
This function has too many arguments, indicating a lack of encapsulation. Avoid adding more arguments. Read more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ Code Health Quality Gates: OK
- Declining Code Health: 0 findings(s) 🚩
- Improving Code Health: 12 findings(s) ✅
- Affected Hotspots: 1 files(s) 🔥
Recommended Review Level: Lightweight sanity check
View detailed results in CodeScene
✅ Improving Code Health:
- Complex Method SchemaGenerationContextImpl.java: traverseGenericType
- Complex Method SchemaGenerationContextImpl.java: generateArrayDefinition
- Complex Method SchemaGenerationContextImpl.java: collectObjectProperties
- Complex Conditional SchemaGenerationContextImpl.java: traverseGenericType
- Complex Conditional SchemaGenerationContextImpl.java: collectObjectProperties
- Excess Number of Function Arguments SchemaGenerationContextImpl.java: applyReferenceDefinition
- Complex Method SchemaGeneratorMojo.java: execute 🔥
- Complex Method SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: execute 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: setOptions 🔥
- Overall Code Complexity SchemaGeneratorMojo.java 🔥
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
❌ Code Health Quality Gates: FAILED
- Declining Code Health: 1 findings(s) 🚩
- Improving Code Health: 32 findings(s) ✅
- Affected Hotspots: 2 files(s) 🔥
Recommended Review Level: Lightweight sanity check
View detailed results in CodeScene
Absence of Expected Change Pattern
- jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/SchemaGeneratorConfig.java is usually changed with: jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/impl/SchemaGeneratorConfigImpl.java
- jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/MethodScope.java is usually changed with: jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/FieldScope.java
🚩 Declining Code Health (highest to lowest):
- Overall Code Complexity GlobHandler.java
✅ Improving Code Health:
- Overall Code Complexity SchemaBuilder.java
- Overall Code Complexity JakartaValidationModule.java
- Complex Method GlobHandler.java: convertGlobToRegex
- Complex Method SchemaGenerationContextImpl.java: populateMethodSchema
- Complex Method SchemaGenerationContextImpl.java: populateFieldSchema
- Complex Method SchemaGenerationContextImpl.java: traverseGenericType
- Complex Conditional JakartaValidationModule.java: overrideInstanceAttributes
- Complex Method GlobHandler.java: createClassOrPackageNamePattern
- Complex Method SchemaGenerationContextImpl.java: generateArrayDefinition
- Complex Method SchemaGenerationContextImpl.java: collectObjectProperties
- Bumpy Road Ahead SchemaBuilder.java: buildDefinitionsAndResolveReferences
- Complex Method SchemaBuilder.java: buildDefinitionsAndResolveReferences
- Excess Number of Function Arguments SchemaGenerationContextImpl.java: applyReferenceDefinition
- Complex Method MethodScope.java: doFindGetterField
- Bumpy Road Ahead MethodScope.java: doFindGetterField
- Complex Conditional SchemaGenerationContextImpl.java: traverseGenericType
- Complex Conditional SchemaGenerationContextImpl.java: collectObjectProperties
- Complex Conditional SchemaGenerationContextImpl.java: populateMemberSchemaWithReference
- Bumpy Road Ahead GlobHandler.java: convertGlobToRegex
- Deep, Nested Complexity GlobHandler.java: convertGlobToRegex
- Complex Method SchemaGeneratorMojo.java: execute 🔥
- Complex Method SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: execute 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: setOptions 🔥
- Overall Code Complexity SchemaGeneratorMojo.java 🔥
- Complex Method JacksonModule.java: applyToConfigBuilder
- Complex Method JsonSubTypesResolver.java: createSubtypeDefinition 🔥
- Complex Method JsonSubTypesResolver.java: provideCustomPropertySchemaDefinition 🔥
- Excess Number of Function Arguments JsonSubTypesResolver.java: createSubtypeDefinition 🔥
- Complex Method JakartaValidationModule.java: overrideInstanceAttributes
- Bumpy Road Ahead JakartaValidationModule.java: overrideInstanceAttributes
@@ -19,12 +19,12 @@ | |||
import com.fasterxml.jackson.databind.JsonNode; | |||
import com.fasterxml.jackson.databind.ObjectMapper; | |||
import com.github.victools.jsonschema.generator.Module; | |||
import com.github.victools.jsonschema.generator.Option; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ No longer an issue: Overall Code Complexity
The mean cyclomatic complexity in this module is no longer above the threshold
@@ -703,7 +706,7 @@ private JsonNode populateMethodSchema(MethodScope method) { | |||
typeOverrides = this.generatorConfig.resolveSubtypes(method.getType(), this); | |||
} | |||
List<MethodScope> methodOptions; | |||
if (typeOverrides == null || typeOverrides.isEmpty()) { | |||
if (Util.isNullOrEmpty(typeOverrides)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ Getting better: Complex Method
populateMethodSchema decreases in cyclomatic complexity from 10 to 9, threshold = 9
Why does this problem occur?
This function has many conditional statements (e.g. if, for, while), leading to lower code health. Avoid adding more conditionals and code to it without refactoring. Read more.
@@ -622,7 +625,7 @@ private ObjectNode populateFieldSchema(FieldScope field) { | |||
typeOverrides = this.generatorConfig.resolveSubtypes(field.getType(), this); | |||
} | |||
List<FieldScope> fieldOptions; | |||
if (typeOverrides == null || typeOverrides.isEmpty()) { | |||
if (Util.isNullOrEmpty(typeOverrides)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ Getting better: Complex Method
populateFieldSchema decreases in cyclomatic complexity from 10 to 9, threshold = 9
Why does this problem occur?
This function has many conditional statements (e.g. if, for, while), leading to lower code health. Avoid adding more conditionals and code to it without refactoring. Read more.
final CustomDefinition customDefinition = this.generatorConfig.getCustomDefinition(targetType, this, ignoredDefinitionProvider); | ||
if (customDefinition != null && (customDefinition.isMeantToBeInline() || forceInlineDefinition)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ No longer an issue: Complex Conditional
traverseGenericType no longer has a complex conditional
if ((!includeStaticFields || hierachyType.getStaticFields().isEmpty()) | ||
&& (!includeStaticMethods || hierachyType.getStaticMethods().isEmpty())) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ No longer an issue: Complex Conditional
collectObjectProperties no longer has a complex conditional
boolean lookUpSubtypes = !this.options.contains(JacksonOption.SKIP_SUBTYPE_LOOKUP); | ||
boolean includeTypeInfoTransform = !this.options.contains(JacksonOption.IGNORE_TYPE_INFO_TRANSFORM); | ||
if (lookUpSubtypes || includeTypeInfoTransform) { | ||
JsonSubTypesResolver subtypeResolver = new JsonSubTypesResolver(this.options); | ||
if (lookUpSubtypes) { | ||
generalConfigPart.withSubtypeResolver(subtypeResolver); | ||
fieldConfigPart.withTargetTypeOverridesResolver(subtypeResolver::findTargetTypeOverrides); | ||
methodConfigPart.withTargetTypeOverridesResolver(subtypeResolver::findTargetTypeOverrides); | ||
} | ||
if (includeTypeInfoTransform) { | ||
generalConfigPart.withCustomDefinitionProvider(subtypeResolver); | ||
fieldConfigPart.withCustomDefinitionProvider(subtypeResolver::provideCustomPropertySchemaDefinition); | ||
methodConfigPart.withCustomDefinitionProvider(subtypeResolver::provideCustomPropertySchemaDefinition); | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ No longer an issue: Complex Method
applyToConfigBuilder is no longer above the threshold for cyclomatic complexity
private ObjectNode createSubtypeDefinition(ResolvedType javaType, JsonTypeInfo typeInfoAnnotation, JsonSubTypes subTypesAnnotation, | ||
ObjectNode attributesToInclude, SchemaGenerationContext context) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ No longer an issue: Complex Method
createSubtypeDefinition is no longer above the threshold for cyclomatic complexity
ObjectNode attributes; | ||
if (scope instanceof FieldScope) { | ||
attributes = AttributeCollector.collectFieldAttributes((FieldScope) scope, context); | ||
} else if (scope instanceof MethodScope) { | ||
attributes = AttributeCollector.collectMethodAttributes((MethodScope) scope, context); | ||
} else { | ||
attributes = null; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ No longer an issue: Complex Method
provideCustomPropertySchemaDefinition is no longer above the threshold for cyclomatic complexity
private ObjectNode createSubtypeDefinition(ResolvedType javaType, JsonTypeInfo typeInfoAnnotation, JsonSubTypes subTypesAnnotation, | ||
ObjectNode attributesToInclude, SchemaGenerationContext context) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ No longer an issue: Excess Number of Function Arguments
createSubtypeDefinition is no longer above the threshold for number of arguments
@@ -50,6 +50,7 @@ | |||
import java.util.HashSet; | |||
import java.util.Map; | |||
import java.util.Set; | |||
import java.util.function.BiPredicate; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ Getting better: Overall Code Complexity
The mean cyclomatic complexity decreases from 5.64 to 5.26, threshold = 4
Why does this problem occur?
This file has many conditional statements (e.g. if, for, while) across its implementation, leading to lower code health. Avoid adding more conditionals. Read more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
❌ Code Health Quality Gates: FAILED
- Declining Code Health: 1 findings(s) 🚩
- Improving Code Health: 32 findings(s) ✅
- Affected Hotspots: 2 files(s) 🔥
Recommended Review Level: Lightweight sanity check
View detailed results in CodeScene
Absence of Expected Change Pattern
- jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/SchemaGeneratorConfig.java is usually changed with: jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/impl/SchemaGeneratorConfigImpl.java
- jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/MethodScope.java is usually changed with: jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/FieldScope.java
🚩 Declining Code Health (highest to lowest):
- Overall Code Complexity GlobHandler.java
✅ Improving Code Health:
- Overall Code Complexity SchemaBuilder.java
- Overall Code Complexity JakartaValidationModule.java
- Complex Method GlobHandler.java: convertGlobToRegex
- Complex Method SchemaGenerationContextImpl.java: populateMethodSchema
- Complex Method SchemaGenerationContextImpl.java: populateFieldSchema
- Complex Method SchemaGenerationContextImpl.java: traverseGenericType
- Complex Conditional JakartaValidationModule.java: overrideInstanceAttributes
- Complex Method SchemaGenerationContextImpl.java: generateArrayDefinition
- Complex Method SchemaGenerationContextImpl.java: collectObjectProperties
- Complex Method GlobHandler.java: createClassOrPackageNamePattern
- Bumpy Road Ahead SchemaBuilder.java: buildDefinitionsAndResolveReferences
- Complex Method SchemaBuilder.java: buildDefinitionsAndResolveReferences
- Excess Number of Function Arguments SchemaGenerationContextImpl.java: applyReferenceDefinition
- Complex Method MethodScope.java: doFindGetterField
- Bumpy Road Ahead MethodScope.java: doFindGetterField
- Complex Conditional SchemaGenerationContextImpl.java: traverseGenericType
- Complex Conditional SchemaGenerationContextImpl.java: collectObjectProperties
- Complex Conditional SchemaGenerationContextImpl.java: populateMemberSchemaWithReference
- Bumpy Road Ahead GlobHandler.java: convertGlobToRegex
- Deep, Nested Complexity GlobHandler.java: convertGlobToRegex
- Complex Method SchemaGeneratorMojo.java: execute 🔥
- Complex Method SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: execute 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: setOptions 🔥
- Overall Code Complexity SchemaGeneratorMojo.java 🔥
- Complex Method JacksonModule.java: applyToConfigBuilder
- Complex Method JsonSubTypesResolver.java: createSubtypeDefinition 🔥
- Complex Method JsonSubTypesResolver.java: provideCustomPropertySchemaDefinition 🔥
- Excess Number of Function Arguments JsonSubTypesResolver.java: createSubtypeDefinition 🔥
- Complex Method JakartaValidationModule.java: overrideInstanceAttributes
- Bumpy Road Ahead JakartaValidationModule.java: overrideInstanceAttributes
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ Code Health Quality Gates: OK
- Declining Code Health: 1 findings(s) 🚩
- Improving Code Health: 33 findings(s) ✅
- Affected Hotspots: 3 files(s) 🔥
Recommended Review Level: Lightweight sanity check
View detailed results in CodeScene
Absence of Expected Change Pattern
- jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/SchemaGeneratorConfig.java is usually changed with: jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/impl/SchemaGeneratorConfigImpl.java
- jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/MethodScope.java is usually changed with: jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/FieldScope.java
🚩 Declining Code Health (highest to lowest):
- Excess Number of Function Arguments GlobHandler.java: handleOtherChar
✅ Improving Code Health:
- Overall Code Complexity SchemaBuilder.java
- Overall Code Complexity JakartaValidationModule.java
- Complex Method GlobHandler.java: convertGlobToRegex
- Complex Method SchemaGenerationContextImpl.java: populateMethodSchema 🔥
- Complex Method SchemaGenerationContextImpl.java: populateFieldSchema 🔥
- Complex Method SchemaGenerationContextImpl.java: traverseGenericType 🔥
- Complex Conditional JakartaValidationModule.java: overrideInstanceAttributes
- Complex Method SchemaGenerationContextImpl.java: generateArrayDefinition 🔥
- Complex Method SchemaGenerationContextImpl.java: collectObjectProperties 🔥
- Bumpy Road Ahead SchemaBuilder.java: buildDefinitionsAndResolveReferences
- Complex Method GlobHandler.java: createClassOrPackageNamePattern
- Complex Method SchemaBuilder.java: buildDefinitionsAndResolveReferences
- Excess Number of Function Arguments SchemaGenerationContextImpl.java: applyReferenceDefinition 🔥
- Complex Method MethodScope.java: doFindGetterField
- Bumpy Road Ahead MethodScope.java: doFindGetterField
- Complex Conditional SchemaGenerationContextImpl.java: traverseGenericType 🔥
- Complex Conditional SchemaGenerationContextImpl.java: collectObjectProperties 🔥
- Complex Conditional SchemaGenerationContextImpl.java: populateMemberSchemaWithReference 🔥
- Complex Conditional GlobHandler.java: convertGlobToRegex
- Bumpy Road Ahead GlobHandler.java: convertGlobToRegex
- Deep, Nested Complexity GlobHandler.java: convertGlobToRegex
- Complex Method SchemaGeneratorMojo.java: execute 🔥
- Complex Method SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: execute 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: setOptions 🔥
- Overall Code Complexity SchemaGeneratorMojo.java 🔥
- Complex Method JacksonModule.java: applyToConfigBuilder
- Complex Method JsonSubTypesResolver.java: createSubtypeDefinition 🔥
- Complex Method JsonSubTypesResolver.java: provideCustomPropertySchemaDefinition 🔥
- Excess Number of Function Arguments JsonSubTypesResolver.java: createSubtypeDefinition 🔥
- Complex Method JakartaValidationModule.java: overrideInstanceAttributes
- Bumpy Road Ahead JakartaValidationModule.java: overrideInstanceAttributes
...hema-maven-plugin/src/main/java/com/github/victools/jsonschema/plugin/maven/GlobHandler.java
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ Code Health Quality Gates: OK
- Declining Code Health: 0 findings(s) 🚩
- Improving Code Health: 33 findings(s) ✅
- Affected Hotspots: 3 files(s) 🔥
Recommended Review Level: Lightweight sanity check
View detailed results in CodeScene
Absence of Expected Change Pattern
- jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/SchemaGeneratorConfig.java is usually changed with: jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/impl/SchemaGeneratorConfigImpl.java
- jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/MethodScope.java is usually changed with: jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/FieldScope.java
✅ Improving Code Health:
- Overall Code Complexity SchemaBuilder.java
- Overall Code Complexity JakartaValidationModule.java
- Complex Method GlobHandler.java: convertGlobToRegex
- Complex Method SchemaGenerationContextImpl.java: populateMethodSchema 🔥
- Complex Method SchemaGenerationContextImpl.java: populateFieldSchema 🔥
- Complex Method SchemaGenerationContextImpl.java: traverseGenericType 🔥
- Complex Method GlobHandler.java: createClassOrPackageNamePattern
- Complex Conditional JakartaValidationModule.java: overrideInstanceAttributes
- Complex Method SchemaGenerationContextImpl.java: generateArrayDefinition 🔥
- Complex Method SchemaGenerationContextImpl.java: collectObjectProperties 🔥
- Bumpy Road Ahead SchemaBuilder.java: buildDefinitionsAndResolveReferences
- Complex Method SchemaBuilder.java: buildDefinitionsAndResolveReferences
- Excess Number of Function Arguments SchemaGenerationContextImpl.java: applyReferenceDefinition 🔥
- Complex Method MethodScope.java: doFindGetterField
- Bumpy Road Ahead MethodScope.java: doFindGetterField
- Complex Conditional SchemaGenerationContextImpl.java: traverseGenericType 🔥
- Complex Conditional SchemaGenerationContextImpl.java: collectObjectProperties 🔥
- Complex Conditional SchemaGenerationContextImpl.java: populateMemberSchemaWithReference 🔥
- Complex Conditional GlobHandler.java: convertGlobToRegex
- Bumpy Road Ahead GlobHandler.java: convertGlobToRegex
- Deep, Nested Complexity GlobHandler.java: convertGlobToRegex
- Complex Method SchemaGeneratorMojo.java: execute 🔥
- Complex Method SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: execute 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: setOptions 🔥
- Overall Code Complexity SchemaGeneratorMojo.java 🔥
- Complex Method JacksonModule.java: applyToConfigBuilder
- Complex Method JsonSubTypesResolver.java: createSubtypeDefinition 🔥
- Complex Method JsonSubTypesResolver.java: provideCustomPropertySchemaDefinition 🔥
- Excess Number of Function Arguments JsonSubTypesResolver.java: createSubtypeDefinition 🔥
- Complex Method JakartaValidationModule.java: overrideInstanceAttributes
- Bumpy Road Ahead JakartaValidationModule.java: overrideInstanceAttributes
...hema-maven-plugin/src/main/java/com/github/victools/jsonschema/plugin/maven/GlobHandler.java
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ Code Health Quality Gates: OK
- Declining Code Health: 0 findings(s) 🚩
- Improving Code Health: 33 findings(s) ✅
- Affected Hotspots: 3 files(s) 🔥
Recommended Review Level: Lightweight sanity check
View detailed results in CodeScene
Absence of Expected Change Pattern
- jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/SchemaGeneratorConfig.java is usually changed with: jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/impl/SchemaGeneratorConfigImpl.java
- jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/MethodScope.java is usually changed with: jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/FieldScope.java
✅ Improving Code Health:
- Overall Code Complexity SchemaBuilder.java
- Overall Code Complexity JakartaValidationModule.java
- Complex Method GlobHandler.java: convertGlobToRegex
- Complex Method SchemaGenerationContextImpl.java: populateMethodSchema 🔥
- Complex Method SchemaGenerationContextImpl.java: populateFieldSchema 🔥
- Complex Method SchemaGenerationContextImpl.java: traverseGenericType 🔥
- Complex Method GlobHandler.java: createClassOrPackageNamePattern
- Complex Conditional JakartaValidationModule.java: overrideInstanceAttributes
- Complex Method SchemaGenerationContextImpl.java: generateArrayDefinition 🔥
- Complex Method SchemaGenerationContextImpl.java: collectObjectProperties 🔥
- Bumpy Road Ahead SchemaBuilder.java: buildDefinitionsAndResolveReferences
- Complex Method SchemaBuilder.java: buildDefinitionsAndResolveReferences
- Excess Number of Function Arguments SchemaGenerationContextImpl.java: applyReferenceDefinition 🔥
- Complex Method MethodScope.java: doFindGetterField
- Bumpy Road Ahead MethodScope.java: doFindGetterField
- Complex Conditional SchemaGenerationContextImpl.java: traverseGenericType 🔥
- Complex Conditional SchemaGenerationContextImpl.java: collectObjectProperties 🔥
- Complex Conditional SchemaGenerationContextImpl.java: populateMemberSchemaWithReference 🔥
- Complex Conditional GlobHandler.java: convertGlobToRegex
- Bumpy Road Ahead GlobHandler.java: convertGlobToRegex
- Deep, Nested Complexity GlobHandler.java: convertGlobToRegex
- Complex Method SchemaGeneratorMojo.java: execute 🔥
- Complex Method SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: execute 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: setOptions 🔥
- Overall Code Complexity SchemaGeneratorMojo.java 🔥
- Complex Method JacksonModule.java: applyToConfigBuilder
- Complex Method JsonSubTypesResolver.java: createSubtypeDefinition 🔥
- Complex Method JsonSubTypesResolver.java: provideCustomPropertySchemaDefinition 🔥
- Excess Number of Function Arguments JsonSubTypesResolver.java: createSubtypeDefinition 🔥
- Complex Method JakartaValidationModule.java: overrideInstanceAttributes
- Bumpy Road Ahead JakartaValidationModule.java: overrideInstanceAttributes
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ Code Health Quality Gates: OK
- Declining Code Health: 0 findings(s) 🚩
- Improving Code Health: 33 findings(s) ✅
- Affected Hotspots: 3 files(s) 🔥
Recommended Review Level: Lightweight sanity check
View detailed results in CodeScene
Absence of Expected Change Pattern
- jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/SchemaGeneratorConfig.java is usually changed with: jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/impl/SchemaGeneratorConfigImpl.java
- jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/MethodScope.java is usually changed with: jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/FieldScope.java
✅ Improving Code Health:
- Overall Code Complexity SchemaBuilder.java
- Overall Code Complexity JakartaValidationModule.java
- Complex Method GlobHandler.java: convertGlobToRegex
- Complex Method SchemaGenerationContextImpl.java: populateMethodSchema 🔥
- Complex Method SchemaGenerationContextImpl.java: populateFieldSchema 🔥
- Complex Method SchemaGenerationContextImpl.java: traverseGenericType 🔥
- Complex Method GlobHandler.java: createClassOrPackageNamePattern
- Complex Conditional JakartaValidationModule.java: overrideInstanceAttributes
- Complex Method SchemaGenerationContextImpl.java: generateArrayDefinition 🔥
- Complex Method SchemaGenerationContextImpl.java: collectObjectProperties 🔥
- Bumpy Road Ahead SchemaBuilder.java: buildDefinitionsAndResolveReferences
- Complex Method SchemaBuilder.java: buildDefinitionsAndResolveReferences
- Excess Number of Function Arguments SchemaGenerationContextImpl.java: applyReferenceDefinition 🔥
- Complex Method MethodScope.java: doFindGetterField
- Bumpy Road Ahead MethodScope.java: doFindGetterField
- Complex Conditional SchemaGenerationContextImpl.java: traverseGenericType 🔥
- Complex Conditional SchemaGenerationContextImpl.java: collectObjectProperties 🔥
- Complex Conditional SchemaGenerationContextImpl.java: populateMemberSchemaWithReference 🔥
- Complex Conditional GlobHandler.java: convertGlobToRegex
- Bumpy Road Ahead GlobHandler.java: convertGlobToRegex
- Deep, Nested Complexity GlobHandler.java: convertGlobToRegex
- Complex Method SchemaGeneratorMojo.java: execute 🔥
- Complex Method SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: execute 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: setOptions 🔥
- Overall Code Complexity SchemaGeneratorMojo.java 🔥
- Complex Method JacksonModule.java: applyToConfigBuilder
- Complex Method JsonSubTypesResolver.java: createSubtypeDefinition 🔥
- Complex Method JsonSubTypesResolver.java: provideCustomPropertySchemaDefinition 🔥
- Excess Number of Function Arguments JsonSubTypesResolver.java: createSubtypeDefinition 🔥
- Complex Method JakartaValidationModule.java: overrideInstanceAttributes
- Bumpy Road Ahead JakartaValidationModule.java: overrideInstanceAttributes
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ Code Health Quality Gates: OK
- Declining Code Health: 0 findings(s) 🚩
- Improving Code Health: 33 findings(s) ✅
- Affected Hotspots: 3 files(s) 🔥
Recommended Review Level: Lightweight sanity check
View detailed results in CodeScene
Absence of Expected Change Pattern
- jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/SchemaGeneratorConfig.java is usually changed with: jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/impl/SchemaGeneratorConfigImpl.java
- jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/MethodScope.java is usually changed with: jsonschema-generator/jsonschema-generator/src/main/java/com/github/victools/jsonschema/generator/FieldScope.java
✅ Improving Code Health:
- Overall Code Complexity SchemaBuilder.java
- Overall Code Complexity JakartaValidationModule.java
- Complex Method GlobHandler.java: convertGlobToRegex
- Complex Method SchemaGenerationContextImpl.java: populateMethodSchema 🔥
- Complex Method SchemaGenerationContextImpl.java: populateFieldSchema 🔥
- Complex Method SchemaGenerationContextImpl.java: traverseGenericType 🔥
- Complex Method GlobHandler.java: createClassOrPackageNamePattern
- Complex Method SchemaGenerationContextImpl.java: generateArrayDefinition 🔥
- Complex Method SchemaGenerationContextImpl.java: collectObjectProperties 🔥
- Bumpy Road Ahead SchemaBuilder.java: buildDefinitionsAndResolveReferences
- Complex Conditional JakartaValidationModule.java: overrideInstanceAttributes
- Complex Method SchemaBuilder.java: buildDefinitionsAndResolveReferences
- Excess Number of Function Arguments SchemaGenerationContextImpl.java: applyReferenceDefinition 🔥
- Complex Method MethodScope.java: doFindGetterField
- Bumpy Road Ahead MethodScope.java: doFindGetterField
- Complex Conditional SchemaGenerationContextImpl.java: traverseGenericType 🔥
- Complex Conditional SchemaGenerationContextImpl.java: collectObjectProperties 🔥
- Complex Conditional SchemaGenerationContextImpl.java: populateMemberSchemaWithReference 🔥
- Complex Conditional GlobHandler.java: convertGlobToRegex
- Bumpy Road Ahead GlobHandler.java: convertGlobToRegex
- Deep, Nested Complexity GlobHandler.java: convertGlobToRegex
- Complex Method SchemaGeneratorMojo.java: execute 🔥
- Complex Method SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: execute 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: generateSchema 🔥
- Bumpy Road Ahead SchemaGeneratorMojo.java: setOptions 🔥
- Overall Code Complexity SchemaGeneratorMojo.java 🔥
- Complex Method JacksonModule.java: applyToConfigBuilder
- Complex Method JsonSubTypesResolver.java: createSubtypeDefinition 🔥
- Complex Method JsonSubTypesResolver.java: provideCustomPropertySchemaDefinition 🔥
- Excess Number of Function Arguments JsonSubTypesResolver.java: createSubtypeDefinition 🔥
- Complex Method JakartaValidationModule.java: overrideInstanceAttributes
- Bumpy Road Ahead JakartaValidationModule.java: overrideInstanceAttributes
No description provided.