Uploaded image for project: 'VYSPER'
  1. VYSPER
  2. VYSPER-189

GSoC: Implement WebSockets/BOSH for XMPP AJAX clients

Details

    • Task
    • Status: Open
    • Major
    • Resolution: Unresolved
    • None
    • None
    • BOSH, extension

    Description

      Apache Vysper is a modular, Java based XMPP/Jabber server. This project aims at developing a Vysper extension that enables AJAX clients to be a XMPP client, for example making it simple to expose IM/chat functionality in web apps.

      BOSH (XEP-124, XEP-206) defines a protocol where XMPP/Jabber can be used by AJAX clients. Also, with the development of WebSockets within the HTML5 work, WebSockets could be used as a way for browsers to communicate with Apache Vysper. This project could use either (or both) these protocols.

      Attachments

        1. ASF.LICENSE.NOT.GRANTED--bosh.patch
          198 kB
          Bogdan Pistol
        2. vysper_0.1.patch.tar.gz
          56 kB
          Bogdan Pistol

        Activity

          moga_florian Florian Moga added a comment -

          I am interested in developing this as part of the GSoC. How can I contact the mentor for this project for further information?
          Thank you.

          moga_florian Florian Moga added a comment - I am interested in developing this as part of the GSoC. How can I contact the mentor for this project for further information? Thank you.

          The best place to discuss the project is on our project mailing lists, where you will also find me. Join the development mailing list as described here: http://mina.apache.org/vysper/mailing-lists.html

          niklas Niklas Therning added a comment - The best place to discuss the project is on our project mailing lists, where you will also find me. Join the development mailing list as described here: http://mina.apache.org/vysper/mailing-lists.html

          Students who want to make themselves familiar with the topic can be recommended to read
          + RFC 2616: http://tools.ietf.org/html/rfc2616
          + RFC 3920: http://xmpp.org/internet-drafts/draft-ietf-xmpp-3920bis-05.html
          + XEP-124: http://xmpp.org/extensions/xep-0124.html
          + XEP-206: http://xmpp.org/extensions/xep-0206.html

          brainlounge Bernd Fondermann added a comment - Students who want to make themselves familiar with the topic can be recommended to read + RFC 2616: http://tools.ietf.org/html/rfc2616 + RFC 3920: http://xmpp.org/internet-drafts/draft-ietf-xmpp-3920bis-05.html + XEP-124: http://xmpp.org/extensions/xep-0124.html + XEP-206: http://xmpp.org/extensions/xep-0206.html
          bogdan.pistol Bogdan Pistol added a comment -

          An initial prototypical patch that implements a BoshEndpoint.
          The BoshEndpoint uses AsyncWeb to parse messages.
          The attached patch just parses HTTP and responds back with a status HTTP message (it works with SSL also - activated by default).
          In the next step I will integrate a Bosh XMPP decoder that will use the decoded HTTP message to extract the stanzas.

          bogdan.pistol Bogdan Pistol added a comment - An initial prototypical patch that implements a BoshEndpoint. The BoshEndpoint uses AsyncWeb to parse messages. The attached patch just parses HTTP and responds back with a status HTTP message (it works with SSL also - activated by default). In the next step I will integrate a Bosh XMPP decoder that will use the decoded HTTP message to extract the stanzas.

          I think before we dig too deep into any implementation of this, we should have a public discussion how we plan to implement it.

          brainlounge Bernd Fondermann added a comment - I think before we dig too deep into any implementation of this, we should have a public discussion how we plan to implement it.
          bogdan.pistol Bogdan Pistol added a comment -

          The right place for a discussion is on jira or on the mailing list?

          In my view the decoder could be like:

          raw bytes --> AsyncWeb decoder --> XML extraction --> stanza creation --> Bosh IoHandler

          and the encoder:

          stanza --> XML serialization --> AsyncWeb encoder --> raw bytes

          The Bosh IoHandler could work with a Bosh StanzaProcessor that would eventually process with some Bosh StanzaHandlers the stanzas and then it will send the processed (as defined by XEP-0206) stanzas to the XMPP StanzaProcessor.

          What do you think?

          bogdan.pistol Bogdan Pistol added a comment - The right place for a discussion is on jira or on the mailing list? In my view the decoder could be like: raw bytes --> AsyncWeb decoder --> XML extraction --> stanza creation --> Bosh IoHandler and the encoder: stanza --> XML serialization --> AsyncWeb encoder --> raw bytes The Bosh IoHandler could work with a Bosh StanzaProcessor that would eventually process with some Bosh StanzaHandlers the stanzas and then it will send the processed (as defined by XEP-0206) stanzas to the XMPP StanzaProcessor. What do you think?
          bogdan.pistol Bogdan Pistol added a comment -

          This patch adds Jetty 7 dependency (in pom.xml) and implements a basic connector for Vysper that uses Jetty to respond to BOSH clients with a simple response.
          This only implements the initial response from Vysper connection manager, it does not go further.

          The implementation is very basic, it does not use nbxml parser. It needs to be updated to use the XML parser.

          For testing I used Strophe.js client (the code for testing is included).

          Because of off-line browser security restrictions you need to set-up apache or some other HTTP server to serve the client files.

          The client test uses flXHR Flash library to circumvent XHR restrictions on connecting on a different domain, so this will not be a concern.

          When connecting I set-up to connect to the <vysper.org> domain name (in hello.js), which isn't registered, and you need to modify /etc/hosts (or on windows windows\system32\drivers\etc\hosts)
          to have an entry "127.0.0.1 vysper.org" so that vysper will be resolved to the loop-back address.

          In the client there will be no graphical notification as the server doesn't do much for now. There will be logs in Vysper only.

          bogdan.pistol Bogdan Pistol added a comment - This patch adds Jetty 7 dependency (in pom.xml) and implements a basic connector for Vysper that uses Jetty to respond to BOSH clients with a simple response. This only implements the initial response from Vysper connection manager, it does not go further. The implementation is very basic, it does not use nbxml parser. It needs to be updated to use the XML parser. For testing I used Strophe.js client (the code for testing is included). Because of off-line browser security restrictions you need to set-up apache or some other HTTP server to serve the client files. The client test uses flXHR Flash library to circumvent XHR restrictions on connecting on a different domain, so this will not be a concern. When connecting I set-up to connect to the <vysper.org> domain name (in hello.js), which isn't registered, and you need to modify /etc/hosts (or on windows windows\system32\drivers\etc\hosts) to have an entry "127.0.0.1 vysper.org" so that vysper will be resolved to the loop-back address. In the client there will be no graphical notification as the server doesn't do much for now. There will be logs in Vysper only.

          People

            niklas Niklas Therning
            niklas Niklas Therning
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: