title: Exception when calling gRPC server from .Net Framework client
body: <p>I have a gRPC server implemented in .Net Core that I would like to contact with a console app running in .Net Framework.</p>
  <p>Here is a working repo of the issue:</p>
  <p><a href="https://github.com/q-bertsuit/grpc-framework-core-issue" rel="nofollow noreferrer">https://github.com/q-bertsuit/grpc-framework-core-issue</a></p>
  <p>The following .Net Core Client works fine:</p>
  <pre><code>class Program
  {
      static async Task Main(string[] args)
      {
          
          var input = new MyModel();
  
          var channel = GrpcChannel.ForAddress(&quot;https://localhost:5001&quot;);
          var client = new Test.TestClient(channel);
  
          var reply = await client.SetTestAsync(input);
  
          Console.ReadLine();
      }
  }
  </code></pre>
  <p>The following .Net Framework client throws an exception:</p>
  <pre><code>class Program
  {
      static void Main(string[] args)
      {
          Channel channel = new Channel(&quot;https://localhost:5001&quot;, ChannelCredentials.Insecure);
          
          var    client = new Test.TestClient(channel);
  
          MyModel request = new MyModel();
  
          var reply = client.SetTest(request);
  
          channel.ShutdownAsync().Wait();
  
  
          Console.ReadLine();
      }
  }
  </code></pre>
  <p>I get the following exception when sending the request:</p>
  <blockquote>
  <p>Grpc.Core.RpcException: 'Status(StatusCode=&quot;Unavailable&quot;, Detail=&quot;DNS
  resolution failed for service: https://localhost:5001&quot;,
  DebugException=&quot;Grpc.Core.Internal.CoreErrorDetailException:
  {&quot;created&quot;:&quot;@1600333768.055000000&quot;,&quot;description&quot;:&quot;Resolver transient
  failure&quot;,&quot;file&quot;:&quot;T:\src\github\grpc\workspace_csharp_ext_windows_x86\src\core\ext\filters\client_channel\resolving_lb_policy.cc&quot;,&quot;file_line&quot;:215,&quot;referenced_errors&quot;:[{&quot;created&quot;:&quot;@1600333768.055000000&quot;,&quot;description&quot;:&quot;DNS
  resolution failed for service:
  https://localhost:5001&quot;,&quot;file&quot;:&quot;T:\src\github\grpc\workspace_csharp_ext_windows_x86\src\core\ext\filters\client_channel\resolver\dns\c_ares\dns_resolver_ares.cc&quot;,&quot;file_line&quot;:378,&quot;grpc_status&quot;:14,&quot;referenced_errors&quot;:[{&quot;created&quot;:&quot;@1600333768.055000000&quot;,&quot;description&quot;:&quot;C-ares
  status is not ARES_SUCCESS qtype=A name=https://localhost:5001
  is_balancer=0: Could not contact DNS
  servers&quot;,&quot;file&quot;:&quot;T:\src\github\grpc\workspace_csharp_ext_windows_x86\src\core\ext\filters\client_channel\resolver\dns\c_ares\grpc_ares_wrapper.cc&quot;,&quot;file_line&quot;:287,&quot;referenced_errors&quot;:[{&quot;created&quot;:&quot;@1600333768.055000000&quot;,&quot;description&quot;:&quot;C-ares
  status is not ARES_SUCCESS qtype=AAAA name=https://localhost:5001
  is_balancer=0: Could not contact DNS
  servers&quot;,&quot;file&quot;:&quot;T:\src\github\grpc\workspace_csharp_ext_windows_x86\src\core\ext\filters\client_channel\resolver\dns\c_ares\grpc_ares_wrapper.cc&quot;,&quot;file_line&quot;:287}]}]}]}&quot;)'</p>
  </blockquote>
  <p>On the server I get this error:</p>
  <blockquote>
  <p>dbug: Microsoft.AspNetCore.Server.Kestrel[17]
  Connection id &quot;0HM2QU64LCR9J&quot; bad request data: &quot;Unrecognized HTTP version: 'HTTP/2.0'&quot;
  Microsoft.AspNetCore.Server.Kestrel.Core.BadHttpRequestException:
  Unrecognized HTTP version: 'HTTP/2.0'    at
  Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.HttpParser<code>1.RejectUnknownVersion(Byte* version, Int32 length)    at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.HttpParser</code>1.ParseRequestLine(TRequestHandler
  handler, Byte* data, Int32 length)    at
  Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.HttpParser<code>1.ParseRequestLine(TRequestHandler handler, ReadOnlySequence</code>1&amp; buffer, SequencePosition&amp; consumed,
  SequencePosition&amp; examined)    at
  Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.HttpParser<code>1.Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.IHttpParser&lt;TRequestHandler&gt;.ParseRequestLine(TRequestHandler handler, ReadOnlySequence</code>1&amp; buffer, SequencePosition&amp; consumed,
  SequencePosition&amp; examined)    at
  Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.Http1Connection.TakeStartLine(ReadOnlySequence<code>1&amp; buffer, SequencePosition&amp; consumed, SequencePosition&amp; examined)    at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.Http1Connection.ParseRequest(ReadOnlySequence</code>1&amp;
  buffer, SequencePosition&amp; consumed, SequencePosition&amp; examined)    at
  Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.Http1Connection.TryParseRequest(ReadResult
  result, Boolean&amp; endConnection)    at
  Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.HttpProtocol.ProcessRequests[TContext](IHttpApplication<code>1 application)    at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.HttpProtocol.ProcessRequestsAsync[TContext](IHttpApplication</code>1
  application) dbug: Microsoft.AspNetCore.Server.Kestrel[10]
  Connection id &quot;0HM2QU64LCR9J&quot; disconnecting. dbug: Microsoft.AspNetCore.Server.Kestrel[2]
  Connection id &quot;0HM2QU64LCR9J&quot; stopped. dbug: Microsoft.AspNetCore.Server.Kestrel.Transport.Sockets[6]
  Connection id &quot;0HM2QU64LCR9J&quot; received FIN. dbug: Microsoft.AspNetCore.Server.Kestrel.Transport.Sockets[7]
  Connection id &quot;0HM2QU64LCR9J&quot; sending FIN because: &quot;The Socket transport's send loop completed gracefully.&quot;</p>
  </blockquote>
  <p>Added Http/2 support in Kestrel as suggested, but still got an error:</p>
  <blockquote>
  <p>Grpc.Core.RpcException: 'Status(StatusCode=&quot;Unknown&quot;, Detail=&quot;Received
  http2 header with status: 307&quot;,
  DebugException=&quot;Grpc.Core.Internal.CoreErrorDetailException:
  {&quot;created&quot;:&quot;@1600342649.633000000&quot;,&quot;description&quot;:&quot;Received http2
  :status header with non-200 OK
  status&quot;,&quot;file&quot;:&quot;T:\src\github\grpc\workspace_csharp_ext_windows_x86\src\core\ext\filters\http\client\http_client_filter.cc&quot;,&quot;file_line&quot;:130,&quot;grpc_message&quot;:&quot;Received
  http2 header with status: 307&quot;,&quot;grpc_status&quot;:2,&quot;value&quot;:&quot;307&quot;}&quot;)'</p>
  </blockquote>