<?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[Flying Teapot - Medium]]></title>
        <description><![CDATA[Place where Im writing things - Medium]]></description>
        <link>https://medium.com/noma4i?source=rss----b695b53ed054---4</link>
        <image>
            <url>https://cdn-images-1.medium.com/proxy/1*TGH72Nnw24QL3iV9IOm4VA.png</url>
            <title>Flying Teapot - Medium</title>
            <link>https://medium.com/noma4i?source=rss----b695b53ed054---4</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Thu, 19 Nov 2026 10:46:56 GMT</lastBuildDate>
        <atom:link href="https://medium.com/feed/noma4i" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Curl for Websockets]]></title>
            <link>https://medium.com/noma4i/curl-for-websockets-e1954e38523e?source=rss----b695b53ed054---4</link>
            <guid isPermaLink="false">https://medium.com/p/e1954e38523e</guid>
            <category><![CDATA[websocket]]></category>
            <category><![CDATA[nginx]]></category>
            <dc:creator><![CDATA[Alexander Tsirel]]></dc:creator>
            <pubDate>Fri, 17 Mar 2017 02:14:01 GMT</pubDate>
            <atom:updated>2017-03-17T02:20:02.668Z</atom:updated>
            <cc:license>http://creativecommons.org/publicdomain/zero/1.0/</cc:license>
            <content:encoded><![CDATA[<p>I was investigating strange Websockets failure a while ago. This is easy if you have right tool for that. I believe that you can craft proper curl command for that. As for me I prefer to use something better.</p><p>I prefer yarn over npm so here we go:</p><pre>yarn global add wscat</pre><p>No I can connect to you WS right from my console:</p><pre>wscat -c ws://mywebsocket-server.com/faye -p 13</pre><h4>Fixing common issue</h4><p>If you experience error: Error: unexpected server response (400) it’s 99% your webserver/loadbalancer has wrong config. My option is <strong>Nginx</strong> so proper config for upstream should look like:</p><pre>location / {<br>  proxy_pass http://localhost:8080;<br>  proxy_http_version 1.1;<br>  proxy_set_header Upgrade $http_upgrade;<br>  proxy_set_header Connection &quot;upgrade&quot;;<br>  proxy_set_header Host $host;<br>}</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/810/1*9NkoUXe3Dp57-T9xL41DEQ.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e1954e38523e" width="1" height="1" alt=""><hr><p><a href="https://medium.com/noma4i/curl-for-websockets-e1954e38523e">Curl for Websockets</a> was originally published in <a href="https://medium.com/noma4i">Flying Teapot</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>