Jappix MiniChat with Openfire

Image2.jpg

I have received a couple of emails about Jappix MiniChat not working properly with Openfire BOSH. The main issue seems to be that the Openfire BOSH is not handling the reconnection properly as the user browses from page to page.

I’ll be surprised if it did as the implementation was a few years ago and the BOSH specification has moved on since. More importantly was that it was designed to work with SparkWeb which was always resident on the web page until the user logged off. In this mode, Openfire BOSH works very well.

A possible solution for using Jappix MiniChat with Openfire is to use this same approach and keep Jappix resident on the web page as the user browses from page to page. My way of doing this is to use a main top page container with the Jappix MiniChat which puts the content web page in an

Of course, this does not always work especially if the content page promotes itself to be the top main page for security purposes like Goole Mail for example. In practice, I use Jappix MiniChat with my own web applications and even if my web page is hijacked, cross domain security will stop malicious JavaScript controlling my application.

If this solution will work for you, then use the attached HTML file and adapt it to your needs.
minichat.html.zip (946 Bytes)

1 Like

It is a cross domain problem. To solve cross domain problems, I use Openfire as my HTTP, PHP, BOSH and XMPP server. Everything is in the same place. I suggest you do the same and put your PHP web application inside the Jappix Plugin, otherwise go to the jappix Web site to learn how to configure for different servers. You could read the comments on this blog http://community.igniterealtime.org/blogs/ignite/2011/06/26/jappix-for-openfire- plugin to modify the read-main.php and read-hosts.php files.

I am not sure why you have a cache problem. I modify my PHP, HTML, JS files directly without restarting Openfire and I can see the changes. Check you browser settings.

Jappix is not an ignite realtime project. Please go to https://project.jappix.com/ to ask questions

Dele,

I appreciate your hard work & inputs on Jappix mini with openfire. Keep it up. Not sure whether I can be of any help to you.

I need one input on you. Currenlty whenever a new user visit my website, I add them in Openfire DB via direct DB access instead of user service plugin. This new users is not getting reflected immediately in Jappix mini. Unless I do not restart the Openfire, this new users are not reflecting in Jappix Mini. I am not in position to use user service plugin, because I have added one extra column in ofUser to take of their membership ( GOLD or PREMIUM Or FREE )

I am not sure how to handle this situation without restarting the openfire server. Restarting the Openfire server everytime for every new user is not feasible at all.

How can I remove the cache time, or refresh the cache so that new user reflect in Jappix minilist of online users. Please help or advice as this openfire issue not jappix mini.

Clearing the jappix mini /store/cache also do NOT help in reflecting the new Users. I can see that this new Users are online ( Green ) when I check their status in Openfire admin.

Thank you for the kind words

Your problem is NOT Jappix, but the Openfire user cache. You need to tell Openfire to refresh its cache much quicker. Read this post at http://community.igniterealtime.org/docs/DOC-1673.

The property you probably want to change is cache.userCache.maxLifetime. A value of 60000 will force a fresh every minute.

I have added the cache.userCache.maxLifetim as value of 60000 in system properties however it did NOT work. When a new is getting added via DB, It is not reflecting for even 10 minutes however I see them online ( Green ) in openfire. I am not sure whether the below property is causing the problem.

cache.username2roster.maxLifetime 419430400
xmpp.pep.enabled false

They were added for meantime & memory leak in PEP.

Secondly, Please that all the new Users are for a same Group. I mean any two new users are added to one group only.

Please advice should I reduce

cache.username2roster.maxLifetime 419430400 to 60000

I am not sure about impact & performance.

I am not sure the impact & performance I will face but I have done below changes…

Openfire Cache I have set to 60000 ( 1 minute ) for all.


cache.username2roster.maxLifetime

cache.userGroup.maxLifetime

cache.userCache.maxLifetime

cache.group.maxLifetime

**cache.groupMeta.maxLifetime **


This has helped me to get the newuser reflect within span of one minite. Please advice any adverse impact or Memory or concurrent users capacity

There are other people on this community who know Openfire better than me. Go and post your questions to them in the Openfire support forum

To run minichat jappix out server openfire, use in your web-server use this atache.

Copy folder “Minichatoutserver” to your server web and edit files, get run have said!

Edite index.php

Line 68

*Line 60 and 61 - Username and password
*

Edit teste.js

Line 4770

  • *Line 4748

var yourserver = “…”;

Link: http://www.megaupload.com/?d=7UYY3T35

PS: Cumprimentos do Pai Natal oh oh oh

missing the groups! is there any option to show them?

I have Openfire 3.70 along with Jappix 0.7 deleloped by Dele. ( openfire-jappix-370-0.0.1.zip ) It is working fine on all the browsers except on IE9.

On IE9 it is showing encountered errors. However when I click on Compatibility view of IE9, it get connected and work fine. Please help or advice.

Should I upgrade to Jappix 0.8 along with Openfire3.70 ( openfire-jappix370-0.0.2.zip )

It got fixed now… Pls close this. Added below in minichat.html file of jappix

---- NEW CHANGE
- EARLIER

Hi!!

I try to install mini jappix with openfire in my web site since 3 months without succes.

I work in windows enviroment.

Here is how I proceed:

1- I download openfire-jappix plugin

2- I download palladium bosh server

3- I install the palladuim bosh server in tomcat

Whan I test the page [http://127.0.0.1:8080/palladium/http-bind/](http://127.0.0.1:8080/palladium/http-bind/)

I have a page where it is writed:

Palladium

XEP-0124: Bidirectional-streams Over Synchronous HTTP (BOSH)

Active sessions: 0

4- I install the openfire-jappix plugin in openfire

Here I have a problem in the jappix administration.

This is the result of my configuration via [http://127.0.0.1:5280/jappix/:](http://127.0.0.1:5280/jappix/:)
<?xml version="1.0" encoding="utf-8" ?> 127.0.0.1

conference.127.0.0.1

pubsub.127.0.0.1

127.0.0.1

127.0.0.1

    <bosh>[http://127.0.0.1:8080/palladium/http-bind/](http://127.0.0.1:8080/palladium/http-bind/)</bosh>

    <bosh_main>[http://127.0.0.1:8080/palladium/http-bind/](http://127.0.0.1:8080/palladium/http-bind/)</bosh_main>

    <bosh_mini>[http://127.0.0.1:8080/palladium/http-bind/](http://127.0.0.1:8080/palladium/http-bind/)</bosh_mini>

After the configuration I’m not abble to connect I have the message “Authorization failed”

Why I can’t connect to jappix via http://127.0.0.1:5280/jappix/ ?

Thanks

Please please help!!

I have some evolution of my situation.

I work in windows enviroment and try to embed jappix mini in my web site done in java.

My openfire work very well via spark. And even when I connect via jappix admin connection, I have the large jappix page whitch work very well. Like I say now I try to embed jappix mini without succes. This is what I did for that:

My main.xml:

<?xml version="1.0" encoding="utf-8" ?>

Jappix

Jappix Client

jappix

off

on

on

<bosh_proxy>on</bosh_proxy>

<manager_link>off</manager_link>

<groupchats_join></groupchats_join>

on

<https_storage>off</https_storage>

<https_force>off</https_force>

on

<multi_files>off</multi_files>

off

My host.xml:

<?xml version="1.0" encoding="utf-8" ?> afreetech

conference.afreetech

pubsub.afreetech

afreetech

afreetech

/http-bind/

<bosh_main></bosh_main>

<bosh_mini>[http://afreetech:8080/palladium/http-bind/](http://afreetech:8080/palladium/http-bind/)</bosh_mini>

And how I call jappix on my page:

Like you can see I use palladium bosh server whitch work well because when I try this url on the browser I have the page with the message:

"

Palladium

XEP-0124: Bidirectional-streams Over Synchronous HTTP (BOSH)

Active sessions: 0

"

But when when the my page is loaded in the chat panel I just hava a “Plaese wait…” indefinitively. So please what’s wrong?

Please help!!!

I am completely new to Openfire… Planning to use it for our intranet… but some how cant load jappix mini. my chat bar shows error…i have used minichat.html for testing… Please help… I need to use this chat bar with our intranet.

Forget jappix mini… Worst thing and worst issues i ever saw… From network engineer we have to become programmer… Better use Ijab… I have successfully configured it on windows enviroment… loo at my other post for the same.

Hello Daniele,

I have the same issue and don’t get it running. I hope we find a solution! Is there someone who can help us?

Thanks in advance,

Benni

Use the latest code from the project page

https://openfire-jappix.googlecode.com/files/Image6.jpg

Thanks Dele for the new version of pluggin. I configurated it without problems.

When I launch jappix and minichat.html(from openfire) it’s ok.

But now I have my java web site running on a tomcat 7 server, I embbed my mini jappix on a page like this:

jQuery(document).ready(function() { launchMini(false, false, "afreetech","test2@afreetech","test2"); }); I have this error on my web console when I try to conect: -- [12:30:33,249] POST [http://afreetech:8080/http-bind/](http://afreetech:8080/http-bind/) [HTTP/1.1 404 Introuvable 78ms] And I don't know how to send the post to [http://afreetech:7070/http-bind/](http://afreetech:7070/http-bind/) How to allows cross domain? Thanks once again