<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Mohit Jindal on Medium]]></title>
        <description><![CDATA[Stories by Mohit Jindal on Medium]]></description>
        <link>https://medium.com/@mohitjindal?source=rss-30d0362922f2------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*wpx__lbaybwm8snnW1TpPg.jpeg</url>
            <title>Stories by Mohit Jindal on Medium</title>
            <link>https://medium.com/@mohitjindal?source=rss-30d0362922f2------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Mon, 16 Nov 2026 09:16:20 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@mohitjindal/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Redis -A magical database that is a must have in your stack]]></title>
            <link>https://medium.com/oku-tech/redis-a-magical-database-that-is-a-must-have-in-your-stack-2892bc174e?source=rss-30d0362922f2------2</link>
            <guid isPermaLink="false">https://medium.com/p/2892bc174e</guid>
            <category><![CDATA[nodejs]]></category>
            <category><![CDATA[redis]]></category>
            <category><![CDATA[tech]]></category>
            <dc:creator><![CDATA[Mohit Jindal]]></dc:creator>
            <pubDate>Mon, 06 Jun 2016 07:05:16 GMT</pubDate>
            <atom:updated>2016-06-06T07:16:25.561Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>Redis -A magical database that is a must have in your stack</strong></p><p>In simple words, Redis (REmote Dictionary Server) is a data structure server. It is also most commonly know to be an in memory and persistent key value store. Persistence to disk implies that the data won’t disappear when you restart the system. It has several other huge advantages over other databases that could (Naat!) be used for similar use cases like MongoDB which is a disk-based document store, or Memcached which is not persistent.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*mPTMOFpmgCxJdVcU." /></figure><p>The development of Redis has been sponsored by Redis Labs since June 2015. Before that, it was sponsored by Pivotal Software and by<a href="https://en.wikipedia.org/wiki/VMware"> </a>VMware. More on that at the Redis <a href="https://en.wikipedia.org/wiki/Redis">wikipedia page</a>.</p><p>Below is one of the most important use cases where Redis is helping us.</p><p><strong>Caching User profiles</strong></p><p><strong>News Feed </strong>is the landing feature of the <a href="https://play.google.com/store/apps/details?id=in.oku.broex"><strong>BroEx App</strong></a>. It brings the pulse of the property market in the area of interest of a real estate broker using our app. Since there are multiple users in a particular area (city or sub area in a large city), similar content is served to several users with a very high QPS rate.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/320/1*8iNkEkR3UxjpZB0CrGnPAQ.jpeg" /><figcaption>BroEx App News Feed</figcaption></figure><p>Redis is the backbone for our ultra fast <strong>BroEx App News Feed</strong> architecture. A major part of the information delivered to the users in news feed (apart from the property listing attributes) is the broker profile information like their name, city, star rating, number of recognitions etc.</p><p>In our system, there are several attributes to a user profile which are stored in different databases (Postgres, Neo4j). If an access request was made for the same profile several times in a short interval, there would be tons of repetitive DB hits, thanks to Redis, we are able to avoid these in an efficient manner.</p><p><strong>Here is how it works :</strong></p><ul><li>Whenever a user profile is accessed via any request made to the server, after it is retrieved from different databases, our Redis manager code base caches the same for next 30 seconds.</li><li>Redis comes with a real handy optional durability mechanism where in we can specify the amount of time a particular object has to be kept in the memory. Since user profile is something that could change very frequently, we store it just for 30 seconds.</li><li>All the subsequent profile accesses for the particular profile are served by Redis for the next 30 seconds and it gets reset when a fresh request is made again for the same profile after the information stored in Redis has expired.</li></ul><p>Redis has become an obvious choice for us in course of building a highly scalable data store shared by multiple processes, multiple applications, and multiple servers. There are several other important use cases in our system where we use it :</p><ul><li><strong>Session caches</strong></li><li><strong>XMPP presence handling</strong></li><li><strong>Job queues</strong></li><li><strong>Lead randomisation</strong></li></ul><p>Read more on these use cases in our upcoming blogs. And if you are a software developer who likes to build scalable systems and wants to work on exciting problems with us,<a href="http://broex.in/career"> <strong>drop us a note, we’re hiring!</strong></a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2892bc174e" width="1" height="1" alt=""><hr><p><a href="https://medium.com/oku-tech/redis-a-magical-database-that-is-a-must-have-in-your-stack-2892bc174e">Redis -A magical database that is a must have in your stack</a> was originally published in <a href="https://medium.com/oku-tech">FastFox Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Answering the million dollar question: Why Node.js?]]></title>
            <link>https://medium.com/oku-tech/answering-the-million-dollar-question-why-node-js-b417fab93d8e?source=rss-30d0362922f2------2</link>
            <guid isPermaLink="false">https://medium.com/p/b417fab93d8e</guid>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[nodejs]]></category>
            <category><![CDATA[tech]]></category>
            <dc:creator><![CDATA[Mohit Jindal]]></dc:creator>
            <pubDate>Sun, 22 May 2016 16:38:44 GMT</pubDate>
            <atom:updated>2016-05-23T06:31:28.967Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>Answering the million dollar question: Why Node.js?</strong></p><p>Node.js was originally written in 2009 by Ryan Dahl. He was inspired to create Node.js after seeing a file upload progress bar on Flickr. The browser did not know how much of the file had been uploaded and had to query the Web server. Dahl desired an easier way, came the Node.js. More on that at the Node.js <a href="https://en.wikipedia.org/wiki/Node.js">wikipedia</a> page.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*P6cyY15a9gyXu7NW." /></figure><p>Below is what we at Okutech believe are the key advantages of using Node.js.</p><p><strong>Performance</strong></p><p>Node.js uses events heavily and it is also one of the reasons why Node.js is pretty fast when compared to other similar technologies. It operates on a single thread, using non-blocking I/O calls, allowing it to support tens of thousands of concurrent connections without incurring the cost of thread context switching. Imagine a situation where the requests made to a web server had a response time of 100 ms. Out of those 100 ms, 90 ms were required to fetch the data from a database and the rest 10 ms was required for post fetch computation. Instead of waiting for the I/O call (data fetch from db), Node.js utilises that time to serve other requests and it responds to the initial request whenever the data is ready for post fetch processing. Node.js is well suited for applications that have a lot of concurrent connections and each request only needs very few CPU cycles, because the event loop (with all the other clients) is blocked during execution of a function. Read more on how Node.js does that<a href="http://www.tutorialspoint.com/nodejs/nodejs_event_loop.htm"> here</a> and more on concurrency vs. parallelism<a href="http://bytearcher.com/articles/parallel-vs-concurrent/"> here</a>.</p><p><strong>Common back-end and front-end code</strong></p><p>Another rather important advantage of having Node.js in a tech stack is that it allows you to use the same language on the client and on the server. You can write libraries and APIs for your back-end code base and seamlessly use the same for your front-end. This enables faster development cycles when compared to traditional languages like Java or C++.</p><p><strong>Common back-end and front-end developers</strong></p><p>Hiring becomes easy when you don’t have to get people with entirely different set of skill sets ({HTML CSS JS} and {Java}). Since Node.js is essentially JavaScript implemented on back-end, it is quite easy for someone with some experience in JavaScript to pick up Node.js</p><p><strong>Strong Developer community</strong></p><p>The Node.js community is large, inclusive, and excited to enable as many users to contribute in whatever way they can. It currently has well over 300 contributors actively working on different areas of the Node.js project. There are several libraries already available that make things even easier and the list is only growing.<a href="https://nodejs.org/en/get-involved/"> Here</a> is how you can get involved too.</p><p><strong>Conclusion</strong></p><p>It won’t be an exaggeration to say that JavaScript has made a real dent in the computer science community and has dramatically changed the way web development is being done today. The things that we can do on the web nowadays with JavaScript running on the server, as well as in the browser, were hard to imagine just a few years ago.</p><p>If you are a Node.js developer and want to work on exciting problems with us,<a href="http://broex.in/career"> <strong>drop us a note, we’re hiring!</strong></a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b417fab93d8e" width="1" height="1" alt=""><hr><p><a href="https://medium.com/oku-tech/answering-the-million-dollar-question-why-node-js-b417fab93d8e">Answering the million dollar question: Why Node.js?</a> was originally published in <a href="https://medium.com/oku-tech">FastFox Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Using Neo4j to build a user network graph]]></title>
            <link>https://medium.com/oku-tech/using-neo4j-to-build-a-user-network-graph-beb0c2bc96ab?source=rss-30d0362922f2------2</link>
            <guid isPermaLink="false">https://medium.com/p/beb0c2bc96ab</guid>
            <category><![CDATA[tech]]></category>
            <category><![CDATA[graph]]></category>
            <category><![CDATA[neo4j]]></category>
            <dc:creator><![CDATA[Mohit Jindal]]></dc:creator>
            <pubDate>Sun, 15 May 2016 16:20:54 GMT</pubDate>
            <atom:updated>2016-05-15T16:20:54.882Z</atom:updated>
            <content:encoded><![CDATA[<p>In a business-to-business setting, trust commands a huge premium. Creating a process driven system that helps users identify trustworthy business partners is a key issue that needs to be solved in any B2B market place. Alibaba on its B2B marketplace provides a trust seal service which businesses actually buy to look “trusted” on the portal. Indiamart has the same approach. In real estate’s broker to broker market it was no different.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*bGKCk5R5i99flWkv.jpg" /></figure><p>Real estate portals and mobile apps have revolutionized the traditional business model which has been in practice for decades. It has given the much required adrenaline push to the industry by connecting owners, buyers, tenants ,real estate agents and brokers.</p><p>However, even with the inclusion of multiple technology solutions genuineness of the brokers has remained an unsolved problem in the real estate industry. Identifying a fake listing is not only attributed to the properties of the listing such as price, locality and amenities but also to the credibility of the person who posted it. We at BroEx take this problem very seriously and have come up with our own magical algorithm to solve this. We have put our best efforts towards creating a clean broker to broker network and have used technology as a tool to identify the genuineness of the brokers in our network.</p><p><strong>So how is BroEx, by using smart technologies, taking care of this major issue?</strong></p><p>Once a user installs the app, we request for their contact information that includes their phone book contacts. This helps us in creating a relational graph of “who knows who” on our platform. At the same time, it also benefits brokers to know their first degree and second degree connections on Broex.</p><p>For every contact that is stored in user’s phone book, we create a node in the already existing relational map. These nodes connect to all the other nodes that are there in user’s contact list. With increasing number of brokers joining BroEx daily, the 1,00,000+ strong broker network keeps learning more and more about the strength of connections between all the broker nodes. As a result, the system becomes smarter with every new broker joining the network.</p><p><strong>How this very simple magic works?</strong></p><p>Let’s assume a new user Mr. X joins BroEx. The user connection intelligence graph that already has information of 85,000+ brokers in India is able to answer to the following questions:</p><ul><li>How many brokers know Mr. X (we call this #Recognitions)</li><li>How many brokers does Mr. X know (we call this #Contacts)</li><li>By what degree are Mr. X and Mr. Y connected (we call this #Degree of Connection)</li></ul><p>As the number of recognitions, contacts and higher number of 1st and 2nd degree connection of Mr. X increase he becomes a more reliable broker on the platform. The system regularly scans for unreliable brokers and locks their profiles in case it finds the profile suspicious.</p><p><strong>Which technology we are embracing for this purpose and why?</strong></p><p><strong>Neo4j</strong> is a graph database management system developed by Neo Technology, Inc. Described by its developers as an ACID-compliant transactional database with native graph storage and processing.</p><p>Neo4j helps us to ascertain that each piece of data in the graph has an explicit connection to everything it’s related to. This means the database can ignore anything that’s not connected, rather than having to trawl through all of the data in order to determine what is connected. This results in unparalleled speed and scale.</p><p>Relationships are first-class citizens of the graph data model, unlike other database management systems, which require us to infer connections between entities using special properties such as foreign keys, or out-of-band processing like map-reduce. By assembling the simple abstractions of nodes and relationships into connected structures, graph databases enable us to build sophisticated models that helps us to do the broker to broker connection magic.</p><p>We use relational database (Postgres) for storing most of our structured data. Postgres could have been our first choice of database for storing relationship between users on BroEx platform. Relational databases are good at storing highly structured data with predetermined columns of a table. So it becomes difficult to maintain sparse adjacency matrix in a relational database. Also queries will not be optimized for queries like finding relations, degree of connection etc.</p><p>Hence relational database was out of question. We started exploring graph databases which are storage system that provides index-free adjacency. Graph databases contains for every element direct link to its adjacent elements. Hence we can easily query relations, degree of connections etc.</p><p>There are various graph databases available. We chose neo4j because it has largest and most active community support. Also query language of neo4j is easier to understand and write than other graph databases we considered.</p><p>Keep following this space to follow our regular product updates. And if you’re interested solving such problems with us, <a href="http://broex.in/career"><strong>drop us a note, we’re hiring!</strong></a></p><p><em>Originally published at </em><a href="http://blog.broex.in/technology"><em>blog.broex.in/technology</em></a><em>. Find the original post </em><a href="http://blog.broex.in/phonegraph-neo4j/"><em>here</em></a><em>.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=beb0c2bc96ab" width="1" height="1" alt=""><hr><p><a href="https://medium.com/oku-tech/using-neo4j-to-build-a-user-network-graph-beb0c2bc96ab">Using Neo4j to build a user network graph</a> was originally published in <a href="https://medium.com/oku-tech">FastFox Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Implementing a quick search module for your MVP]]></title>
            <link>https://medium.com/oku-tech/implementing-a-quick-search-module-for-your-mvp-fe63a52bba21?source=rss-30d0362922f2------2</link>
            <guid isPermaLink="false">https://medium.com/p/fe63a52bba21</guid>
            <category><![CDATA[nlp]]></category>
            <category><![CDATA[nodejs]]></category>
            <category><![CDATA[solr]]></category>
            <dc:creator><![CDATA[Mohit Jindal]]></dc:creator>
            <pubDate>Sun, 15 May 2016 15:23:26 GMT</pubDate>
            <atom:updated>2016-05-15T15:23:26.864Z</atom:updated>
            <content:encoded><![CDATA[<p>A standard way of prioritizing development tasks in a technology product (especially in the initial few weeks) is to go with the Minimum Viable Product (MVP) approach. MVP is a product that has only the core features; you can find more information<a href="https://en.wikipedia.org/wiki/Minimum_viable_product"> here</a>.</p><p>A search module/engine is something which is ever evolving; even for a tech giant like Google. Aiming at something that matches absolutely with what you have in your vision could harm your product launch time-lines. Having said that, if your product is meant to have search as a core feature, it becomes imperative to have something developed quickly that could be shipped without compromising with your MVP time-lines. Read below to know how we started and went about developing a NLP-based search module for BroEx in the initial days.</p><p><strong>BroEx property search use case</strong></p><p>100,000+ brokers across India post around 1000+ property listings per day on our platform. The property search feature helps them to hunt for residential and commercial inventories &amp; requirements based on filters like area, #BHK, Price, Vaastu, Facing, Parking, Power Backup, etc. It also helps brokers to get closest results for their intended searches and showcase most relevant properties to their clients, which in turn helps them to close more deals successfully.</p><p>Before we dive deep, let’s talk about the technology at core for this module:</p><ul><li>We use<a href="https://en.wikipedia.org/wiki/Apache_Solr"> Solr</a> as the data store where every document represents a property listing. Solr is the popular, blazing-fast, open source enterprise search platform built on Apache Lucene. (More on how our search module has matured now with Solr geospatial magic in upcoming blogs)</li><li>We use<a href="https://en.wikipedia.org/wiki/Node.js"> </a>Node.<a href="https://en.wikipedia.org/wiki/Node.js">js</a> as our primary programming language in the back-end. Node.js is a JavaScript runtime built on Chrome’s V8 JavaScript engine. It uses an event-driven, non-blocking I/O model that makes it lightweight and efficient.</li></ul><p><strong>How it works:</strong></p><p>In the below diagram you can see how this magic works:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*hZHjYsIM43XVVlo3.jpg" /><figcaption>Property search flow</figcaption></figure><ul><li>Users add their listings on BroEx with details like Residential/Commercial, Sale/Lease, Location, etc.</li><li>This information is now processed by a tokenizer code written in Node.js<br> # Aggregated tokens for a listing based on the provided attributes are created<br> # Every attribute goes through separate processing mechanism<br> # Stop-words are removed<br> # Processing based on representative keywords<br> # Bigrams and trigrams for location attribute are considered<br> # Additional tags are added to the list based on the nearby area knowledge base</li><li>The information along with the tokens are pushed to Solr</li><li>Users search for listings using different keywords like 3bhk in sec 45 / north facing 3bhk in sec 45 with filters</li><li>This information is then passed to Solr via client APIs written in Node.js</li><li>Information is processed in Solr along with search tokens from keywords and results are passed to users via client APIs written in Node.js</li></ul><p>Although this system is not super smart (wait for the next release) but it did serve our purpose of having a working search module effectively. While we are well on our way to power BroEx with a revamped search back-end with geospatial intelligence and other bells and whistles, this module shall continue to support search feature in our app for cities we do not intend to get geospatial data for. (Just kidding, of course we will power all the cities with new search, we just like to solve the problems in parts).</p><p>With geospatial intelligence under the covers, BroEx will be able to serve more relevant search results and listings recommendations in the near future. Keep following this space to follow our regular product updates. And if you’re interested solving such problems with us, <a href="http://broex.in/career"><strong>drop us a note, we’re hiring!</strong></a></p><p><em>Originally published at </em><a href="http://blog.broex.in/technology"><em>blog.broex.in/technology</em></a><em>. Find the original post </em><a href="http://blog.broex.in/implementing-a-quick-search-module-for-your-mvp/"><em>here</em></a><em>.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=fe63a52bba21" width="1" height="1" alt=""><hr><p><a href="https://medium.com/oku-tech/implementing-a-quick-search-module-for-your-mvp-fe63a52bba21">Implementing a quick search module for your MVP</a> was originally published in <a href="https://medium.com/oku-tech">FastFox Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Using XMPP to Build a Cutting-edge Chat Module]]></title>
            <link>https://medium.com/oku-tech/using-xmpp-to-build-a-cutting-edge-chat-module-c8bb67343d7d?source=rss-30d0362922f2------2</link>
            <guid isPermaLink="false">https://medium.com/p/c8bb67343d7d</guid>
            <category><![CDATA[ejabberd]]></category>
            <category><![CDATA[xmpp]]></category>
            <category><![CDATA[erlang]]></category>
            <dc:creator><![CDATA[Mohit Jindal]]></dc:creator>
            <pubDate>Tue, 26 Apr 2016 14:11:13 GMT</pubDate>
            <atom:updated>2016-06-06T17:31:31.043Z</atom:updated>
            <content:encoded><![CDATA[<p>Mobile apps have truly revolutionized the way people interact with each other, with any network or different businesses. A little investment in a smartphone, opens up the gateway to the world of mobile apps. Likewise, now there are many mobile apps for Real Estate brokers and BroEx is leading the pack.</p><p>Our product BroEx is being used by 100,000+ brokers across the country. It helps them find relevant brokers on our platform, get connected, share inventories &amp; requirements, and close deals successfully. However, after a deep dive into the user habits on our app, we analyzed that brokers are using the app to find other brokers but were communicating with them on WhatsApp. We wanted to extend the platform such that we can reliably handle the communication within the application itself. A good chat module is one of the most important feature in any social or professional network app and we needed the same for BroEx to have. As we looked around, we realized that while most of the popular apps have a chat feature, but they struggle to make it stable and reliable.</p><p>While the chat feature seems trivial from users’ perspective, it came with several daunting challenges and use cases when we set on route for implementing the same. Read more on a special use case below but first, let’s get started with the keywords and technology at core.</p><p><strong>XMPP and Erlang powered Ejabberd</strong></p><p><a href="https://en.wikipedia.org/wiki/XMPP">Extensible Messaging and Presence Protocol</a> (XMPP) is a communications protocol for message-oriented middleware based on XML (Extensible Markup Language). It enables the near-real-time exchange of structured yet extensible data between any two or more network entities.</p><p><a href="https://en.wikipedia.org/wiki/Erlang_%28programming_language%29">Erlang</a> is a programming language used to build massively scalable soft real-time systems with requirements on high availability. Some of its uses are in telecoms, banking, e-commerce, computer telephony and instant messaging. Erlang’s runtime system has built-in support for concurrency, distribution and fault tolerance.</p><p><a href="https://en.wikipedia.org/wiki/Ejabberd">Ejabberd</a> is an XMPP application server, written mainly in the Erlang programming language. It can run under several Unix-like operating systems such as Mac OS X, GNU/Linux, FreeBSD, NetBSD, OpenBSD and OpenSolaris.</p><p>There are several options available with respect to XMPP server software but Ejabberd clearly stood out above the rest for our use cases. You can find a detailed comparison on the XMPP server software available by <a href="https://en.wikipedia.org/wiki/Comparison_of_XMPP_server_software">clicking here</a>.</p><p>Let’s trace a series of messages flowing back and forth. In the diagram below you can see what happens in the background when Alice sends a message to Bob.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QqyhlYA2uCZL3lBL16dD2g.jpeg" /><figcaption>Single message flow</figcaption></figure><p>Looks pretty simple eh? Well, isn’t everything that is designed simple just awesome? <em>Everything should be made as simple as possible, but no simpler ~ Albert Einstein</em></p><p>This looks easy and seamless but it happens only when the users are online. Twist and complete reliance on technology comes in when the receiver of the message is offline, and the message had to be delivered as soon as they came online.</p><p><strong>Let’s talk about a major challenge that we faced with handling offline messages’ delivery</strong></p><p><em>Have you ever used Tinder?</em> When you tap on a notification for a message from your match, there are good chances that the message would not appear in the chat thread for at least a few seconds (this bug is present as of today. Isn’t that heart breaking?). This is a typical problem with many other popular chat applications as well, where the client app receives the notification from GCM/APN before a connection was established with the chat server and offline messages were retrieved. Well, here is how we have solved it. In the below diagram Alice has sent a message to Bob, but he is offline.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cgHmChUTDg5ASGc_3F_UZg.jpeg" /><figcaption>Offline message flow</figcaption></figure><p>The magic happens when BroEx app at Bob’s phone makes a stealth mode (Bob is not treated to be online) connection with XMPP and requests for all of their offline messages. XMPP server calculates and sends all the pending offline messages to Bob. The BroEx app at Bob’s phone then sends “received” acknowledgements to the server, which is then sent to Alice.</p><p>Now, when Bob would tap on the push notification he received from APN/GCM, he would see all the offline messages already present waiting to be read.</p><p>We are not alone in doing this! <a href="http://highscalability.com/blog/2014/2/26/the-whatsapp-architecture-facebook-bought-for-19-billion.html">Check how</a> WhatsApp used Erlang and XMPP to reach a multi-billion-dollar valuation. XMPP for the Win!</p><p>If you are a software engineer who likes to build scalable systems and wants to work on exciting problems with us,<a href="http://broex.in/career"> <strong>drop us a note, we’re hiring!</strong></a></p><p><em>Originally published at </em><a href="http://blog.broex.in/technology"><em>blog.broex.in/technology</em></a><em>. Find the original post </em><a href="http://blog.broex.in/using-xmpp-to-build-a-cutting-edge-chat-module/"><em>here</em></a><em>.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c8bb67343d7d" width="1" height="1" alt=""><hr><p><a href="https://medium.com/oku-tech/using-xmpp-to-build-a-cutting-edge-chat-module-c8bb67343d7d">Using XMPP to Build a Cutting-edge Chat Module</a> was originally published in <a href="https://medium.com/oku-tech">FastFox Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>