Age | Commit message (Collapse) | Author |
|
Fix how DiscoServiceWalker handles it disconnections from the
discoInfoRequests and discoItemsRequest, as per swiften patch 'Fix
memory leak warnings by Valgrind/LSAN'
(b00c84574fc730eeeabb57df1f17b54855218193).
Test-information: Unit tests pass ok.
Change-Id: If47dca0f89822b0bf1da8dab1a3113a969f1c396
|
|
As per swiften patch of the same name
(37aafcb4d693a0b4f5944a52e0c070e5aa384245) changes behaviour of VCard
cache slightly, and updates test accordingly.
Test-information: Unit tests pass.
Change-Id: I933c8000b4cb73b43db28db94887a768d0272dd2
|
|
As per patch 'Stop throwing out of range exception from
dateTimeToLocalStrin' (eed183fbd5d121049d5965d7c60abd65f44d0376). In
swiften when DateTime.dateToLocalString was passed a pre 1970 date it
could throw an out of range exception. Swiften code was fixed to
return an empty string in this case.
In java we do not see this error so no need to modify DateTime code.
Instead I just added a test to verify we can cope with pre 1970 dates.
Test-information: Unit tests pass.
Change-Id: Ie1db328818d1457a17e68ab891f564d169912320
|
|
As per swiften patch 'Fix notification logic for signals in BlockListImpl'
(4455c20085834098f6d9aa872db3115d466e7004). Fix the logic in the BlockListImpl
class and add a unit test for it.
Test-information: Unit tests pass ok.
Change-Id: I739d1febb2cf728ff00c132a00adb2f7f144b739
|
|
Add the Whiteboard classes to stroke.
Test-information:
Unit tests all pass.
Change-Id: Id409c09d0fc1f82864e5d706c413b9d984a7db82
|
|
Add missing methods and classes in the TLS and Base packages where
possible. In the case of TLSContextFactory the methods could not be
implemented in java so added a not saying they are not supported in
java.
Test-information:
Unit tests still build and run ok.
Change-Id: I9be2035f092875fcdc02644a3c0082739f26949a
|
|
Add the BOSHSessionStream class to stroke.
Also tidy up PortingProgress.txt there were some files it was saying had not
been imported when they had.
Test-information:
Code inspection as there are no unit tests for the new code.
Sanity test all existing unit tests pass.
Change-Id: Ia049a008f0d2c39c23f5752aa7740b10f48aa397
|
|
Add classes to the parser and serializer packages, including some tests.
Update PortingProgress with info on the classes that could not be imported in
this patch.
Test-information:
Unit tests pass ok.
Change-Id: If42af9c0cecb68151cf817f1839b86b4d7c8967c
|
|
As per PortingProgress.txt finsh porting all the classes I can from the network
package. This involved some updates as the tests and code had changed since
they existing classes had been imported.
I have added notes for the classes I did not port in PortingProgress explaining
why they were not ported.
Test-information:
All unit tests pass.
Change-Id: Ibb52ae409f1da9b72a4c1e590cd22835a1be95eb
|
|
Add the sortResult static method to the DomainNameServiceQuery class. This
required adding a few equivalances for C++ std library methods to the class. And
add a test for the new method too.
Test-information:
All unit tests pass ok.
Change-Id: Idee0888f7ea140d35a971414fc2fd3cbcdfc337f
|
|
Add the missing Bosh classes to the network packages (BoshConnection
and BoshConnectionPool), plus tests for the classes and any other
classes required by the new classes.
Test-information:
Units tests all pass ok.
Change-Id: I5c2e05bae9e678ac10d2601c7fdbdccd68d66b71
|
|
Add the missing FileTransfer tests to stroke. When porting the tests
I found some of them were failing and required changes to the classes
being tested to fix. Had to add a DummyNetworkEnvironment as well for
the OutgoingJingleFileTransferTest.
Test-information:
All unit tests pass.
Change-Id: Id511a556ef3a5d66e0e107f36f736db3bbb3a437
|
|
There ware duplicate copies of DummyFileTransferManager and
DummyFileTransferTransporterFactory in both stroke src and stroke test
directories (but within the same package). This was confusing and
could cause problems when we come to update the files.
This patch removes the copies in the test directory, leaving only the
the src directory ones.
Test-information: Ran 'make test' everything still builds ok and all
tests pass.
Change-Id: I112d2b21e1217dcacd619393f81ba008a097e83a
|
|
Finish porting S5BTransportSession to Stroke (previously a lot of it had been commented out). To
do so had to introduce a heirachy to the SOCKS5BytestreamSession classes (which were being used as
type parameters for the Transport Session) and refactor some of the onByteSent signals to insure
they were all of the same type (Integer).
Also update PortingProgress.txt to update to give status of some of the porting files.
Test-information:
Ran unit tests they all still pass.
Change-Id: I4295b3a8829c208e65f5a46d19c35090f8c55865
|
|
Add the IQTest class.
Test-information:
All tests pass.
Change-Id: I1fa14c275f9fbe19f4b21002b300024334d5a9da
|
|
Adds the CombinedAvatarProviderTest class.
When I was adding the test I noticed that
testProviderUpdateWithAvatarDisappearingTriggersChange kept failing
due to a bug in the CombinedAvatarProvider class and
testRemoveProviderDisconnectsUpdates could not be implemented as the
class was incomplete.
I had to make some changes to CombinedAvatarProvider to fix these
issues.
Test-information:
Ran unit tests they all pass.
Change-Id: I0bfb68dd2b15df0f220f36c136aceadaf6545893
|
|
Update the porting notes in PortingProgress.txt to be inline with
latest changes.
Change-Id: I0e8d69c6795d75614077867b556eb530c7b5d144
|
|
Add BlockParser and BlockSerializer for the block payload classes.
This required slightly different approach to the Swiften code as C++ templates
are different to Java generics. In short needed to add a type hierachy to the
Block payload classes and to the Parsers and Serilaizers associated with them.
Test-information:
Ran unit tests everything passed ok.
Change-Id: I3ea2d66afd7cb3b5c4c3515be3a1ef99d7dbb566
|
|
Updates the FullPayloadSerializerCollection and
FullPayloadParserSerializerCollection to bring it inline with the Swiften
classes. This included reordering the elements so they are in the same order as
the Swiften class (so its easier to see classes that are missing), and adding
ones that were missing. For ones where no Java implemenation exits yet the line
is added but commented out.
Test-information:
Sanity test, ran unit tests all test still pass.
Change-Id: I318c8da577f638f4d799fabdfc09a3afa7fcb608
|
|
Adds a S5BProxyRequestParser and a S5BProxyRequestSerializer to stroke based on the Swiften classes of the same
name. These has been missed out previous stroke patches for some reason.
Test-information:
Code inspection against the Swifen classes.
Sanity test ran the unit tests for stroke they still all pass (note I could not
find any unit tests for this class to transfer from Swiften).
Change-Id: Ic5463169ada33c72127e87a416d42a650aad6399
|
|
There has been some changes to the file transfer clases in Swiften since Tarun's
patch was written. This patch updates the java classes to bring them in line
with the swiften one.
In details
IBBSendSession - added code to clean up onResponse connection when not needed.
In Swiften this was done by keeping reference to current session using boost
bindings to remove binding. In java we have to keep a reference to the current
onResponse connection and disconnect it when not neeeded.
IncomingFileTransferManager - Remove redundant IQRouter field.
LocalJingeTransportCandidateGenerator - Do not advertise link-local IPv6
addresses in FT candidates
OutgoingSIFileTransfer - File deleted
SOCKS5BytestreamProxiesManager and SOCKS5BytestreamProxyFinder - Search for all
proxies instead of just one.
Test-information:
Ran make and make test to check everything built ok and that the unit tests
still passed.
Change-Id: I696444e5074fe20625243693a44c836306b3a41e
|
|
Updates Progress to file to indicate progress of recent patch, i.e. Queries, MUC, VCards, StreamStack, Compress,
AdHoc, EventLoop, SASL, Session, TLS, Presence, Client, StringCodecs, Network, PubSub, StreamManagement, Jingle, FileTransfer.
License:
This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.
Test-Information:
None.
Change-Id: I5e90d8b2348e43f60a53b2f0a1faa8289e1537cf
|
|
Some fixes that were required for the File Transfer Patch (see patch notes
on Gerrit).
Test-information:
By code inspection.
Ran against MLC (after modification so it works for stroke interface changes
introduces in a previous patch) it still runs correctly.
Ran unit tests they still all pass.
Change-Id: Ib49d9f9160f5e6b6b578f16695f8e8bc0f96a412
|
|
S5BTransport Session still needs generic T.
FileTransfer, OutgoingFileTransfer and IncomingFileTransfer are made an interface due to the need of multiple inheritance in
IncomingJingleFileTransfer and OutgoingJingleFileTransfer. Corresponding documentation has been updated.
License:
This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.
Test-Information:
None.
Change-Id: If44cf387767865c37492d871c12d623f94ebaa3a
|
|
Some fixes to the Jingle classes for the previous patch.
Test-information:
By code inspection.
Ran Unit Tests there were no failures.
Change-Id: I61210dd1ec2c7e0dd11d67a45a0ced63952804c7
|
|
Adds Listenable, JingleSession, JingleContentID, FakeJingleSession, JingleSessionListener,
JingleSessionManager, JingleResponder.
NotifyListeners are not in line with Swiften and have to be corrected.
License:
This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.
Test-Information:
None.
Change-Id: I6533b2be02a0843277a63ca115348ff6138a0fc0
|
|
Small changes to PubSubManagerImpl and StanzaAckRequester making them equivalent with Swiften.
License:
This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.
Test-Information:
Added tests for StanzaAckResponder and StanzaAckRequester, which passes.
Change-Id: I99878fc6552ed18e353848a0cea6584c26b2ba0c
|
|
Some more changes to the Networks classes. Based on comments on the last
patch.
Test-information:
No longer see crash I was seeing when I ran the updated Stroke against MLC.
Ran unit tests.
Change-Id: Id577e5322bab0ec48f0353907f82e72bc93b848a
|
|
Adds ProxyProviders, DomainNameResolvers and DummyConnection.
License:
This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.
Test-Information:
Tests added for ChainedConnector, Connector and HostAddress.
Test also added for ComponentConnector, which needed bits of Network.
Five assertions are commented in ConnectorTest, which fails and will be updated after review.
Change-Id: I8a62841eb2f9c109bc3a94865b7a003b33493e11
|
|
Remove calls to TimeZone.setDefault().
Whatever problem the changes that introduced these calls were supposed
to solve, overriding the system default timezone is not the right
solution.
Change-Id: I626419a1c00fe9d68df0c63472d4433e12502acb
|
|
If a JavaConnection is supplied with a JavaConnection.ActivityWatcher at
creation time, then each of its Worker threads will signal when they
become active and when they potentially go to sleep (on select()).
This allows clients to manage a device's power state or any other
suitable subsystem.
Change-Id: I3c83cb8ce5a087dd6fc5d402c75f830f5deca282
|
|
Given that doRead() ends up populating a SafeByteArray as part of the
result is is more efficient to pass an empty SafeByteArray to doRead()
and push each chunk of data read directly to the it rather than use an
intermediate ByteArrayOutputStream. SafeByteArray.getData() will do any
concatenation necessary.
It is unnecessarily inefficient to use a class instance to return the
connection status from doRead. Remove JavaConnection.ReadResult.
Change-Id: I6c8dc000d9030d3929c71444eb5b489df93f1987
|
|
Refactor JavaConnection to make it fully event-driven via select for
both reads and writes. Remove the 100ms spin when there are pending
writes.
Encapslate all the management of the select mask and the write queue
within Worker and protect via a common lock.
Change-Id: I1a709f9b12a949448923f51c2d434746c9190c9d
|
|
Missing initialisation for client authenticator for SASL external was
causing null pointer exceptions. This patch corrects it by initialising
the authenticator as is done in swiften.
Test-information:
tested using an XMPP admin client that does SASL External
Change-Id: I321b425c1c28e0424effd9cb974980c392e48b68
|
|
The IDNConverter interface now throws java strandard IllegalArg exception
instead of the ICU specific StringPrepParseException. Users of stroke that
are not using ICU will now be able to use it without the icu jar.
Test-information:
Sanity tested by connecting to an XMPP server using an XMPP client
Change-Id: I6999ae0c690b70bc748f131908a758a01dac20b9
|
|
The default, clean finish() method needs to set up no error, not a null
instance of Error.Type (with type field == null).
Change-Id: I6912392b226dd84c411e2369844b9aee656d2e6f
|
|
Change-Id: I2ccf6ae1293859dc8bd49731ee55a90b383d30a8
|
|
Change-Id: I50c4eb6ab33a8136245c76e5ecf45cc8134372ec
|
|
Change-Id: I41924cdd6d32deb9d47b47a3fc7ffb3b55947029
|
|
Remove SHA1 and HMACSHA1 from StringCodecs as they are already provided by CryptoProvider,
and is equivalent to Swiften.
License:
This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.
Test-Information:
Add tests for Base64 and PBKDF2, which passes.
Change-Id: Ife05f185a10a79c9d69a12235f1b0397d022d992
|
|
Updates all bits of Client to be in parity with Swiften.
Some part of code which depends on Network is commented.
License:
This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.
Test-Information:
Tests added for: ClientBlockListManager, ClientSession and NickResolver.
All tests pass.
Change-Id: I5b9b0e5ae5b2df58202e2349ba24e4544d9a4614
|
|
Updates DirectedPresenceSender, PayloadAddingPresenceSender, PresenceOracle and SubscriptionManager.
License:
This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.
Test-Information:
Tests added for: DirectedPresenceSenderTest, PayloadAddingPresenceSenderTest and PresenceOracle.
All tests pass.
Change-Id: I9ad899965f5ac32c6f21805b530c234e391be6ba
|
|
Adds TLSError and TLSOptions.
Updates BasicSessionStream, SessionStream and Session.
Updates Client and Components to accomodate changes in TLS.
Also completes TLSLayer in StreamStack which was pending due to TLS port.
License:
This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.
Test-Information:
Tests added for Certificate and ServerIdentityVerifier.
Test updated for ComponentSession.
All tests pass.
Change-Id: I34a8fe068c1e8af5348cc4ab49d3d1ed118ae833
|
|
The way a VCard is used, pessimistic allocation puts an undue load on
the Java GC.
Change-Id: Ifced03a759783db2de911fc22dd40f6e475e5596
|
|
Clean up imports.
Add @Override annotations as appropraiate to MUCImpl and MockMUC.
Change-Id: Id34849364fe1e4cdd7709b2cc7b397d007c2868c
|
|
Use and ArrayList<byte[]> as the internal storage, instead of
Vector<Byte>.
Constructors and methods that supply a byte[] to add to the instance
will have that value copied, rather than just taking ownership of the
byte[]. There is an argument, on efficiency grounds, for providing
methods that take ownership of the supplied argument.
The earlier discussions about use of synchronization in the class are
revisited. This is a low-level container that should be thread-safe or
take precautions against non-thread-safe use. It is anticipated that the
vast majority of uses will be thread-safe. Use of synchronization
permits occasional deviations from this without imposing any significant
overhead for the normal case - uncontended synchronization is close to
free.
Change-Id: Ifb7b2915d5c96345c53aec8e33673d892c430431
|
|
Most of the time when VCard.getPhoto() is called it is only used to
determine presence or absence of a photo. Thus, it makes no sense to
allocate an empty ByteArray() just for this purpose. Return null
instead, if absent.
Change-Id: I3bae02ffbece5589c74c950bbb4c0db6c0376c76
|
|
Adds DIGESTMD5ClientAuthenticator, DIGESTMD5Properties, ExternalClientAuthenticator, PLAINMessage.
Updates Client, ClientSession, CoreClient, ConnectDisconnect, StrokeGUI to reflect changes made in SASL.
Updates ClientAuthenticator, SCRAMSHA1ClientAuthenticator, PBKDF2.
License:
This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.
Test-Information:
Added tests for DIGESTMD5ClientAuthenticator, DIGESTMD5Properties, PLAINClientAuthenticator, PLAINMessage.
Update test for SCRAMSHA1ClientAuthenticatorTest.
All tests pass.
Change-Id: I4fd38f922cab7e4c4548d9706f6ad3b9e1506e81
|
|
Adds SingleThreadedEventLoop.
License:
This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.
Test-Information:
Tests for EventLoop and SimpleEventLoop passes.
Change-Id: Ifda63a328e0adfb2da0eb2a1038805042ed0f6fb
|
|
A recent change (9ead0fdcca595df9dc3f4143122776b398dbe405) made MUC an
abstract class, and moved all functionality into MUCImpl (to
correspond with Swiften). The "disconnect()" method was moved to
MUCImpl, which means that any existing application which used it would
break.
The disconnect() method is required in java (although it's not in
Swiften) because it provides a way to disconnect signals that are
connected in the MUC constructor (or MUCImpl constructor now). While
the signals are connected, the MUC object will not be eligible to be
garbage collected, and this can lead to growing memory usage for an
application which creates lots of MUC objects for a given connection.
Adding a call to "disconnect()" in the finalizer for the MUC would not
be effective because the finalizer only gets called when the MUC is
gc'd, and the MUC can't be gc'd until the disconnect() has happened.
Test-information:
Unit tests pass.
Before this change, an application calling "MUC.disconnect()" fails to compile.
After this change, the application compiles.
Tested an app that creates lots of MUC objects, and checked, using the
debugger, to see if the objects were being garbage collected when the
application dropped its reference to the objects.
When not calling "disconnect()", the MUC objects are not garbage
collected until the owning StanzaChannel is closed.
When a call to "disconnect()" was added, the MUC objects are garbage
collected soon after the application finishes using them, even though
the StanzaChannel is still in use.
Change-Id: Icd6c354e34d2124c292ae5d44bc47725a6e73df5
|