<?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 Mahesh Upasani on Medium]]></title>
        <description><![CDATA[Stories by Mahesh Upasani on Medium]]></description>
        <link>https://medium.com/@upasanimr30?source=rss-39873b6c64c5------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*dmbNkD5D-u45r44go_cf0g.png</url>
            <title>Stories by Mahesh Upasani on Medium</title>
            <link>https://medium.com/@upasanimr30?source=rss-39873b6c64c5------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Wed, 02 Dec 2026 10:22:35 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@upasanimr30/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[Use of IPv6 and IPv4 with gRPC]]></title>
            <link>https://medium.com/@upasanimr30/use-of-ipv6-and-ipv4-with-grpc-e68d1ee9aabe?source=rss-39873b6c64c5------2</link>
            <guid isPermaLink="false">https://medium.com/p/e68d1ee9aabe</guid>
            <dc:creator><![CDATA[Mahesh Upasani]]></dc:creator>
            <pubDate>Wed, 01 Mar 2023 13:23:56 GMT</pubDate>
            <atom:updated>2023-03-01T13:23:56.131Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>What is gRPC ?</strong></p><p>gRPC is a modern open source high performance Remote Procedure Call (RPC) framework that can run in any environment. It is also useful for building scalable and fast APIs.</p><p><strong>Use of gRPC ?</strong></p><ul><li>Works with different languages — gRPC is designed in a way that it can work with different languages i.e., we can write servers with Javascript and clients can be with different languages like Go,Java.</li><li>Develop quickly and scale — gRPC uses protocol buffers as the Interface Definition Language(IDL) for defining the both server side and client side. This definition will be in .proto file, it is a simple text file. This will result in saving a lot of time for development for a variety of use cases.</li><li>Streaming — It has bidirectional streaming. It allows client side &amp; server streaming simultaneously.</li><li>Cancel a call — Either the client or server can cancel the call at any time.</li></ul><p>If your network uses IPv6 then server url doesn’t support 0.0.0.0 or localhost as Host because both are the IPv4 host. It should be IPv6 host as [::].</p><p>Errors that you may receive while using IPv4 instead of IPv6 —</p><pre>Error: 14 UNAVAILABLE: failed to connect to all addresses<br>OR<br>No Address added out of total 1 resolved</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/665/1*W5XPBYNh47Hdlx1CxcxoYA.png" /><figcaption>gRPC error</figcaption></figure><p>Following are the examples while using it with IPv4 and IPv6 in NodeJS —</p><p><strong>IPv4</strong></p><pre>const GRPC_HOST = &#39;0.0.0.0&#39;; // &#39;localhost&#39;    =&gt; IPv4<br>const GRPC_PORT = 40041; // port no for gRPC server<br>const GRPC_URL = `${GRPC_HOST}:${GRPC_PORT}`;<br>const server = new grpc.Server();<br>server.addService(hello_proto.Greeter.service, {sayHello: sayHello});<br>server.bindAsync(GRPC_URL, grpc.ServerCredentials.createInsecure(), () =&gt; {<br>  server.start();<br>});</pre><p><strong>IPv6</strong></p><pre>const GRPC_HOST = &#39;[::]&#39;;                   //  =&gt; IPv6<br>const GRPC_PORT = 40041; // port no for gRPC server<br>const GRPC_URL = `${GRPC_HOST}:${GRPC_PORT}`;<br>const server = new grpc.Server();<br>server.addService(hello_proto.Greeter.service, {sayHello: sayHello});<br>server.bindAsync(GRPC_URL, grpc.ServerCredentials.createInsecure(), () =&gt; {<br>  server.start();<br>});</pre><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e68d1ee9aabe" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>