Commit 22b9009
committed
refactor(transport): make fields final and specify charset in stream readers
Make scheduler fields final in client and server transports for better immutability.
Explicitly specify UTF-8 charset when creating InputStreamReader instances to ensure consistent character encoding.1 parent 082444e commit 22b9009
File tree
2 files changed
+11
-17
lines changed- mcp-core/src/main/java/io/modelcontextprotocol
- client/transport
- server/transport
2 files changed
+11
-17
lines changedLines changed: 7 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
48 | 48 | | |
49 | 49 | | |
50 | 50 | | |
51 | | - | |
| 51 | + | |
52 | 52 | | |
53 | 53 | | |
54 | | - | |
| 54 | + | |
55 | 55 | | |
56 | 56 | | |
57 | | - | |
| 57 | + | |
58 | 58 | | |
59 | 59 | | |
60 | | - | |
| 60 | + | |
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
| |||
180 | 180 | | |
181 | 181 | | |
182 | 182 | | |
183 | | - | |
| 183 | + | |
184 | 184 | | |
185 | 185 | | |
186 | 186 | | |
| |||
246 | 246 | | |
247 | 247 | | |
248 | 248 | | |
249 | | - | |
| 249 | + | |
| 250 | + | |
250 | 251 | | |
251 | 252 | | |
252 | 253 | | |
| |||
Lines changed: 4 additions & 11 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
14 | 13 | | |
15 | 14 | | |
16 | 15 | | |
| |||
22 | 21 | | |
23 | 22 | | |
24 | 23 | | |
25 | | - | |
26 | 24 | | |
27 | 25 | | |
28 | 26 | | |
| |||
82 | 80 | | |
83 | 81 | | |
84 | 82 | | |
85 | | - | |
86 | | - | |
87 | | - | |
88 | | - | |
89 | | - | |
90 | 83 | | |
91 | 84 | | |
92 | 85 | | |
| |||
124 | 117 | | |
125 | 118 | | |
126 | 119 | | |
127 | | - | |
| 120 | + | |
128 | 121 | | |
129 | 122 | | |
130 | | - | |
| 123 | + | |
131 | 124 | | |
132 | 125 | | |
133 | 126 | | |
| |||
198 | 191 | | |
199 | 192 | | |
200 | 193 | | |
201 | | - | |
| 194 | + | |
202 | 195 | | |
203 | | - | |
| 196 | + | |
204 | 197 | | |
205 | 198 | | |
206 | 199 | | |
| |||
0 commit comments