Skip to content

Change HashMap to LinkedHashMap for query parameters - #125

Closed
phapntm wants to merge 1 commit into
socketio:mainfrom
phapntm:patch-4
Closed

phapntm wants to merge 1 commit into
socketio:mainfrom
phapntm:patch-4

Conversation

@phapntm

@phapntm phapntm commented May 24, 2026

Copy link
Copy Markdown

No description provided.

@phapntm
phapntm marked this pull request as draft May 24, 2026 12:43
@phapntm phapntm closed this May 24, 2026
MonkeyMed added a commit to kaeferfreund/socket.io-client-kotlin that referenced this pull request Sep 26, 2026
Refs socketio/engine.io-client-java#126, socketio/engine.io-client-java#124,
socketio/engine.io-client-java#125: the Java client copied the query into a
HashMap and sent the parameters in hash order. JavaScript keeps the insertion
order, and so does this client (LinkedHashMap in EngineUri.decodeQuery and
EngineSocket.createTransport), but no test pinned it.

The new test checks the exact parameter order of the handshake, the following
polling requests and the WebSocket upgrade for a query in the URL, and of a
WebSocket connection for the query option. Replacing either LinkedHashMap with
a HashMap makes it fail.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant