{"action":"created","issue":{"url":"https://api.github.com/repos/zalando/riptide/issues/407","repository_url":"https://api.github.com/repos/zalando/riptide","labels_url":"https://api.github.com/repos/zalando/riptide/issues/407/labels{/name}","comments_url":"https://api.github.com/repos/zalando/riptide/issues/407/comments","events_url":"https://api.github.com/repos/zalando/riptide/issues/407/events","html_url":"https://github.com/zalando/riptide/issues/407","id":336539994,"node_id":"MDU6SXNzdWUzMzY1Mzk5OTQ=","number":407,"title":"java.lang.BootstrapMethodError: call site initialization exception starting from version 2.8.0","user":{"login":"mazenmelouk","id":3579734,"node_id":"MDQ6VXNlcjM1Nzk3MzQ=","avatar_url":"https://avatars0.githubusercontent.com/u/3579734?v=4","gravatar_id":"","url":"https://api.github.com/users/mazenmelouk","html_url":"https://github.com/mazenmelouk","followers_url":"https://api.github.com/users/mazenmelouk/followers","following_url":"https://api.github.com/users/mazenmelouk/following{/other_user}","gists_url":"https://api.github.com/users/mazenmelouk/gists{/gist_id}","starred_url":"https://api.github.com/users/mazenmelouk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mazenmelouk/subscriptions","organizations_url":"https://api.github.com/users/mazenmelouk/orgs","repos_url":"https://api.github.com/users/mazenmelouk/repos","events_url":"https://api.github.com/users/mazenmelouk/events{/privacy}","received_events_url":"https://api.github.com/users/mazenmelouk/received_events","type":"User","site_admin":false},"labels":[{"id":196842392,"node_id":"MDU6TGFiZWwxOTY4NDIzOTI=","url":"https://api.github.com/repos/zalando/riptide/labels/Bug","name":"Bug","color":"b60205","default":false},{"id":196842395,"node_id":"MDU6TGFiZWwxOTY4NDIzOTU=","url":"https://api.github.com/repos/zalando/riptide/labels/Help%20Wanted","name":"Help Wanted","color":"0e8a16","default":false}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-06-28T09:18:51Z","updated_at":"2018-07-04T23:21:36Z","closed_at":"2018-07-04T23:21:36Z","author_association":"NONE","body":"<!--- Provide a general summary of the issue in the Title above -->\r\nStarting from version 1.8.0 I get 'BootstrapMethodError' exception on calling `getForObject`.\r\nHere is a [link](https://stackoverflow.com/questions/33929304/weird-exception-invalid-receiver-type-class-java-lang-object-not-a-subtype-of) that describes the exception.\r\nAlso I put the stacktrace in the description\r\n\r\n## Description\r\n<!--- Provide a more detailed introduction to the issue itself, and why you consider it to be a bug -->\r\n```java\r\n java.lang.BootstrapMethodError: call site initialization exception\r\n #011at java.lang.invoke.CallSite.makeSite(CallSite.java:341) ~[na:1.8.0_162]\r\n #011at java.lang.invoke.MethodHandleNatives.linkCallSiteImpl(MethodHandleNatives.java:307) ~[na:1.8.0_162]\r\n #011at java.lang.invoke.MethodHandleNatives.linkCallSite(MethodHandleNatives.java:297) ~[na:1.8.0_162]\r\n #011at org.zalando.logbook.httpclient.LocalRequest.getContentType(LocalRequest.java:109) ~[logbook-httpclient-1.8.1.jar!/:na]\r\n #011at org.zalando.logbook.Conditions.lambda$contentType$3(Conditions.java:54) ~[logbook-core-1.8.1.jar!/:na]\r\n #011at org.zalando.logbook.BodyReplacers.lambda$replaceBody$0(BodyReplacers.java:48) ~[logbook-core-1.8.1.jar!/:na]\r\n #011at org.zalando.logbook.BodyReplacer.lambda$null$0(BodyReplacer.java:21) ~[logbook-api-1.8.1.jar!/:na]\r\n #011at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193) ~[na:1.8.0_162]\r\n #011at java.util.Spliterators$ArraySpliterator.tryAdvance(Spliterators.java:958) ~[na:1.8.0_162]\r\n #011at java.util.stream.ReferencePipeline.forEachWithCancel(ReferencePipeline.java:126) ~[na:1.8.0_162]\r\n #011at java.util.stream.AbstractPipeline.copyIntoWithCancel(AbstractPipeline.java:498) ~[na:1.8.0_162]\r\n #011at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:485) ~[na:1.8.0_162]\r\n #011at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471) ~[na:1.8.0_162]\r\n #011at java.util.stream.FindOps$FindOp.evaluateSequential(FindOps.java:152) ~[na:1.8.0_162]\r\n #011at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234) ~[na:1.8.0_162]\r\n #011at java.util.stream.ReferencePipeline.findFirst(ReferencePipeline.java:464) ~[na:1.8.0_162]\r\n #011at org.zalando.logbook.BodyReplacer.lambda$compound$1(BodyReplacer.java:23) ~[logbook-api-1.8.1.jar!/:na]\r\n #011at org.zalando.logbook.RawRequestFilters.lambda$replaceBody$0(RawRequestFilters.java:24) ~[logbook-core-1.8.1.jar!/:na]\r\n #011at org.zalando.logbook.DefaultLogbook.write(DefaultLogbook.java:44) ~[logbook-core-1.8.1.jar!/:na]\r\n #011at org.zalando.logbook.httpclient.LogbookHttpRequestInterceptor.process(LogbookHttpRequestInterceptor.java:29) ~[logbook-httpclient-1.8.1.jar!/:na]\r\n #011at org.apache.http.protocol.ImmutableHttpProcessor.process(ImmutableHttpProcessor.java:133) ~[httpcore-4.4.6.jar!/:4.4.6]\r\n #011at org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:183) ~[httpclient-4.5.3.jar!/:4.5.3]\r\n #011at org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:89) ~[httpclient-4.5.3.jar!/:4.5.3]\r\n #011at org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java:111) ~[httpclient-4.5.3.jar!/:4.5.3]\r\n #011at org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:185) ~[httpclient-4.5.3.jar!/:4.5.3]\r\n #011at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:83) ~[httpclient-4.5.3.jar!/:4.5.3]\r\n #011at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:56) ~[httpclient-4.5.3.jar!/:4.5.3]\r\n #011at org.springframework.http.client.HttpComponentsClientHttpRequest.executeInternal(HttpComponentsClientHttpRequest.java:89) ~[spring-web-4.3.11.RELEASE.jar!/:4.3.11.RELEASE]\r\n #011at org.springframework.http.client.AbstractBufferingClientHttpRequest.executeInternal(AbstractBufferingClientHttpRequest.java:48) ~[spring-web-4.3.11.RELEASE.jar!/:4.3.11.RELEASE]\r\n #011at org.springframework.http.client.AbstractClientHttpRequest.execute(AbstractClientHttpRequest.java:53) ~[spring-web-4.3.11.RELEASE.jar!/:4.3.11.RELEASE]\r\n #011at org.springframework.http.client.InterceptingClientHttpRequest$InterceptingRequestExecution.execute(InterceptingClientHttpRequest.java:99) ~[spring-web-4.3.11.RELEASE.jar!/:4.3.11.RELEASE]\r\n #011at org.zalando.riptide.spring.PluginInterceptors$Adapter.lambda$intercept$0(PluginInterceptors.java:49) ~[riptide-spring-boot-starter-2.8.0.jar!/:na]\r\n #011at org.zalando.riptide.OriginalStackTracePlugin.lambda$prepare$1(OriginalStackTracePlugin.java:27) ~[riptide-core-2.8.0.jar!/:na]\r\n #011at org.zalando.riptide.spring.PluginInterceptors$Adapter.intercept(PluginInterceptors.java:61) ~[riptide-spring-boot-starter-2.8.0.jar!/:na]\r\n #011at org.springframework.http.client.InterceptingClientHttpRequest$InterceptingRequestExecution.execute(InterceptingClientHttpRequest.java:86) ~[spring-web-4.3.11.RELEASE.jar!/:4.3.11.RELEASE]\r\n #011at org.springframework.http.client.InterceptingClientHttpRequest.executeInternal(InterceptingClientHttpRequest.java:70) ~[spring-web-4.3.11.RELEASE.jar!/:4.3.11.RELEASE]\r\n #011at org.springframework.http.client.AbstractBufferingClientHttpRequest.executeInternal(AbstractBufferingClientHttpRequest.java:48) ~[spring-web-4.3.11.RELEASE.jar!/:4.3.11.RELEASE]\r\n #011at org.springframework.http.client.AbstractClientHttpRequest.execute(AbstractClientHttpRequest.java:53) ~[spring-web-4.3.11.RELEASE.jar!/:4.3.11.RELEASE]\r\n #011at org.springframework.web.client.RestTemplate.doExecute(RestTemplate.java:652) ~[spring-web-4.3.11.RELEASE.jar!/:4.3.11.RELEASE]\r\n #011at org.springframework.web.client.RestTemplate.execute(RestTemplate.java:613) ~[spring-web-4.3.11.RELEASE.jar!/:4.3.11.RELEASE]\r\n #011at org.springframework.web.client.RestTemplate.getForObject(RestTemplate.java:287) ~[spring-web-4.3.11.RELEASE.jar!/:4.3.11.RELEASE]\r\n```\r\n\r\n## Expected Behavior\r\nThe exception should not be thrown and the call executed should be logged\r\n\r\n## Actual Behavior\r\nThe call fails \r\n\r\n## Steps to Reproduce\r\n<!--- Provide a link to a live example, or an unambiguous set of steps to -->\r\n<!--- reproduce this bug. Include code to reproduce, if relevant -->\r\n```java\r\nrestTemplate.getForEntity(some_url,somePojo[].class).getBody()\r\n```\r\n\r\n## Context\r\njust upgrading from an old version, for a project that does \r\n\r\n## Your Environment\r\nJava8 spring-boot 1.5.7\r\n* Version used: 2.8.1/2.8.0(failed) 2.7.1 (succeed) \r\n\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/zalando/riptide/issues/comments/402571020","html_url":"https://github.com/zalando/riptide/issues/407#issuecomment-402571020","issue_url":"https://api.github.com/repos/zalando/riptide/issues/407","id":402571020,"node_id":"MDEyOklzc3VlQ29tbWVudDQwMjU3MTAyMA==","user":{"login":"whiskeysierra","id":429981,"node_id":"MDQ6VXNlcjQyOTk4MQ==","avatar_url":"https://avatars2.githubusercontent.com/u/429981?v=4","gravatar_id":"","url":"https://api.github.com/users/whiskeysierra","html_url":"https://github.com/whiskeysierra","followers_url":"https://api.github.com/users/whiskeysierra/followers","following_url":"https://api.github.com/users/whiskeysierra/following{/other_user}","gists_url":"https://api.github.com/users/whiskeysierra/gists{/gist_id}","starred_url":"https://api.github.com/users/whiskeysierra/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/whiskeysierra/subscriptions","organizations_url":"https://api.github.com/users/whiskeysierra/orgs","repos_url":"https://api.github.com/users/whiskeysierra/repos","events_url":"https://api.github.com/users/whiskeysierra/events{/privacy}","received_events_url":"https://api.github.com/users/whiskeysierra/received_events","type":"User","site_admin":false},"created_at":"2018-07-04T23:21:36Z","updated_at":"2018-07-04T23:21:36Z","author_association":"MEMBER","body":"IntelliJ actually produces a root cause:\r\n\r\n```\r\nCaused by: java.lang.invoke.LambdaConversionException: Invalid receiver type interface org.apache.http.Header; not a subtype of implementation type interface org.apache.http.NameValuePair\r\n\tat java.lang.invoke.AbstractValidatingLambdaMetafactory.validateMetafactoryArgs(AbstractValidatingLambdaMetafactory.java:233)\r\n\tat java.lang.invoke.LambdaMetafactory.metafactory(LambdaMetafactory.java:303)\r\n\tat java.lang.invoke.CallSite.makeSite(CallSite.java:302)\r\n\t... 80 more\r\n```\r\n\r\nLooks like we are running into a dependency issue with Apache Http Client. See [release notes](https://archive.apache.org/dist/httpcomponents/httpcore/RELEASE_NOTES.txt) for version 4.4.9:\r\n\r\n> * HTTPCORE-499: Make interface Header extend NameValuePair.\r\n  Contributed by Gary Gregory <ggregory at apache.org>\r\n\r\nYou can workaround this by specifying a concrete http client/core version until we release riptide, logbook and tracer with a matching version for http core and client:\r\n\r\n```xml\r\n<dependency>\r\n    <groupId>org.apache.httpcomponents</groupId>\r\n    <artifactId>httpclient</artifactId>\r\n    <version>4.5.5</version>\r\n</dependency>\r\n\r\n<dependency>\r\n    <groupId>org.apache.httpcomponents</groupId>\r\n    <artifactId>httpcore</artifactId>\r\n    <version>4.4.9</version>\r\n</dependency>\r\n```\r\n\r\nThat gives me another error, but it looks OK to me:\r\n\r\n```\r\norg.springframework.web.client.ResourceAccessException: I/O error on GET request for \"http://localhost:8011/api/items\": Connect to localhost:8011 [localhost/127.0.0.1] failed: Connection refused (Connection refused); nested exception is org.apache.http.conn.HttpHostConnectException: Connect to localhost:8011 [localhost/127.0.0.1] failed: Connection refused (Connection refused)\r\n\tat java.net.PlainSocketImpl.socketConnect(Native Method)\r\n\tat java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350)\r\n\tat java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)\r\n```\r\n\r\n"}}
{"actor":{"display_login":"whiskeysierra"}}