Xmppclient Library Smack 4.0. Development of 61 versions

Source: Internet
Author: User

Xmppclient Library Smack 4.0.6 version of the development of a

Chszs, reprint need to indicate. Blog home:Http://blog.csdn.net/chszs

I. Overview of the SMACK Library

Smack is an open-source, easy-to-use Xmpp/jabberclient library, developed in the Java language and developed by Jive Software.

The advantage of smack is simple programming.

Smack's disadvantage is that its API is not designed for a large number of concurrent users, each customer has 1 threads, occupy a relatively high resource, so with smack to do simulation test, 1 machines can only simulate a limited (thousands of) customers.

As of November 27, 2014, the Smack Library has been developed to 4.0. Version 6.

The latest good news is that smack will support the Android system directly after the 4.1.0 release, without the need to use the Smack ported version Asmack library.

Smack Library source code hosted on GitHub, home see: https://github.com/igniterealtime/Smack/



Ii. Changes in Smack 4

Smack Library from 3.4 to 4.0.x version, its API has a large change, mainly:

1. Rename the connection class to Xmppconnection class

The Xmppconnection class is the parent class of the Xmpptcpconnection class and the Xmppboshconnection class.

2, the various provider class has been subcontracting

3. Keep-alive (persistent connection) mechanism moved from the Smack-core library to the Smack-extensions library

The keep-alive mechanism is now provided by the Pingmanager class.

4. The ToString () method of the Privacylist class is renamed to GetName ()

5. When all the references to the chat instance are removed, the Chat.close () method should be called

Otherwise, the chat object will have a hidden memory leak, until the Chatmanager object is reclaimed by the garbage collector and the memory leaks are hidden.

6, Servertrustmanager class was removed

Assuming you want to use XMPP with SSL authentication, you just need to provide your own Sslcontext object to the Connectionconfiguration object.

7, Packet.setproperty () moved from the Smack-core library to the Smack-extensions library

Its API can now be found in the Org.jivesoftware.smackx.jiveproperties package.

8, Connection.getaccountmanager () method is now changed to Accountmanager.getinstance (Xmppconnection) method

9, the exception API has been improved

10, Tocontains filter was removed


Xmppclient Library Smack 4.0. Development of 61 versions

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.