{"action":"created","comment":{"url":"https://api.github.com/repos/ReactiveX/RxJava/pulls/comments/166486970","pull_request_review_id":94556387,"id":166486970,"diff_hunk":"@@ -19,14 +19,35 @@\n /**\n  * Provides a mechanism for receiving push-based notifications.\n  * <p>\n- * After an Observer calls an {@link Observable}'s {@link Observable#subscribe subscribe} method,\n- * first the Observable calls {@link #onSubscribe(Disposable)} with a {@link Disposable} that allows\n+ * When an {@code Observer} is subscribed to an {@link ObservableSource} through the {@link ObservableSource#subscribe(Observer)} method,\n+ * the {@code ObservableSource} calls {@link #onSubscribe(Disposable)}  with a {@link Disposable} that allows\n  * cancelling the sequence at any time, then the\n- * {@code Observable} may call the Observer's {@link #onNext} method any number of times\n+ * {@code ObservableSource} may call the Observer's {@link #onNext} method any number of times\n  * to provide notifications. A well-behaved\n- * {@code Observable} will call an Observer's {@link #onComplete} method exactly once or the Observer's\n+ * {@code ObservableSource} will call an {@code Observer}'s {@link #onComplete} method exactly once or the {@code Observer}'s\n  * {@link #onError} method exactly once.\n- *\n+ * <p>\n+ * Calling the {@code Observer}'s method must happen in a serialized fashion, that is, they must not\n+ * be invoked concurrently by multiple threads in an overlapping fashion and the invocation pattern must\n+ * adhere to the following protocol:\n+ * <p>\n+ * <pre><code>    onSubscribe onNext* (onError | onComplete)?</code></pre>\n+ * <p>\n+ * Subscribing an {@code Observer} to multiple {@code ObservableSource}s is not recommended. If such reuse\n+ * happens, it is the duty of the {@code Observer} implementation to be ready to receive multiple calls to\n+ * its methods and ensure proper concurrent behavior of its business logic.\n+ * <p>\n+ * Calling {@link #onSubscribe(Disposable)}, {@link #onNext(Object)} or {@link #onError(Throwable)} with a\n+ * {@code null} argument is forbidden.\n+ * <p>\n+ * The implementations of the {@code onXXX} methods should avoid throwing runtime exceptions other than the following cases:","path":"src/main/java/io/reactivex/Observer.java","position":31,"original_position":30,"commit_id":"a11f2285ebdc81e9e68a6ab06e1cd6aae5ad1984","original_commit_id":"1324f26ed2273253e9a50205d8bb6d601c957bcc","user":{"login":"artem-zinnatullin","id":967132,"avatar_url":"https://avatars0.githubusercontent.com/u/967132?v=4","gravatar_id":"","url":"https://api.github.com/users/artem-zinnatullin","html_url":"https://github.com/artem-zinnatullin","followers_url":"https://api.github.com/users/artem-zinnatullin/followers","following_url":"https://api.github.com/users/artem-zinnatullin/following{/other_user}","gists_url":"https://api.github.com/users/artem-zinnatullin/gists{/gist_id}","starred_url":"https://api.github.com/users/artem-zinnatullin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/artem-zinnatullin/subscriptions","organizations_url":"https://api.github.com/users/artem-zinnatullin/orgs","repos_url":"https://api.github.com/users/artem-zinnatullin/repos","events_url":"https://api.github.com/users/artem-zinnatullin/events{/privacy}","received_events_url":"https://api.github.com/users/artem-zinnatullin/received_events","type":"User","site_admin":false},"body":"When for some reason `Observer` finds itself in inconsistent state during `onXXX()` execution.\r\n\r\nIn this case exception thrown from `onXXX()` will reach `RxJavaPlugins` as `OnErrorNotImplementedException` and in case of Android will crash the application, on JVM user can hook into that and specify required behavior.\r\n\r\nThis is fail fast design principle, when instead of swallowing error states and writing defensive code you fail as soon as possible preventing inconsistent states from going deeper into your system.\r\n\r\nI'm just afraid that this doc might discourage people from that design principle","created_at":"2018-02-07T00:30:27Z","updated_at":"2018-02-07T00:30:27Z","html_url":"https://github.com/ReactiveX/RxJava/pull/5841#discussion_r166486970","pull_request_url":"https://api.github.com/repos/ReactiveX/RxJava/pulls/5841","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/ReactiveX/RxJava/pulls/comments/166486970"},"html":{"href":"https://github.com/ReactiveX/RxJava/pull/5841#discussion_r166486970"},"pull_request":{"href":"https://api.github.com/repos/ReactiveX/RxJava/pulls/5841"}},"in_reply_to_id":166192190},"pull_request":{"url":"https://api.github.com/repos/ReactiveX/RxJava/pulls/5841","id":167132707,"html_url":"https://github.com/ReactiveX/RxJava/pull/5841","diff_url":"https://github.com/ReactiveX/RxJava/pull/5841.diff","patch_url":"https://github.com/ReactiveX/RxJava/pull/5841.patch","issue_url":"https://api.github.com/repos/ReactiveX/RxJava/issues/5841","number":5841,"state":"open","locked":false,"title":"2.x: Improve JavaDoc of XObserver types.","user":{"login":"akarnokd","id":1269832,"avatar_url":"https://avatars2.githubusercontent.com/u/1269832?v=4","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":"This PR improves the JavaDoc of the 4 RxJava main consumer types:\r\n\r\n- `Observer`\r\n- `SingleObserver`\r\n- `MaybeObserver`\r\n- `CompletableObserver`","created_at":"2018-02-05T12:34:26Z","updated_at":"2018-02-07T00:30:27Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8c2e6794a0358554bb86cc34c350fdb478043c94","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"milestone":{"url":"https://api.github.com/repos/ReactiveX/RxJava/milestones/24","html_url":"https://github.com/ReactiveX/RxJava/milestone/24","labels_url":"https://api.github.com/repos/ReactiveX/RxJava/milestones/24/labels","id":2523573,"number":24,"title":"2.2","description":"Fixes, enhancements targeting version 2.2.0","creator":{"login":"akarnokd","id":1269832,"avatar_url":"https://avatars2.githubusercontent.com/u/1269832?v=4","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":5,"closed_issues":124,"state":"open","created_at":"2017-05-16T09:27:43Z","updated_at":"2018-02-05T12:34:26Z","due_on":"2018-02-28T08:00:00Z","closed_at":null},"commits_url":"https://api.github.com/repos/ReactiveX/RxJava/pulls/5841/commits","review_comments_url":"https://api.github.com/repos/ReactiveX/RxJava/pulls/5841/comments","review_comment_url":"https://api.github.com/repos/ReactiveX/RxJava/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ReactiveX/RxJava/issues/5841/comments","statuses_url":"https://api.github.com/repos/ReactiveX/RxJava/statuses/a11f2285ebdc81e9e68a6ab06e1cd6aae5ad1984","head":{"label":"akarnokd:JavadocClarifications0205","ref":"JavadocClarifications0205","sha":"a11f2285ebdc81e9e68a6ab06e1cd6aae5ad1984","user":{"login":"akarnokd","id":1269832,"avatar_url":"https://avatars2.githubusercontent.com/u/1269832?v=4","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},"repo":{"id":14518033,"name":"RxJava","full_name":"akarnokd/RxJava","owner":{"login":"akarnokd","id":1269832,"avatar_url":"https://avatars2.githubusercontent.com/u/1269832?v=4","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},"private":false,"html_url":"https://github.com/akarnokd/RxJava","description":"RxJava - a library for composing asynchronous and event-based programs using observable sequences for the Java VM.","fork":true,"url":"https://api.github.com/repos/akarnokd/RxJava","forks_url":"https://api.github.com/repos/akarnokd/RxJava/forks","keys_url":"https://api.github.com/repos/akarnokd/RxJava/keys{/key_id}","collaborators_url":"https://api.github.com/repos/akarnokd/RxJava/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/akarnokd/RxJava/teams","hooks_url":"https://api.github.com/repos/akarnokd/RxJava/hooks","issue_events_url":"https://api.github.com/repos/akarnokd/RxJava/issues/events{/number}","events_url":"https://api.github.com/repos/akarnokd/RxJava/events","assignees_url":"https://api.github.com/repos/akarnokd/RxJava/assignees{/user}","branches_url":"https://api.github.com/repos/akarnokd/RxJava/branches{/branch}","tags_url":"https://api.github.com/repos/akarnokd/RxJava/tags","blobs_url":"https://api.github.com/repos/akarnokd/RxJava/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/akarnokd/RxJava/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/akarnokd/RxJava/git/refs{/sha}","trees_url":"https://api.github.com/repos/akarnokd/RxJava/git/trees{/sha}","statuses_url":"https://api.github.com/repos/akarnokd/RxJava/statuses/{sha}","languages_url":"https://api.github.com/repos/akarnokd/RxJava/languages","stargazers_url":"https://api.github.com/repos/akarnokd/RxJava/stargazers","contributors_url":"https://api.github.com/repos/akarnokd/RxJava/contributors","subscribers_url":"https://api.github.com/repos/akarnokd/RxJava/subscribers","subscription_url":"https://api.github.com/repos/akarnokd/RxJava/subscription","commits_url":"https://api.github.com/repos/akarnokd/RxJava/commits{/sha}","git_commits_url":"https://api.github.com/repos/akarnokd/RxJava/git/commits{/sha}","comments_url":"https://api.github.com/repos/akarnokd/RxJava/comments{/number}","issue_comment_url":"https://api.github.com/repos/akarnokd/RxJava/issues/comments{/number}","contents_url":"https://api.github.com/repos/akarnokd/RxJava/contents/{+path}","compare_url":"https://api.github.com/repos/akarnokd/RxJava/compare/{base}...{head}","merges_url":"https://api.github.com/repos/akarnokd/RxJava/merges","archive_url":"https://api.github.com/repos/akarnokd/RxJava/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/akarnokd/RxJava/downloads","issues_url":"https://api.github.com/repos/akarnokd/RxJava/issues{/number}","pulls_url":"https://api.github.com/repos/akarnokd/RxJava/pulls{/number}","milestones_url":"https://api.github.com/repos/akarnokd/RxJava/milestones{/number}","notifications_url":"https://api.github.com/repos/akarnokd/RxJava/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/akarnokd/RxJava/labels{/name}","releases_url":"https://api.github.com/repos/akarnokd/RxJava/releases{/id}","deployments_url":"https://api.github.com/repos/akarnokd/RxJava/deployments","created_at":"2013-11-19T08:04:52Z","updated_at":"2017-07-25T13:23:33Z","pushed_at":"2018-02-06T10:13:27Z","git_url":"git://github.com/akarnokd/RxJava.git","ssh_url":"git@github.com:akarnokd/RxJava.git","clone_url":"https://github.com/akarnokd/RxJava.git","svn_url":"https://github.com/akarnokd/RxJava","homepage":"","size":29862,"stargazers_count":3,"watchers_count":3,"language":"Java","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0"},"forks":2,"open_issues":0,"watchers":3,"default_branch":"2.x"}},"base":{"label":"ReactiveX:2.x","ref":"2.x","sha":"363f0381c2fcc9df287d771ffd2826c64c998145","user":{"login":"ReactiveX","id":6407041,"avatar_url":"https://avatars1.githubusercontent.com/u/6407041?v=4","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://avatars1.githubusercontent.com/u/6407041?v=4","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":"2018-02-06T23:28:27Z","pushed_at":"2018-02-06T10:13:35Z","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":48089,"stargazers_count":30702,"watchers_count":30702,"language":"Java","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":5405,"mirror_url":null,"archived":false,"open_issues_count":37,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0"},"forks":5405,"open_issues":37,"watchers":30702,"default_branch":"2.x"}},"_links":{"self":{"href":"https://api.github.com/repos/ReactiveX/RxJava/pulls/5841"},"html":{"href":"https://github.com/ReactiveX/RxJava/pull/5841"},"issue":{"href":"https://api.github.com/repos/ReactiveX/RxJava/issues/5841"},"comments":{"href":"https://api.github.com/repos/ReactiveX/RxJava/issues/5841/comments"},"review_comments":{"href":"https://api.github.com/repos/ReactiveX/RxJava/pulls/5841/comments"},"review_comment":{"href":"https://api.github.com/repos/ReactiveX/RxJava/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ReactiveX/RxJava/pulls/5841/commits"},"statuses":{"href":"https://api.github.com/repos/ReactiveX/RxJava/statuses/a11f2285ebdc81e9e68a6ab06e1cd6aae5ad1984"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"artem-zinnatullin"}}