Commit 2a5954f
committed
GH-5723: cleanup and polishing
Apache HttpClient Factory
- Removed the unconditional evictIdleConnections(...) call
- Added a guard so idle eviction is only configured when
idleConnectionTimeoutMs > 0
- Also removed the duplicate evictExpiredConnections() that was
present in the original
SparqlProtocolSession
Case-insensitive match: replaced startsWith("charset=") with
regionMatches(true, 0, "charset=", 0, 8) — the true flag makes it
case-insensitive, so CHARSET=, Charset=, etc. all match.
2. Quote stripping: after extracting the value, checks for surrounding
double-quotes and strips them, handling charset="UTF-8".
HttpUtils
UnsupportedCharsetException is a subclass of IllegalArgumentException,
so catching IllegalArgumentException covers both it and
IllegalCharsetNameException in one clause — no need for multiple catches1 parent cd0af8f commit 2a5954f
3 files changed
Lines changed: 15 additions & 6 deletions
File tree
- core/http
- client-apache5/src/main/java/org/eclipse/rdf4j/http/client/apache5
- client-api/src/main/java/org/eclipse/rdf4j/http/client/spi
- client/src/main/java/org/eclipse/rdf4j/http/client
Lines changed: 7 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
104 | 104 | | |
105 | 105 | | |
106 | 106 | | |
107 | | - | |
108 | | - | |
109 | 107 | | |
110 | | - | |
111 | | - | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
112 | 115 | | |
113 | 116 | | |
114 | 117 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
90 | 90 | | |
91 | 91 | | |
92 | 92 | | |
93 | | - | |
| 93 | + | |
94 | 94 | | |
95 | 95 | | |
96 | 96 | | |
| |||
Lines changed: 7 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1173 | 1173 | | |
1174 | 1174 | | |
1175 | 1175 | | |
1176 | | - | |
| 1176 | + | |
1177 | 1177 | | |
| 1178 | + | |
| 1179 | + | |
| 1180 | + | |
| 1181 | + | |
| 1182 | + | |
| 1183 | + | |
1178 | 1184 | | |
1179 | 1185 | | |
1180 | 1186 | | |
| |||
0 commit comments