{"action":"created","comment":{"url":"https://api.github.com/repos/ReactiveX/RxJava/pulls/comments/76781893","id":76781893,"diff_hunk":"@@ -0,0 +1,133 @@\n+/**\n+ * Copyright 2016 Netflix, Inc.\n+ * \n+ * Licensed under the Apache License, Version 2.0 (the \"License\"); you may not use this file except in\n+ * compliance with the License. You may obtain a copy of the License at\n+ * \n+ * http://www.apache.org/licenses/LICENSE-2.0\n+ * \n+ * Unless required by applicable law or agreed to in writing, software distributed under the License is\n+ * distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See\n+ * the License for the specific language governing permissions and limitations under the License.\n+ */\n+\n+package io.reactivex.internal.operators.flowable;\n+\n+import static io.reactivex.BackpressureOverflowStrategy.DROP_OLDEST;\n+import static org.junit.Assert.assertEquals;\n+\n+import java.util.concurrent.CountDownLatch;\n+import java.util.concurrent.atomic.AtomicInteger;\n+\n+import org.junit.Test;\n+\n+import io.reactivex.Flowable;\n+import io.reactivex.functions.Action;\n+import io.reactivex.internal.subscriptions.BooleanSubscription;\n+import io.reactivex.schedulers.Schedulers;\n+import io.reactivex.subscribers.DefaultSubscriber;\n+import io.reactivex.subscribers.TestSubscriber;\n+import org.reactivestreams.Publisher;\n+import org.reactivestreams.Subscriber;\n+\n+public class FlowableOnBackpressureBufferStrategyTest {\n+\n+    private static Action onOverFlow = new Action() {\n+        @Override\n+        public void run() throws Exception {\n+            // Nothing\n+        }\n+    };\n+\n+\n+    @Test(timeout = 2000)\n+    public void testFixBackpressureWithBuffer() throws InterruptedException {","path":"src/test/java/io/reactivex/internal/operators/flowable/FlowableOnBackpressureBufferStrategyTest.java","position":44,"original_position":44,"commit_id":"607752975459da53bece3f58b68b6c54114a3e1e","original_commit_id":"607752975459da53bece3f58b68b6c54114a3e1e","user":{"login":"akarnokd","id":1269832,"avatar_url":"https://avatars.githubusercontent.com/u/1269832?v=3","gravatar_id":"","url":"https://api.github.com/users/akarnokd","html_url":"https://github.com/akarnokd","followers_url":"https://api.github.com/users/akarnokd/followers","following_url":"https://api.github.com/users/akarnokd/following{/other_user}","gists_url":"https://api.github.com/users/akarnokd/gists{/gist_id}","starred_url":"https://api.github.com/users/akarnokd/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/akarnokd/subscriptions","organizations_url":"https://api.github.com/users/akarnokd/orgs","repos_url":"https://api.github.com/users/akarnokd/repos","events_url":"https://api.github.com/users/akarnokd/events{/privacy}","received_events_url":"https://api.github.com/users/akarnokd/received_events","type":"User","site_admin":false},"body":"Don't request upfront. Fill the buffer until it drops items then issue a `TestSubscriber.request()` and see if the right value comes out. No threading needed.","created_at":"2016-08-30T12:08:48Z","updated_at":"2016-08-30T12:08:48Z","html_url":"https://github.com/ReactiveX/RxJava/pull/4441#discussion_r76781893","pull_request_url":"https://api.github.com/repos/ReactiveX/RxJava/pulls/4441","_links":{"self":{"href":"https://api.github.com/repos/ReactiveX/RxJava/pulls/comments/76781893"},"html":{"href":"https://github.com/ReactiveX/RxJava/pull/4441#discussion_r76781893"},"pull_request":{"href":"https://api.github.com/repos/ReactiveX/RxJava/pulls/4441"}}},"pull_request":{"url":"https://api.github.com/repos/ReactiveX/RxJava/pulls/4441","id":83228656,"html_url":"https://github.com/ReactiveX/RxJava/pull/4441","diff_url":"https://github.com/ReactiveX/RxJava/pull/4441.diff","patch_url":"https://github.com/ReactiveX/RxJava/pull/4441.patch","issue_url":"https://api.github.com/repos/ReactiveX/RxJava/issues/4441","number":4441,"state":"open","locked":false,"title":"Fix FlowableOnBackpressureBufferStrategy","user":{"login":"matgabriel","id":6783734,"avatar_url":"https://avatars.githubusercontent.com/u/6783734?v=3","gravatar_id":"","url":"https://api.github.com/users/matgabriel","html_url":"https://github.com/matgabriel","followers_url":"https://api.github.com/users/matgabriel/followers","following_url":"https://api.github.com/users/matgabriel/following{/other_user}","gists_url":"https://api.github.com/users/matgabriel/gists{/gist_id}","starred_url":"https://api.github.com/users/matgabriel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/matgabriel/subscriptions","organizations_url":"https://api.github.com/users/matgabriel/orgs","repos_url":"https://api.github.com/users/matgabriel/repos","events_url":"https://api.github.com/users/matgabriel/events{/privacy}","received_events_url":"https://api.github.com/users/matgabriel/received_events","type":"User","site_admin":false},"body":"Fix buffered objects not propagated downstream in FlowableOnBackpressureBufferStrategy\r\nFix drop strategy logic in FlowableOnBackpressureBufferStrategy\r\nAdd unit test for FlowableOnBackpressureBufferStrategy, copied from FlowableOnBackpressureBufferTest, there is still some work needed to have a better coverage","created_at":"2016-08-30T08:30:41Z","updated_at":"2016-08-30T12:08:48Z","closed_at":null,"merged_at":null,"merge_commit_sha":"08bcda7313ced90f5d2253eb56a56be940267226","assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/ReactiveX/RxJava/milestones/15","html_url":"https://github.com/ReactiveX/RxJava/milestones/2.0%20RC%202","labels_url":"https://api.github.com/repos/ReactiveX/RxJava/milestones/15/labels","id":1835499,"number":15,"title":"2.0 RC 2","description":"Address feedback regarding API, behavior and issues from RC 1.\r\n\r\nPossibly public API lockdown.","creator":{"login":"akarnokd","id":1269832,"avatar_url":"https://avatars.githubusercontent.com/u/1269832?v=3","gravatar_id":"","url":"https://api.github.com/users/akarnokd","html_url":"https://github.com/akarnokd","followers_url":"https://api.github.com/users/akarnokd/followers","following_url":"https://api.github.com/users/akarnokd/following{/other_user}","gists_url":"https://api.github.com/users/akarnokd/gists{/gist_id}","starred_url":"https://api.github.com/users/akarnokd/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/akarnokd/subscriptions","organizations_url":"https://api.github.com/users/akarnokd/orgs","repos_url":"https://api.github.com/users/akarnokd/repos","events_url":"https://api.github.com/users/akarnokd/events{/privacy}","received_events_url":"https://api.github.com/users/akarnokd/received_events","type":"User","site_admin":false},"open_issues":10,"closed_issues":6,"state":"open","created_at":"2016-06-17T22:58:23Z","updated_at":"2016-08-30T08:46:36Z","due_on":"2016-09-22T22:00:00Z","closed_at":null},"commits_url":"https://api.github.com/repos/ReactiveX/RxJava/pulls/4441/commits","review_comments_url":"https://api.github.com/repos/ReactiveX/RxJava/pulls/4441/comments","review_comment_url":"https://api.github.com/repos/ReactiveX/RxJava/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ReactiveX/RxJava/issues/4441/comments","statuses_url":"https://api.github.com/repos/ReactiveX/RxJava/statuses/607752975459da53bece3f58b68b6c54114a3e1e","head":{"label":"matgabriel:2.x","ref":"2.x","sha":"607752975459da53bece3f58b68b6c54114a3e1e","user":{"login":"matgabriel","id":6783734,"avatar_url":"https://avatars.githubusercontent.com/u/6783734?v=3","gravatar_id":"","url":"https://api.github.com/users/matgabriel","html_url":"https://github.com/matgabriel","followers_url":"https://api.github.com/users/matgabriel/followers","following_url":"https://api.github.com/users/matgabriel/following{/other_user}","gists_url":"https://api.github.com/users/matgabriel/gists{/gist_id}","starred_url":"https://api.github.com/users/matgabriel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/matgabriel/subscriptions","organizations_url":"https://api.github.com/users/matgabriel/orgs","repos_url":"https://api.github.com/users/matgabriel/repos","events_url":"https://api.github.com/users/matgabriel/events{/privacy}","received_events_url":"https://api.github.com/users/matgabriel/received_events","type":"User","site_admin":false},"repo":{"id":66864003,"name":"RxJava","full_name":"matgabriel/RxJava","owner":{"login":"matgabriel","id":6783734,"avatar_url":"https://avatars.githubusercontent.com/u/6783734?v=3","gravatar_id":"","url":"https://api.github.com/users/matgabriel","html_url":"https://github.com/matgabriel","followers_url":"https://api.github.com/users/matgabriel/followers","following_url":"https://api.github.com/users/matgabriel/following{/other_user}","gists_url":"https://api.github.com/users/matgabriel/gists{/gist_id}","starred_url":"https://api.github.com/users/matgabriel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/matgabriel/subscriptions","organizations_url":"https://api.github.com/users/matgabriel/orgs","repos_url":"https://api.github.com/users/matgabriel/repos","events_url":"https://api.github.com/users/matgabriel/events{/privacy}","received_events_url":"https://api.github.com/users/matgabriel/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/matgabriel/RxJava","description":"RxJava – Reactive Extensions for the JVM – a library for composing asynchronous and event-based programs using observable sequences for the Java VM.","fork":true,"url":"https://api.github.com/repos/matgabriel/RxJava","forks_url":"https://api.github.com/repos/matgabriel/RxJava/forks","keys_url":"https://api.github.com/repos/matgabriel/RxJava/keys{/key_id}","collaborators_url":"https://api.github.com/repos/matgabriel/RxJava/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/matgabriel/RxJava/teams","hooks_url":"https://api.github.com/repos/matgabriel/RxJava/hooks","issue_events_url":"https://api.github.com/repos/matgabriel/RxJava/issues/events{/number}","events_url":"https://api.github.com/repos/matgabriel/RxJava/events","assignees_url":"https://api.github.com/repos/matgabriel/RxJava/assignees{/user}","branches_url":"https://api.github.com/repos/matgabriel/RxJava/branches{/branch}","tags_url":"https://api.github.com/repos/matgabriel/RxJava/tags","blobs_url":"https://api.github.com/repos/matgabriel/RxJava/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/matgabriel/RxJava/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/matgabriel/RxJava/git/refs{/sha}","trees_url":"https://api.github.com/repos/matgabriel/RxJava/git/trees{/sha}","statuses_url":"https://api.github.com/repos/matgabriel/RxJava/statuses/{sha}","languages_url":"https://api.github.com/repos/matgabriel/RxJava/languages","stargazers_url":"https://api.github.com/repos/matgabriel/RxJava/stargazers","contributors_url":"https://api.github.com/repos/matgabriel/RxJava/contributors","subscribers_url":"https://api.github.com/repos/matgabriel/RxJava/subscribers","subscription_url":"https://api.github.com/repos/matgabriel/RxJava/subscription","commits_url":"https://api.github.com/repos/matgabriel/RxJava/commits{/sha}","git_commits_url":"https://api.github.com/repos/matgabriel/RxJava/git/commits{/sha}","comments_url":"https://api.github.com/repos/matgabriel/RxJava/comments{/number}","issue_comment_url":"https://api.github.com/repos/matgabriel/RxJava/issues/comments{/number}","contents_url":"https://api.github.com/repos/matgabriel/RxJava/contents/{+path}","compare_url":"https://api.github.com/repos/matgabriel/RxJava/compare/{base}...{head}","merges_url":"https://api.github.com/repos/matgabriel/RxJava/merges","archive_url":"https://api.github.com/repos/matgabriel/RxJava/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/matgabriel/RxJava/downloads","issues_url":"https://api.github.com/repos/matgabriel/RxJava/issues{/number}","pulls_url":"https://api.github.com/repos/matgabriel/RxJava/pulls{/number}","milestones_url":"https://api.github.com/repos/matgabriel/RxJava/milestones{/number}","notifications_url":"https://api.github.com/repos/matgabriel/RxJava/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/matgabriel/RxJava/labels{/name}","releases_url":"https://api.github.com/repos/matgabriel/RxJava/releases{/id}","deployments_url":"https://api.github.com/repos/matgabriel/RxJava/deployments","created_at":"2016-08-29T17:15:15Z","updated_at":"2016-08-29T17:15:22Z","pushed_at":"2016-08-30T08:28:42Z","git_url":"git://github.com/matgabriel/RxJava.git","ssh_url":"git@github.com:matgabriel/RxJava.git","clone_url":"https://github.com/matgabriel/RxJava.git","svn_url":"https://github.com/matgabriel/RxJava","homepage":"","size":28410,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"1.x"}},"base":{"label":"ReactiveX:2.x","ref":"2.x","sha":"a856572327528ee05c1d1ab05426343aa0c5224b","user":{"login":"ReactiveX","id":6407041,"avatar_url":"https://avatars.githubusercontent.com/u/6407041?v=3","gravatar_id":"","url":"https://api.github.com/users/ReactiveX","html_url":"https://github.com/ReactiveX","followers_url":"https://api.github.com/users/ReactiveX/followers","following_url":"https://api.github.com/users/ReactiveX/following{/other_user}","gists_url":"https://api.github.com/users/ReactiveX/gists{/gist_id}","starred_url":"https://api.github.com/users/ReactiveX/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ReactiveX/subscriptions","organizations_url":"https://api.github.com/users/ReactiveX/orgs","repos_url":"https://api.github.com/users/ReactiveX/repos","events_url":"https://api.github.com/users/ReactiveX/events{/privacy}","received_events_url":"https://api.github.com/users/ReactiveX/received_events","type":"Organization","site_admin":false},"repo":{"id":7508411,"name":"RxJava","full_name":"ReactiveX/RxJava","owner":{"login":"ReactiveX","id":6407041,"avatar_url":"https://avatars.githubusercontent.com/u/6407041?v=3","gravatar_id":"","url":"https://api.github.com/users/ReactiveX","html_url":"https://github.com/ReactiveX","followers_url":"https://api.github.com/users/ReactiveX/followers","following_url":"https://api.github.com/users/ReactiveX/following{/other_user}","gists_url":"https://api.github.com/users/ReactiveX/gists{/gist_id}","starred_url":"https://api.github.com/users/ReactiveX/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ReactiveX/subscriptions","organizations_url":"https://api.github.com/users/ReactiveX/orgs","repos_url":"https://api.github.com/users/ReactiveX/repos","events_url":"https://api.github.com/users/ReactiveX/events{/privacy}","received_events_url":"https://api.github.com/users/ReactiveX/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ReactiveX/RxJava","description":"RxJava – Reactive Extensions for the JVM – a library for composing asynchronous and event-based programs using observable sequences for the Java VM.","fork":false,"url":"https://api.github.com/repos/ReactiveX/RxJava","forks_url":"https://api.github.com/repos/ReactiveX/RxJava/forks","keys_url":"https://api.github.com/repos/ReactiveX/RxJava/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ReactiveX/RxJava/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ReactiveX/RxJava/teams","hooks_url":"https://api.github.com/repos/ReactiveX/RxJava/hooks","issue_events_url":"https://api.github.com/repos/ReactiveX/RxJava/issues/events{/number}","events_url":"https://api.github.com/repos/ReactiveX/RxJava/events","assignees_url":"https://api.github.com/repos/ReactiveX/RxJava/assignees{/user}","branches_url":"https://api.github.com/repos/ReactiveX/RxJava/branches{/branch}","tags_url":"https://api.github.com/repos/ReactiveX/RxJava/tags","blobs_url":"https://api.github.com/repos/ReactiveX/RxJava/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ReactiveX/RxJava/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ReactiveX/RxJava/git/refs{/sha}","trees_url":"https://api.github.com/repos/ReactiveX/RxJava/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ReactiveX/RxJava/statuses/{sha}","languages_url":"https://api.github.com/repos/ReactiveX/RxJava/languages","stargazers_url":"https://api.github.com/repos/ReactiveX/RxJava/stargazers","contributors_url":"https://api.github.com/repos/ReactiveX/RxJava/contributors","subscribers_url":"https://api.github.com/repos/ReactiveX/RxJava/subscribers","subscription_url":"https://api.github.com/repos/ReactiveX/RxJava/subscription","commits_url":"https://api.github.com/repos/ReactiveX/RxJava/commits{/sha}","git_commits_url":"https://api.github.com/repos/ReactiveX/RxJava/git/commits{/sha}","comments_url":"https://api.github.com/repos/ReactiveX/RxJava/comments{/number}","issue_comment_url":"https://api.github.com/repos/ReactiveX/RxJava/issues/comments{/number}","contents_url":"https://api.github.com/repos/ReactiveX/RxJava/contents/{+path}","compare_url":"https://api.github.com/repos/ReactiveX/RxJava/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ReactiveX/RxJava/merges","archive_url":"https://api.github.com/repos/ReactiveX/RxJava/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ReactiveX/RxJava/downloads","issues_url":"https://api.github.com/repos/ReactiveX/RxJava/issues{/number}","pulls_url":"https://api.github.com/repos/ReactiveX/RxJava/pulls{/number}","milestones_url":"https://api.github.com/repos/ReactiveX/RxJava/milestones{/number}","notifications_url":"https://api.github.com/repos/ReactiveX/RxJava/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ReactiveX/RxJava/labels{/name}","releases_url":"https://api.github.com/repos/ReactiveX/RxJava/releases{/id}","deployments_url":"https://api.github.com/repos/ReactiveX/RxJava/deployments","created_at":"2013-01-08T20:11:48Z","updated_at":"2016-08-30T12:04:58Z","pushed_at":"2016-08-30T09:04:55Z","git_url":"git://github.com/ReactiveX/RxJava.git","ssh_url":"git@github.com:ReactiveX/RxJava.git","clone_url":"https://github.com/ReactiveX/RxJava.git","svn_url":"https://github.com/ReactiveX/RxJava","homepage":"","size":40078,"stargazers_count":16521,"watchers_count":16521,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":2877,"mirror_url":null,"open_issues_count":68,"forks":2877,"open_issues":68,"watchers":16521,"default_branch":"1.x"}},"_links":{"self":{"href":"https://api.github.com/repos/ReactiveX/RxJava/pulls/4441"},"html":{"href":"https://github.com/ReactiveX/RxJava/pull/4441"},"issue":{"href":"https://api.github.com/repos/ReactiveX/RxJava/issues/4441"},"comments":{"href":"https://api.github.com/repos/ReactiveX/RxJava/issues/4441/comments"},"review_comments":{"href":"https://api.github.com/repos/ReactiveX/RxJava/pulls/4441/comments"},"review_comment":{"href":"https://api.github.com/repos/ReactiveX/RxJava/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ReactiveX/RxJava/pulls/4441/commits"},"statuses":{"href":"https://api.github.com/repos/ReactiveX/RxJava/statuses/607752975459da53bece3f58b68b6c54114a3e1e"}}}}
{"actor":{"display_login":"akarnokd"}}