You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hc.apache.org by mi...@apache.org on 2020/08/18 10:20:02 UTC
[httpcomponents-core] branch decimal-ids created (now 18baff0)
This is an automated email from the ASF dual-hosted git repository.
michaelo pushed a change to branch decimal-ids
in repository https://gitbox.apache.org/repos/asf/httpcomponents-core.git.
at 18baff0 Use decimal numbers for endpoint/execution IDs
This branch includes the following new commits:
new 18baff0 Use decimal numbers for endpoint/execution IDs
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
[httpcomponents-core] 01/01: Use decimal numbers for
endpoint/execution IDs
Posted by mi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
michaelo pushed a commit to branch decimal-ids
in repository https://gitbox.apache.org/repos/asf/httpcomponents-core.git
commit 18baff0a8d69748224a2e74e5f4b07269ed85782
Author: Michael Osipov <mi...@apache.org>
AuthorDate: Tue Aug 18 12:19:02 2020 +0200
Use decimal numbers for endpoint/execution IDs
---
httpcore5/src/main/java/org/apache/hc/core5/reactor/IOSessionImpl.java | 2 +-
.../org/apache/hc/core5/http/examples/AsyncReverseProxyExample.java | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/httpcore5/src/main/java/org/apache/hc/core5/reactor/IOSessionImpl.java b/httpcore5/src/main/java/org/apache/hc/core5/reactor/IOSessionImpl.java
index 3cffb58..242dd77 100644
--- a/httpcore5/src/main/java/org/apache/hc/core5/reactor/IOSessionImpl.java
+++ b/httpcore5/src/main/java/org/apache/hc/core5/reactor/IOSessionImpl.java
@@ -71,7 +71,7 @@ class IOSessionImpl implements IOSession {
this.commandQueue = new ConcurrentLinkedDeque<>();
this.lock = new ReentrantLock();
this.socketTimeout = Timeout.DISABLED;
- this.id = String.format(type + "-%08X", COUNT.getAndIncrement());
+ this.id = String.format(type + "-%08d", COUNT.getAndIncrement());
this.handlerRef = new AtomicReference<>();
this.status = new AtomicReference<>(Status.ACTIVE);
final long currentTimeMillis = System.currentTimeMillis();
diff --git a/httpcore5/src/test/java/org/apache/hc/core5/http/examples/AsyncReverseProxyExample.java b/httpcore5/src/test/java/org/apache/hc/core5/http/examples/AsyncReverseProxyExample.java
index 8136cab..e1f98f9 100644
--- a/httpcore5/src/test/java/org/apache/hc/core5/http/examples/AsyncReverseProxyExample.java
+++ b/httpcore5/src/test/java/org/apache/hc/core5/http/examples/AsyncReverseProxyExample.java
@@ -251,7 +251,7 @@ public class AsyncReverseProxyExample {
AsyncClientEndpoint clientEndpoint;
ProxyExchangeState() {
- this.id = String.format("%08X", COUNT.getAndIncrement());
+ this.id = String.format("%08d", COUNT.getAndIncrement());
}
}