[ejabberd] EXMPP and PubSub Publishing

Tristan Sloughter kungfooguru at gmail.com
Thu Sep 24 00:21:20 MSD 2009


I build and send it with:

XML = [#xmlel{name=topics, attrs=[#xmlattr{name=xmlns, value= <<"
http://www.chatyeo.com/2009/Topics">>}], children=[#xmlel{name=topic,
children=[#xmlcdata{cdata= "Rza"}]}]}],
exmpp_session:send_packet(Session,
exmpp_client_pubsub:publish(<<"pubsub.localhost">>,
"/home/localhost/another_10/test_4", XML)),

the result for the publish that constructs the XML is:

"<iq xmlns=\"jabber:client\" type=\"set\" to=\"pubsub.localhost\"
id=\"pubsub-899574700\">
    <pubsub xmlns=\"http://jabber.org/protocol/pubsub\">
      <publish node=\"/home/localhost/another_10/test_4\">
        <item>
           <topics xmlns=\"\" xmlns=\"http://www.chatyeo.com/2009/Topics\">
             <topic>Rza</topic>
            </topics>
        </item>
      </publish>
    </pubsub>
  </iq>"

On Wed, Sep 23, 2009 at 2:23 PM, Pablo Polvorin <
pablo.polvorin at process-one.net> wrote:

> Hi,
> could you provide more details? that will help us identify what is going
> on.
> How are you building the publish stanzas?.  What XML is generated?
> ( you can see the xml sent  by raising ejabberds's loglevel  or  by
> printing
>  the results of  exmpp_xml:document_to_list(YourStanza) )
>
>
>
>
> 2009/9/23 Tristan Sloughter <kungfooguru at gmail.com>:
> > I've gotten creating and subscribing to nodes working fine with EXMPP and
> > EJabberd 2.0.5 and 2.1rc1; however, I could only successfully publish a
> list
> > of a single #xmlcdata element on 2.0.5 and nothing at all on 2.1rc1.
> > Obviously, I'd like to be able to publish a list of #xmlel elements as
> the
> > item or items. There is no useful error message when I attempt to publish
> to
> > a node I created. The only message is:
> >
> > =INFO REPORT==== 2009-09-23 13:24:37 ===
> > I(<0.410.0>:ejabberd_c2s:1326) :
> > ({socket_state,gen_tcp,#Port<0.3412>,<0.409.0>}) Close session for
> > another_10 at localhost/exmpp#1253730276407777
> >
> > Does anyone have any guess as to what could be causing this to happen?
> I'm
> > lost for ideas at this point...
> >
> > Thanks,
> > Tristan
> >
> > _______________________________________________
> > ejabberd mailing list
> > ejabberd at jabber.ru
> > http://lists.jabber.ru/mailman/listinfo/ejabberd
> >
> >
>
>
>
> --
> Pablo Polvorin
> ProcessOne
> _______________________________________________
> ejabberd mailing list
> ejabberd at jabber.ru
> http://lists.jabber.ru/mailman/listinfo/ejabberd
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.jabber.ru/pipermail/ejabberd/attachments/20090923/7b1b1520/attachment.html>


More information about the ejabberd mailing list