jdev - 2021-09-02

  1. reng

    how to establishment connection between xmpp and ejabbered server using react native please help me i'm stucking on this past one week

  2. Trbl

    did you implement the protocol?

  3. Trbl

    did you enable http/https endpoints to connect to from a webclient?

  4. Trbl

    or websockets

  5. Sam

    Isn't react a frontend UI thing? I feel like it won't have anything to do with XMPP so I don't understand the question. You'll need an XMPP libary in your language of choice, what you do with your frontend is up to you.

  6. reng

    I have a ejabbered server details like domain name, password id..

  7. reng

    now i have to establish the connection between the server

  8. MattJ

    Check out xmpp.js

  9. Trbl

    > I have a ejabbered server details like domain name, password id.. check the config, make sure bosh is enabled

  10. reng


  11. reng

    please anyone send the code

  12. Sam

    What XMPP library are you using? Are you receiving any errors when you try to connect?

  13. reng

    for connection

  14. Trbl


  15. reng

    i am not start to work on that

  16. reng

    For chatting purpose which xmpp i have to use

  17. Trbl

    you are stuck at getting started for a week?

  18. reng

    i mean library

  19. reng


  20. Sam

    What exactly are you stuck on? Finding a library? Figuring out how to connect using a library you already have? We'll need more information to help you

  21. reng

    i mean (i am not start to work on that) i have tried many libraries but i don't understand that concept

  22. Sam

    Or are you just looking for a client htat uses react native and I'm imsunderstanding?

  23. Sam

    oh, nevermind on the client question, answered it right before I hit send :)

  24. reng

    okay brother

  25. reng


  26. reng

    for reference my senior developer sent this

  27. reng

    but in this chat they has used connectyCube

  28. reng

    but backend developer give me a ejabbered server details

  29. reng

    so i don't know about that

  30. reng

    i have researched on web but i have confusing about it

  31. Sam

    It looks like that example is using websockets to connect, so make sure you have websockets enabled in ejabberd.

  32. reng

    can you send any reference repo

  33. Sam

    I'm still not even sure what part you're getting stuck on or what steps you've completed, so I'm not sure how helpful that would be.

  34. reng

    i am stucking on starting part

  35. reng

    i have server details

  36. reng

    but i don't know how to connect the frontend with that server

  37. Trbl

    "Implement the ‘Connect to Server’ logic"

  38. Trbl

    tells you how

  39. reng


  40. Sam

    That article seems to show that, what part of the article are you getting stuck on?

  41. reng

    to connection establishment part brother

  42. Trbl

    its basically copy past and replacing the connection strings

  43. Trbl

    its basically copy paste and replacing the connection strings

  44. Trbl

    you need to tell us what you are stuck with

  45. Trbl

    what have you tried, what happenes

  46. reng

    no wait

  47. reng


  48. Sam

    I'm sorry, but I still don't understand. Maybe you can show the part you're stuck on and tell us what's not working? Is it trying to connect but spinning forever, are you getting an error, is it just immediately returning?

  49. reng

    this.XMPPServerOptions = {uri: 'wss://chat.connectycube.com:5291', domain: 'chat.connectycube.com'};

  50. reng

    in this code they used connectycube

  51. reng

    instead of connectycube i have to use ejabbered

  52. Trbl

    so replace it with your details

  53. reng

    i need to one this

  54. reng

    how i don't have any idea

  55. Trbl

    chat.connectytybe.com:5291 is a xmpp server

  56. reng

    can you please write for me this code

  57. Trbl

    you replace it with your domain

  58. Sam

    No, we can't. We don't know what your servers details are

  59. Trbl


  60. reng

    ok wait

  61. reng

    i will

  62. Trbl

    while you're at it, please also give us the root password to the server and your social security number

  63. Trbl


  64. reng


  65. reng

    IP: Port number: 5285

  66. reng

    how can i replace this one

  67. Trbl

    chat.connectycube.com:5291 ->

  68. Trbl

    assuming the port is correct

  69. Trbl

    i dont think you can connect to wss:// without a domain name though

  70. Trbl

    IP shouldn't work cause it doesn't have a certificate

  71. reng

    Oh..ok brother

  72. reng

    do you have a telegram

  73. Trbl


  74. reng

    i am stuck na i want to ping you

  75. reng

    for doubt

  76. Trbl

    tell your 'senior' that you need a domain w/ tls certificate

  77. reng

    Ok brother

  78. Sam

    And tell them to make sure websockets are enabled on the ejabberd server. Good luck!

  79. reng

    Okay thanks Sam Trbl

  80. Sam

    Do any clients that maintain a separation between the roster and open chats sync the list of open chats somewhere in a non-standard way? Maybe as a PEP node of JIDs or something? (or is there a standard for this that I've missed?)

  81. Kev

    Sam: The ‘inbox’ stuff?

  82. Sam

    Kev: I dunno, I vaguely remember inbox but I thought it was something different. I'm more looking for whatever anyone is actually doing in the wild as far as syncing the currently open chats list

  83. Sam goes to look at inbox

  84. Sam

    No, looks like inbox was just a way to speed up MAM sync

  85. Sam

    I'm hoping that someone is sycing the list of open chats, not history, but "these are the contacts and rooms we currently have in our 'recent chats'" list or whatever the client calls them.

  86. MattJ

    I'm not aware of any clients doing that currently, but I can confirm that "inbox" is generally associated with this feature because people don't want to sync only the tabs but also the unread status of them, etc.

  87. Trbl

    021-09-02 12:56:59.155029+02:00 [error] <0.7155.1>@ejabberd_hooks:safe_apply/4:240 Hook muc_process_iq crashed when running mod_mam:muc_process_iq/2: ** exception error: no case clause matching {error,{{bad_object,read_buckets}, "/var/lib/ejabberd/archive_msg.DAT"}}

  88. Trbl

    is that something i should open an issue for

  89. Arun


  90. Arun

    I require sample codes and procedures for Connecting react native with ejabberd Xmpp?

  91. moparisthebest

    Try https://medium.com/@connectycube/xmpp-real-time-chat-in-react-native-8d6d5d23dd47

  92. Trbl

    lol another guy wanting the same thing as reng

  93. moparisthebest

    Trbl, I assume it's the same person actually :)

  94. Trbl

    shh 😉