Damien Arrachequesne
667bd17a01
chore(release): prepare release socket.io-client-2.1.2
2025-02-18 09:49:09 +01:00
Damien Arrachequesne
80aa47158e
refactor: merge duplicate cases
2025-02-18 09:42:56 +01:00
Damien Arrachequesne
e2cdf7b99c
refactor: make fields final when possible
2025-02-18 09:42:55 +01:00
Damien Arrachequesne
54852ce2a4
ci: fix java 7 build
...
Maven has been upgraded from 3.8 to 3.9, which is not compatible with JDK 7.
See also: https://github.com/actions/runner-images/issues/11093
2025-02-18 09:42:55 +01:00
Harshvardhan Gupta
4f45e3c127
fix: make acks thread safe ( #779 )
2025-02-06 09:16:05 +01:00
Damien Arrachequesne
6ea9c15a34
ci: fix java 7 build
...
In order to prevent:
> Error: Exception in thread "main" java.lang.UnsupportedClassVersionError: com/fasterxml/jackson/databind/ObjectMapper : Unsupported major.minor version 52.0
> at java.lang.ClassLoader.defineClass1(Native Method)
> at java.lang.ClassLoader.defineClass(ClassLoader.java:808)
2024-07-10 12:42:26 +02:00
Damien Arrachequesne
6d5d74ed8c
chore(release): prepare for next development iteration
2024-07-10 12:23:32 +02:00
Damien Arrachequesne
0e11f2f7bb
chore(release): prepare release socket.io-client-2.1.1
2024-07-10 12:07:58 +02:00
Damien Arrachequesne
54645ece2c
fix: discard acknowledgements upon disconnection
...
Previously, getting disconnected while waiting for an acknowledgement
would create a memory leak, as the acknowledgement was never received
and the handler would stay in memory forever.
See also: 34cbfbb532
Related: https://github.com/socketio/socket.io-client-java/issues/446
2024-07-10 11:43:48 +02:00
Harshvardhan Gupta
b00ae8eec1
fix: make sendBuffer thread safe ( #769 )
...
Clearing the buffer upon timeout could lead to:
```
java.util.ConcurrentModificationException
at java.base/java.util.LinkedList$ListItr.checkForComodification(LinkedList.java:970)
at java.base/java.util.LinkedList$ListItr.next(LinkedList.java:892)
at io.socket.client.Socket$6$1.run(Socket.java:232)
at java.base/java.util.TimerThread.mainLoop(Timer.java:556)
at java.base/java.util.TimerThread.run(Timer.java:506)
```
Related:
- https://github.com/socketio/socket.io-client-java/issues/710
- https://github.com/socketio/socket.io-client-java/issues/727
- https://github.com/socketio/socket.io-client-java/pull/758
- https://github.com/socketio/socket.io-client-java/issues/759
2024-07-10 11:10:17 +02:00
FarmersWrap
774543ef57
test: silence expected error ( #757 )
2024-01-08 17:52:15 +01:00
Damien Arrachequesne
ad3a930e34
docs: how to run unit tests in Android Studio
...
Related: https://github.com/socketio/socket.io-client-java/issues/493
2022-07-11 10:11:34 +02:00
Damien Arrachequesne
22518c9fa9
docs: add changelog for version 1.0.2
2022-07-11 00:37:40 +02:00
Damien Arrachequesne
17d13c335c
chore(release): prepare for next development iteration
2022-07-10 23:24:36 +02:00
Damien Arrachequesne
abe22c3779
chore(release): prepare release socket.io-client-2.1.0
2022-07-10 23:15:59 +02:00
Damien Arrachequesne
95ecf222d2
fix: prevent socket from reconnecting after middleware failure
...
See also: d54d12ce63
2022-07-10 22:59:57 +02:00
Damien Arrachequesne
ee35261dc0
chore: bump engine.io-client to version 2.1.0
...
Diff: https://github.com/socketio/engine.io-client-java/compare/engine.io-client-2.0.0...engine.io-client-2.1.0
Release notes: https://github.com/socketio/engine.io-client-java/releases/tag/engine.io-client-2.1.0
2022-07-10 09:37:10 +02:00
Damien Arrachequesne
4f932f278c
docs: how to map the event arguments to POJO
...
Related: https://github.com/socketio/socket.io-client-java/issues/235
2022-07-10 08:15:54 +02:00
Damien Arrachequesne
c7d50b8ae9
feat: implement catch-all listeners
...
Syntax:
```java
socket.onAnyIncoming(new Emitter.Listener() {
@Override
public void call(Object... args) {
// ...
}
});
socket.onAnyOutgoing(new Emitter.Listener() {
@Override
public void call(Object... args) {
// ...
}
});
```
Related:
- https://github.com/socketio/engine.io-client-java/issues/99
- https://github.com/socketio/socket.io-client-java/issues/243
- https://github.com/socketio/socket.io-client-java/issues/475
2022-07-08 20:39:36 +02:00
Damien Arrachequesne
fca3b9507d
feat: emit with timeout
...
This feature allows to send a packet and expect an acknowledgement from
the server within the given delay.
Syntax:
```java
socket.emit("hello", "world", new AckWithTimeout(5000) {
@Override
public void onTimeout() {
// ...
}
@Override
public void onSuccess(Object... args) {
// ...
}
});
```
Related:
- https://github.com/socketio/socket.io-client-java/issues/309
- https://github.com/socketio/socket.io-client-java/pull/517
2022-07-08 19:46:18 +02:00
Damien Arrachequesne
73757635ed
docs: multiplexing
...
Related: https://github.com/socketio/socket.io-client-java/pull/716
2022-07-08 09:26:40 +02:00
Damien Arrachequesne
6e08d1fe3b
docs: how to properly close a client
...
Related:
- https://github.com/socketio/socket.io-client-java/issues/547
- https://github.com/socketio/socket.io-client-java/issues/704
2022-07-08 08:46:11 +02:00
Damien Arrachequesne
f3221a4cdf
docs: how to create a lot of clients
...
Related:
- https://github.com/socketio/socket.io-client-java/issues/460
- https://github.com/socketio/socket.io-client-java/issues/618
2022-07-07 08:53:33 +02:00
Damien Arrachequesne
d178f31f53
docs: add note about TLS versions
...
Related: https://github.com/socketio/socket.io-client-java/issues/298
2022-07-07 08:10:39 +02:00
Damien Arrachequesne
b43819e986
docs: how to display the debug logs
...
Related: https://github.com/socketio/socket.io-client-java/issues/498
2022-07-06 09:33:14 +02:00
Damien Arrachequesne
de7f932918
docs: add note about the readTimeout value
...
See also: fb531fab30
2022-07-04 02:54:11 +02:00
Damien Arrachequesne
98d0c13da1
docs: add missing manager options
2022-07-04 02:50:00 +02:00
Damien Arrachequesne
18b2fca397
docs: init Android documentation
...
Related:
- https://github.com/socketio/socket.io-client-java/issues/606
- https://github.com/socketio/socket.io-client-java/issues/435
2022-07-04 02:37:51 +02:00
Damien Arrachequesne
0cbf01eb25
fix: ensure randomizationFactor is always between 0 and 1
...
Using a randomizationFactor value above 1 could lead to generating a
negative duration, then throwing:
> java.lang.IllegalArgumentException: delay < 0: -1012
> at java.util.Timer.schedule(Timer.java:454)
> at io.socket.client.Manager.reconnect(Manager.java:544)
This error does not seem related to a long overflow (in the
BigInteger.longValue() operation), because the BigInteger.min(this.max)
operation before should prevent it.
Related: https://github.com/socketio/socket.io-client-java/issues/349
2022-07-02 09:02:48 +02:00
Damien Arrachequesne
fd0c733822
docs: add "How to deal with cookies" in FAQ
2022-07-02 07:26:20 +02:00
Damien Arrachequesne
891bea342f
test: add test class (2)
...
Let's use Java 7 syntax for now.
2022-07-02 07:24:33 +02:00
Damien Arrachequesne
d7ff2bbca5
test: add test class
2022-06-29 08:20:39 +02:00
Damien Arrachequesne
072d894dab
docs: add changelog for version 2.0.1
2022-06-29 07:36:21 +02:00
Damien Arrachequesne
7fa9e9595b
docs: add SSL examples
2022-06-29 07:27:11 +02:00
Damien Arrachequesne
d97f4573be
docs: add example with server to client ack
...
Related: https://github.com/socketio/socket.io-client-java/issues/693
2021-11-24 16:20:57 +01:00
Damien Arrachequesne
d8d975e5bd
docs: update links to the Socket.IO website
...
Some links were broken due to recent updates.
2021-09-21 08:34:33 +02:00
Damien Arrachequesne
08bc462ccd
docs: use implementation instead of compile in gradle ( #684 )
...
Reference: https://docs.gradle.org/current/userguide/upgrading_version_5.html#dependencies_should_no_longer_be_declared_using_the_compile_and_runtime_configurations
2021-09-21 08:28:30 +02:00
Damien Arrachequesne
ad23cfcca6
chore(release): prepare for next development iteration
2021-04-27 00:35:37 +02:00
Damien Arrachequesne
b46da92382
chore(release): prepare release socket.io-client-2.0.1
2021-04-27 00:30:03 +02:00
Damien Arrachequesne
d324e7f396
fix: emit a CONNECT_ERROR event upon connection failure
...
See also: 53c73749a8
2021-04-27 00:17:05 +02:00
Damien Arrachequesne
e8ffe9d138
fix: ensure the payload format is valid
...
This commit should prevent some NPE issues encountered after the
parsing of the packet.
Related:
- https://github.com/socketio/socket.io-client-java/issues/642
- https://github.com/socketio/socket.io-client-java/issues/609
- https://github.com/socketio/socket.io-client-java/issues/505
2021-04-27 00:14:24 +02:00
Damien Arrachequesne
4885e7d59f
fix: ensure buffered events are sent in order
...
Before this commit, an event sent in the "connect" handler could be
sent before the events that were buffered while disconnected.
Related: https://github.com/socketio/socket.io-client/issues/1458
2021-04-27 00:12:46 +02:00
Damien Arrachequesne
48fec45740
refactor: minor cleanup
...
- replace explicit types by <>
- remove unnecessary interface modifiers
2021-04-26 11:19:02 +02:00
Damien Arrachequesne
a4053e8645
test: cleanup URISyntaxException exceptions
...
Note: we cannot update the `IO.socket(uri: string)` method without
doing a breaking change.
2021-04-26 11:19:02 +02:00
Damien Arrachequesne
67fd5f34a3
fix: fix usage with ws:// scheme
...
The URL constructor does not support the ws:// scheme, and would throw:
> java.net.MalformedURLException: unknown protocol: ws
Related:
- https://github.com/socketio/socket.io-client-java/issues/650
- https://github.com/socketio/socket.io-client-java/issues/555
- https://github.com/socketio/socket.io-client-java/issues/233
2021-04-26 11:17:41 +02:00
Damien Arrachequesne
e2e24ea75d
docs: update compatibility table with Socket.IO v4
2021-04-26 09:22:05 +02:00
Damien Arrachequesne
5b5b91cb01
test: fix random test failures
2021-04-26 09:12:55 +02:00
Damien Arrachequesne
615942b828
docs: update compatibility table with Socket.IO v4
...
There is no breaking change at the protocol level.
Reference: https://socket.io/blog/socket-io-4-release/
2021-03-19 14:55:42 +01:00
Damien Arrachequesne
275cd1b7ee
docs: add EVENT_CONNECT_TIMEOUT in the migration guide
2020-12-21 10:37:49 +01:00
Damien Arrachequesne
651404136f
docs: add additional details
...
Adapted from:
- https://socket.io/docs/v3/client-initialization/
- https://socket.io/docs/v3/client-socket-instance/
2020-12-21 10:08:02 +01:00