-
Notifications
You must be signed in to change notification settings - Fork 1
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
Issue #42: Rollback classpath.jar logic #43
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ETP-729
sebastianbarrozo
requested review from
valenvivaldi,
valeg-etendo,
isaiasb-etendo,
Matias-Bernal and
Gremiger
November 11, 2024 15:40
etendobot
reviewed
Nov 11, 2024
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.
GPT Review for ResolverDependencyLoader.groovy
Review
- Estimated effort to review [1-5]:
3, because the changes involve significant modifications to the file handling and classpath management logic, which require careful review to ensure correctness and compatibility with different operating systems. - Score: 85
Code feedback
- File:
src/main/groovy/com/etendoerp/legacy/dependencies/ResolverDependencyLoader.groovy - Language:
groovy - Suggestion:
Consider usingStringBuilder
for constructing thestrClasspath
string. This can improve performance, especially when dealing with a large number of files, asStringBuilder
is more efficient for concatenating strings in a loop. [medium] - Label:
performance - Existing code:
String strClasspath = ''
files.forEach { String file ->
if (OperatingSystem.current().isWindows()) {
// Windows paths need to be file:/// and replace \ with /
strClasspath += 'file:///' + file.toString().replaceAll('\\\\', '/') + CLASSPATH_SEPARATOR
} else {
strClasspath += file.toString() + CLASSPATH_SEPARATOR
}
}
- Improved code:
StringBuilder strClasspathBuilder = new StringBuilder()
files.forEach { String file ->
if (OperatingSystem.current().isWindows()) {
// Windows paths need to be file:/// and replace \ with /
strClasspathBuilder.append('file:///').append(file.toString().replaceAll('\\\\', '/')).append(CLASSPATH_SEPARATOR)
} else {
strClasspathBuilder.append(file.toString()).append(CLASSPATH_SEPARATOR)
}
}
String strClasspath = strClasspathBuilder.toString()
This comment has been minimized.
This comment has been minimized.
sebastianbarrozo
changed the title
Issue #42: Remove log output
Issue #42: Rollback classpath.jar logic
Nov 11, 2024
ETP-729
etendobot
reviewed
Nov 11, 2024
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.
GPT Review for ResolverDependencyLoader.groovy
Review
- Estimated effort to review [1-5]:
4, because the PR involves significant changes to theResolverDependencyLoader.groovy
file, including refactoring and restructuring of the code. The changes are extensive and require careful review to ensure that the functionality remains intact and that no new issues are introduced. - Score: 85
Code feedback
- File:
src/main/groovy/com/etendoerp/legacy/dependencies/ResolverDependencyLoader.groovy - Language:
groovy - Suggestion:
Consider usingStringBuilder
for constructing thestrClasspath
string to improve performance, especially when dealing with a large number of files. [medium] - Label:
performance - Existing code:
String strClasspath = ''
files.forEach { String file ->
if (OperatingSystem.current().isWindows()) {
// Windows paths need to be file:/// and replace \ with /
strClasspath += 'file:///' + file.toString().replaceAll('\\\\', '/') + CLASSPATH_SEPARATOR
} else {
strClasspath += file.toString() + CLASSPATH_SEPARATOR
}
}
- Improved code:
StringBuilder strClasspathBuilder = new StringBuilder()
files.forEach { String file ->
if (OperatingSystem.current().isWindows()) {
// Windows paths need to be file:/// and replace \ with /
strClasspathBuilder.append('file:///').append(file.toString().replaceAll('\\\\', '/')).append(CLASSPATH_SEPARATOR)
} else {
strClasspathBuilder.append(file.toString()).append(CLASSPATH_SEPARATOR)
}
}
String strClasspath = strClasspathBuilder.toString()
valeg-etendo
approved these changes
Nov 11, 2024
isaiasb-etendo
approved these changes
Nov 12, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
ETP-729