1
0
Fork 0
mirror of https://github.com/vanitasvitae/Smack.git synced 2024-11-21 19:42:05 +01:00
Commit graph

4965 commits

Author SHA1 Message Date
Florian Schmaus
04dc212db8 Add smack-examples 2023-11-28 10:46:16 +01:00
Florian Schmaus
5a78534443 [core] Mark LazyStringBuilder's String cache as transient 2023-11-26 21:35:19 +01:00
Florian Schmaus
b35b67c360 [repl] Bump Scala to 2.13.12, Ammonite to 2.5.11, and Scalastyle plugin to 2.1.0 2023-11-26 21:34:14 +01:00
Florian Schmaus
6322f4f826 [core] Add global option to flatten when appending in XmlStringBuilder
For certain use cases, this provides a performance improvement,
probably due better cache locality. However, it comes with the cost of
additional memory consumption.

This was initially suggested by Boris Grozev, who also reported a
significant performance problem of
XmlStringBuilder/LazyStringBuilder. However, the main cause of the
performance probelm was the missing caching of LazyStringBuilder. The
length of the lazy string is now cached by LazyStringBuidler since
70e48300a6 ("[core] Cache length in LazyStringBuilder"), which
accounts for large performance improvement. A significantly smaller
improvement is achieved by this commit and setting
XmlStringBuilder.FLAT_APPEND to 'true'.

Suggested-by: Boris Grozev <boris@jitsi.org>
2023-11-26 21:34:13 +01:00
Florian Schmaus
70e48300a6 [core] Cache length in LazyStringBuilder 2023-11-26 21:24:17 +01:00
Florian Schmaus
9203907e66
Merge pull request #567 from guusdk/sint_trim-config
[sinttest] Trim externally-provided configuration
2023-11-26 17:12:39 +00:00
Florian Schmaus
38dd64835f Merge branch '4.4' 2023-11-26 17:53:07 +01:00
Florian Schmaus
0fb8bfdf6c [CHANGELOG] fix markdown listing 2023-11-26 17:52:32 +01:00
Florian Schmaus
472bee8497 [sinttest] drop empty line 2023-11-26 13:58:09 +01:00
Florian Schmaus
535ecd67ee
Merge pull request #573 from Flowdalic/sinttest-ibr
[sinttest] Fix IBR-based account registration
2023-11-26 12:56:13 +00:00
Florian Schmaus
915626123d [sinttest] Fix IBR-based account registration
When performing IBR-based account registration, we do not need to
login nor are the admin credentials typically available.

Suggested-by: Guus der Kinderen <guus@goodbytes.nl>
2023-11-26 13:55:35 +01:00
Guus der Kinderen
9055878748 [sinttest] Fix typos in log and exception messages 2023-11-25 20:08:51 +01:00
Florian Schmaus
6859de95d0
Merge pull request #564 from vanitasvitae/bumpLibSignal
Bump libsignal-protocol-java to 2.8.1
2023-11-25 19:00:45 +00:00
Florian Schmaus
0469185b62
Merge pull request #517 from Neustradamus/slf4j
Add SLF4J 2.0+
2023-11-25 19:00:20 +00:00
Florian Schmaus
2dc12db6f4
Merge pull request #563 from vanitasvitae/bumpPgpainless
Bump pgpainless
2023-11-25 19:00:02 +00:00
Florian Schmaus
7eabdaf8f7
Merge pull request #570 from guusdk/SMACK-935_Websocket-open-element
Improve handling of expanded Websocket 'open' element
2023-11-25 18:59:40 +00:00
Florian Schmaus
097ab20485 [websocket] Do not swallow exceptions and use QName
Follow up on c4d11eae299e ("[websocket] Reduce fragility")
2023-11-25 19:59:05 +01:00
Florian Schmaus
2ebffa7615 Merge remote-tracking branch 'origin/pr/571' 2023-11-25 19:58:54 +01:00
Florian Schmaus
0552440c1a Merge branch '4.4' 2023-11-25 19:44:29 +01:00
Florian Schmaus
84ec2c8c2f Smack 4.4.8-SNAPSHOT 2023-11-25 19:30:49 +01:00
Florian Schmaus
6d99ba7ffb Smack 4.4.7 2023-11-25 19:07:40 +01:00
Florian Schmaus
b5b4418406 Merge branch '4.4' 2023-11-25 17:36:15 +01:00
Florian Schmaus
2e8f83c579
Merge pull request #572 from Flowdalic/sync-entity-caps
[caps] Use a synchronous listener for incoming presence stanzas
2023-11-25 13:26:12 +01:00
Florian Schmaus
5560fb4752 [chatmarkers] Deprecate ChatMarkers.isSupportedByServer()
Fixes SMACK-934.
2023-11-25 11:24:37 +01:00
Florian Schmaus
a270542397 [core] Improve javadoc for listeners
With 92f253cc74 ("[core] Replace
AbstractXMPPConnection.inOrderListeners") we changes the behavior of
listeners. This commit documents the expectations to the user.
2023-11-24 12:59:04 +01:00
Florian Schmaus
f593b6d0a0 [core] Whitespace fix in XMPPConnection's javadoc 2023-11-24 12:18:19 +01:00
Florian Schmaus
ccfbf9f346 [caps] Use a synchronous listener for incoming presence stanzas
Fixes SMACK-937.
2023-11-24 12:15:32 +01:00
Guus der Kinderen
8c1fa1cc91 [websocket] Reduce fragility
Replace string-based comparison with a XML parsing when checking for 'open' and 'close' elements.
2023-11-13 16:03:41 +01:00
Guus der Kinderen
6244a213c8 [websocket] Improve handling of expanded 'open' element
Prior to this fix, Smack requires the 'open' element send on a websocket connection to be collapsed. With the change in
this commit, an expanded (eg: `<open ...></open>`) element can also be used.

fixes SMACK-935
2023-10-27 13:33:04 +02:00
Florian Schmaus
c7f3e231d0
Merge pull request #568 from guusdk/intellij-icon
Add icon to IntelliJ metadata
2023-10-26 19:08:35 +00:00
Guus der Kinderen
e2d136d992 Add icon to IntelliJ metadata 2023-10-05 10:31:41 +02:00
Guus der Kinderen
92d4cf5c77 [sinttest] Trim externally-provided configuration
Smack integration test configuration is provided externally. Guard against accidental whitespace inclusion by trimming values.
2023-09-29 20:37:03 +02:00
38844ee340
Bump libsignal-protocol-java to 2.8.1 2023-06-24 11:28:53 +02:00
430795bb9e
Bump PGPainless to 1.5.3 2023-06-24 11:10:24 +02:00
9bfaf674b1
Bump BC to 1.73 2023-06-24 11:10:10 +02:00
Florian Schmaus
19b20fefec
Merge pull request #537 from MF1-MS/mf1-ms/use_xmpp_connection_as_local_socks5_address
Use XMPP connection as local socks5 address
2023-04-26 11:35:04 +00:00
Martin Fidczuk
ffd027cc7d
Use XMPP connection as local SOCKS5 address
The default local address is often just "the first address found in the list of addresses read from the OS" and this might mean an internal IP address that cannot reach external servers. So wherever possible use the same IP address being used to connect to the XMPP server because this local address has a better chance of being suitable.

This MR adds the above behaviour, and two UTs to test that we use the local XMPP connection IP when connected, and the previous behaviour when not.
2023-04-26 10:00:23 +01:00
Florian Schmaus
50eb94850d
Merge pull request #535 from MF1-MS/mf1-ms/xep_0249_support
Add partial support for XEP-0249 Direct MUC Invitations
2023-04-24 10:10:08 +00:00
Martin Fidczuk
9e9c233468
Add partial support for XEP-0249 Direct MUC Invitations.
Exposes a method for a MUC to invite a user to the room, and adds a listener to the MultiUserChat listener to inform users of direct invitations they have received.

Fixes SMACK-932.
2023-04-24 10:47:06 +01:00
Florian Schmaus
f6c85d9fb3
Merge pull request #561 from Flowdalic/github-ci
[github ci] Java 15 → 17
2023-03-18 09:03:35 +00:00
Florian Schmaus
e3425706d9 [github ci] Remove Java 15, as its no longer provided
It appears github's ubuntu-22.04 image does not provide java
15. However, since Smack uses Gradle 6.8, we can not use any higher
version than Java 15.
2023-03-18 09:54:20 +01:00
Florian Schmaus
24782558d6 [sinttest] Properly handle AbstractSmackSpecificLowLevelIntegrationTest
Subclasses of AbstractSmackSpecificLowLevelIntegrationTest have test
methods with no parameters. This was, after the refactoring in
c5bb15c631 ("[sinttest] Add UnconnectedConnectionSource for
low-level tests") not handled properly.

Fixes: c5bb15c631 ("[sinttest] Add UnconnectedConnectionSource for low-level tests")
2023-03-17 20:28:14 +01:00
Florian Schmaus
6d2216858c [sinttest] Cleanup method signature in ModularXmppClientToServerConnectionLowLevelIntegrationTest 2023-03-17 20:25:34 +01:00
Florian Schmaus
f78eade4da Merge branch '4.4' 2023-03-17 18:20:20 +01:00
Florian Schmaus
2e79a6b718
Merge pull request #558 from Flowdalic/iq-error-with-child-element
[core] Fix ErrorIQ displaying potential child elements
2023-03-17 18:18:28 +01:00
Florian Schmaus
bf3a27df9a [core] Fix ErrorIQ not showing potential original IQ child
Also delete StanzaIdTest since the test was fundamentally weak and
flawed. It does not work anyway, since TestIQ has a fixed stanza ID.

Fixes SMACK-931.
2023-03-17 18:03:57 +01:00
Florian Schmaus
9ec67611a0
Merge pull request #560 from Flowdalic/ubuntu-22.04
[github ci]: Bump to Ubuntu 22.04
2023-03-17 18:01:51 +01:00
Florian Schmaus
3ba1aba2e3 [github ci]: Disable Java 8 (potentially temprorary)
We currently run into
https://github.com/android-actions/setup-android/issues/378
2023-03-17 17:52:35 +01:00
cmeng-git
ef0fc01505 Rename ELEMENT 'candidate-activated' to 'activated' per XEP-0260
Fixes SMACK-930.
2023-03-17 17:48:15 +01:00
Florian Schmaus
d93fbacc35
Merge pull request #546 from bgrozev/fix-npe-when-missing-x
Add null check for mucUser.
2023-03-17 17:45:43 +01:00