Project

General

Profile

A light weight xmpp robot?

Matthew M
Added about 4 years ago

I wonder what would be best practice to implement a xmpp robot in the system that meet 2 requirements

  1. Any online user can see robot as "Available / Online" presence status.

  2. Robot can respond to some simple incoming message such as "Robot says hello!".

One way is to create a xmpp client as a robot connecting to Tigase all the time, and let robot be in the roster of every user (in order to show the presence status).

But I am afraid this might cause huge traffic of presence stanza, related to all users and the robot. As the robot does not really care if the users are online or not, is there an easy to implement a robot in Tigase (as a component) to avoid extensive presence stanzas ?

Thanks!


Replies (1)

Avatar?id=6023&size=32x32

Added by Artur Hefczyc TigaseTeam about 4 years ago

If you control the server you can easily inject roster item for all users using DynamicRoster API. To avoid excessive presence traffic to the robot, I suggest using one-way presence subscription only. This way users will see the robot but the robot will not receive users' presences.

    (1-1/1)