Current Liferay poller implementation is AJAX based, it recusively fires send and receive ajax request.
This implementation uses node/sockjs to use HTML5 websockets for supported browsers and long polling for other browsers.
Liferay node poller consists a hook available in plugins sdk and a nodejs/sockjs server named as NodePoller.
-
Install node.js
-
Clone the repo:
git clone git@github.com:saggiyogesh/liferay-node-poller.git
or download the source.
-
In NodePoller folder install the dependencies:
npm install
-
Edit the Liferay server url in
poller.properties
-
Run nodejs server, listening on port 9999.
node server
- In
portal-ext.properties
file edit the NodePoller url. - Deploy Liferay chat portlet from market place.
- Deploy 'liferay-node-poller-hook-6.1.1.1.war' available in dist folder of plugins sdk.
Note: Hook should be deployed at last.
Now Liferay is configured with Node poller.
To remove this, simply undeploy liferay-node-poller-hook from Update Manager in Liferay.