{"action":"opened","issue":{"url":"https://api.github.com/repos/Netflix/ribbon/issues/196","labels_url":"https://api.github.com/repos/Netflix/ribbon/issues/196/labels{/name}","comments_url":"https://api.github.com/repos/Netflix/ribbon/issues/196/comments","events_url":"https://api.github.com/repos/Netflix/ribbon/issues/196/events","html_url":"https://github.com/Netflix/ribbon/issues/196","id":56118399,"number":196,"title":"SSL issue with Ribbon (via Feign)","user":{"login":"craigivy","id":764721,"avatar_url":"https://avatars.githubusercontent.com/u/764721?v=3","gravatar_id":"","url":"https://api.github.com/users/craigivy","html_url":"https://github.com/craigivy","followers_url":"https://api.github.com/users/craigivy/followers","following_url":"https://api.github.com/users/craigivy/following{/other_user}","gists_url":"https://api.github.com/users/craigivy/gists{/gist_id}","starred_url":"https://api.github.com/users/craigivy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/craigivy/subscriptions","organizations_url":"https://api.github.com/users/craigivy/orgs","repos_url":"https://api.github.com/users/craigivy/repos","events_url":"https://api.github.com/users/craigivy/events{/privacy}","received_events_url":"https://api.github.com/users/craigivy/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-01-31T08:48:48Z","updated_at":"2015-01-31T08:48:48Z","closed_at":null,"body":"I'm in the process of trying to get Feign with Ribbon to call my service using SSL.  It continues to call it in a non secure manner even when the configuration seems right.\r\n\r\nMy client interface:\r\n    @RequestLine(\"GET /remoteFiles\")\r\n    public PagedResources<RemoteFile> getRemoteFiles();\r\n\r\nCalling code:\r\n        RemoteFileClient rfc = Feign.builder()\r\n                .client(new RibbonClient())\r\n                .target(RemoteFileClient.class, \"https://remotefilesvc\");\r\n        return rfc.getRemoteFiles();\r\n\r\nAs the code executes I notice:\r\nThe method RibonClient.execute(....) removes the schema with this code:\r\nURI uriWithoutSchemeAndPort = URI.create(request.url().replace(asUri.getScheme() + \"://\" + asUri.getHost(), \"\"));\r\n\r\nBut when it reconstructs the URI it no longer has the schema because it has been stripped by the code above.  Notice the reconstruction in LoadBalancerContext.reconsturctURIwithServer(...) its using the schema for the original URI which in this particular case will always be null and default back to HTTP.  code not returning HTTPS is String scheme = original.getScheme();.\r\n\r\nThanks in advance, Craig\r\n\r\n"}}