null
if synchronization point was successful, or the failure Exception.
*/
- public E sendAndWaitForResponse(TopLevelStreamElement request) throws NoResponseException,
+ public Exception sendAndWaitForResponse(TopLevelStreamElement request) throws NoResponseException,
NotConnectedException, InterruptedException {
assert (state == State.Initial);
connectionLock.lock();
@@ -103,15 +106,14 @@ public class SynchronizationPointnull
if synchronization point was successful, or the failure Exception.
*/
- public E checkIfSuccessOrWait() throws NoResponseException, InterruptedException {
+ public Exception checkIfSuccessOrWait() throws NoResponseException, InterruptedException {
connectionLock.lock();
try {
switch (state) {
@@ -145,7 +148,7 @@ public class SynchronizationPoint
@@ -264,7 +309,7 @@ public class SynchronizationPoint
*
- * Refer to Jabber::Registrar
+ * Refer to XMPP Registry for Service Discovery Identities
* in order to get the official registry of values for the category and type
* attributes.
*
@@ -327,7 +327,7 @@ public class DiscoverInfo extends IQ implements TypedCloneable
+ * We use a {@link ConcurrentLinkedQueue} here in order to allow the listeners to remove
+ * themselves after they have been invoked.
+ *
+ * Those listeners will be invoked every time a Stanza has been dropped due to a failed SM resume. They will not get
+ * automatically removed. If at least one StanzaDroppedListener is configured, no attempt will be made to retransmit
+ * the Stanzas.
+ *
diff --git a/smack-tcp/src/test/java/org/jivesoftware/smack/tcp/PacketWriterTest.java b/smack-tcp/src/test/java/org/jivesoftware/smack/tcp/PacketWriterTest.java
index c72996783..c28ec85e4 100644
--- a/smack-tcp/src/test/java/org/jivesoftware/smack/tcp/PacketWriterTest.java
+++ b/smack-tcp/src/test/java/org/jivesoftware/smack/tcp/PacketWriterTest.java
@@ -1,6 +1,6 @@
/**
*
- * Copyright 2014 Florian Schmaus
+ * Copyright 2014-2019 Florian Schmaus
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -49,11 +49,9 @@ public class PacketWriterTest {
@Test
public void shouldBlockAndUnblockTest() throws InterruptedException, BrokenBarrierException, NotConnectedException, XmppStringprepException {
XMPPTCPConnection connection = new XMPPTCPConnection("user", "pass", "example.org");
- final PacketWriter pw = connection.new PacketWriter();
- connection.packetWriter = pw;
- connection.packetReader = connection.new PacketReader();
+ final PacketWriter pw = connection.packetWriter;
connection.setWriter(new BlockingStringWriter());
- pw.init();
+ connection.packetWriter.init();
for (int i = 0; i < XMPPTCPConnection.PacketWriter.QUEUE_SIZE; i++) {
pw.sendStreamElement(new Message());
diff --git a/version.gradle b/version.gradle
index 683627553..82e39bdf3 100644
--- a/version.gradle
+++ b/version.gradle
@@ -1,9 +1,15 @@
allprojects {
ext {
- shortVersion = '4.3.1'
+ shortVersion = '4.3.4'
isSnapshot = true
- jxmppVersion = '0.6.3'
- miniDnsVersion = '0.3.2'
+ // When using dynamic versions for those, do *not* use [1.0,
+ // 2.0), since this will also pull in 2.0-alpha1. Instead use
+ // [1.0, 1.0.99].
+ // See also:
+ // - https://issues.apache.org/jira/browse/MNG-6232
+ // - https://issues.igniterealtime.org/browse/SMACK-858
+ jxmppVersion = '[0.6, 0.6.999]'
+ miniDnsVersion = '[0.3, 0.3.999]'
smackMinAndroidSdk = 9
}
}
true
if synchronization point was successful, false
on failure.
* @throws NoResponseException
*/
- private E checkForResponse() throws NoResponseException {
+ private Exception checkForResponse() throws NoResponseException {
switch (state) {
case Initial:
case NoResponse:
@@ -273,7 +318,7 @@ public class SynchronizationPoint