{"action":"created","issue":{"url":"https://api.github.com/repos/apache/kafka/issues/4826","repository_url":"https://api.github.com/repos/apache/kafka","labels_url":"https://api.github.com/repos/apache/kafka/issues/4826/labels{/name}","comments_url":"https://api.github.com/repos/apache/kafka/issues/4826/comments","events_url":"https://api.github.com/repos/apache/kafka/issues/4826/events","html_url":"https://github.com/apache/kafka/pull/4826","id":311426342,"number":4826,"title":"KAFKA-6747 Check whether there is in-flight transaction before aborting transaction","user":{"login":"tedyu","id":235188,"avatar_url":"https://avatars3.githubusercontent.com/u/235188?v=4","gravatar_id":"","url":"https://api.github.com/users/tedyu","html_url":"https://github.com/tedyu","followers_url":"https://api.github.com/users/tedyu/followers","following_url":"https://api.github.com/users/tedyu/following{/other_user}","gists_url":"https://api.github.com/users/tedyu/gists{/gist_id}","starred_url":"https://api.github.com/users/tedyu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tedyu/subscriptions","organizations_url":"https://api.github.com/users/tedyu/orgs","repos_url":"https://api.github.com/users/tedyu/repos","events_url":"https://api.github.com/users/tedyu/events{/privacy}","received_events_url":"https://api.github.com/users/tedyu/received_events","type":"User","site_admin":false},"labels":[{"id":820747028,"url":"https://api.github.com/repos/apache/kafka/labels/streams","name":"streams","color":"63edea","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-04-04T23:34:34Z","updated_at":"2018-04-05T17:50:34Z","closed_at":null,"author_association":"CONTRIBUTOR","pull_request":{"url":"https://api.github.com/repos/apache/kafka/pulls/4826","html_url":"https://github.com/apache/kafka/pull/4826","diff_url":"https://github.com/apache/kafka/pull/4826.diff","patch_url":"https://github.com/apache/kafka/pull/4826.patch"},"body":"As Frederic reported on mailing list under the subject \"kafka-streams Invalid transition attempted from state READY to state ABORTING_TRANSACTION\", producer#abortTransaction should only be called when transactionInFlight is true.\r\n\r\n### Committer Checklist (excluded from commit message)\r\n- [ ] Verify design and implementation \r\n- [ ] Verify test coverage and CI build status\r\n- [ ] Verify documentation (including upgrade notes)\r\n"},"comment":{"url":"https://api.github.com/repos/apache/kafka/issues/comments/379021066","html_url":"https://github.com/apache/kafka/pull/4826#issuecomment-379021066","issue_url":"https://api.github.com/repos/apache/kafka/issues/4826","id":379021066,"user":{"login":"guozhangwang","id":10729597,"avatar_url":"https://avatars0.githubusercontent.com/u/10729597?v=4","gravatar_id":"","url":"https://api.github.com/users/guozhangwang","html_url":"https://github.com/guozhangwang","followers_url":"https://api.github.com/users/guozhangwang/followers","following_url":"https://api.github.com/users/guozhangwang/following{/other_user}","gists_url":"https://api.github.com/users/guozhangwang/gists{/gist_id}","starred_url":"https://api.github.com/users/guozhangwang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/guozhangwang/subscriptions","organizations_url":"https://api.github.com/users/guozhangwang/orgs","repos_url":"https://api.github.com/users/guozhangwang/repos","events_url":"https://api.github.com/users/guozhangwang/events{/privacy}","received_events_url":"https://api.github.com/users/guozhangwang/received_events","type":"User","site_admin":false},"created_at":"2018-04-05T17:50:34Z","updated_at":"2018-04-05T17:50:34Z","author_association":"CONTRIBUTOR","body":"@tedyu Thanks for the PR, the fix looks good to me. Could we add a unit test to expose this issue and illustrate that it is fixed in this PR? For example:\r\n\r\n1. create a new `StreamTask` (beginTransaction not called yet).\r\n2. call `task.close()` immediately after the construction; without the fix it should be reproducing the error trace, and with the fix it should be fine."}}
{"actor":{"display_login":"guozhangwang"}}