You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hc.apache.org by GitBox <gi...@apache.org> on 2022/07/01 15:49:55 UTC

[GitHub] [httpcomponents-core] jkmcl commented on a diff in pull request #355: Code cleanup and optimization

jkmcl commented on code in PR #355:
URL: https://github.com/apache/httpcomponents-core/pull/355#discussion_r912075386


##########
httpcore5/src/main/java/org/apache/hc/core5/net/URIBuilder.java:
##########
@@ -1033,22 +1033,22 @@ public URIBuilder normalizeSyntax() {
         if (this.pathSegments != null) {
             final List<String> inputSegments = this.pathSegments;
             if (!inputSegments.isEmpty()) {
-                final Stack<String> outputSegments = new Stack<>();
+                final LinkedList<String> outputSegments = new LinkedList<>();

Review Comment:
   Performance. Stack extends Vector which is synchronized but LinkedList is not synchronized.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@hc.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org