{"action":"closed","issue":{"url":"https://api.github.com/repos/awslabs/amazon-kinesis-client/issues/40","labels_url":"https://api.github.com/repos/awslabs/amazon-kinesis-client/issues/40/labels{/name}","comments_url":"https://api.github.com/repos/awslabs/amazon-kinesis-client/issues/40/comments","events_url":"https://api.github.com/repos/awslabs/amazon-kinesis-client/issues/40/events","html_url":"https://github.com/awslabs/amazon-kinesis-client/issues/40","id":107343048,"number":40,"title":"Subsequent calls to processRecords with 0 records has incorrect largestPermittedCheckpointValue","user":{"login":"rvestal37","id":13202090,"avatar_url":"https://avatars.githubusercontent.com/u/13202090?v=3","gravatar_id":"","url":"https://api.github.com/users/rvestal37","html_url":"https://github.com/rvestal37","followers_url":"https://api.github.com/users/rvestal37/followers","following_url":"https://api.github.com/users/rvestal37/following{/other_user}","gists_url":"https://api.github.com/users/rvestal37/gists{/gist_id}","starred_url":"https://api.github.com/users/rvestal37/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rvestal37/subscriptions","organizations_url":"https://api.github.com/users/rvestal37/orgs","repos_url":"https://api.github.com/users/rvestal37/repos","events_url":"https://api.github.com/users/rvestal37/events{/privacy}","received_events_url":"https://api.github.com/users/rvestal37/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-09-19T16:33:15Z","updated_at":"2015-09-24T01:43:44Z","closed_at":"2015-09-24T01:43:44Z","body":"In the case where some records are processed in one call, but NOT checkpointed, subsequent calls to the processRecords method with 0 records has the largest permitted value of the checkpointer set to the last checkpoint value and NOT the current largest value (which should be the largest permitted value from the last time processRecords was called with at least one record).\r\n\r\nIt looks like this is done in ProcessTask line 154 where if there are no records, the largest permitted value is set to the last checkpoint value instead of keeping its value from the last run.\r\n\r\nIf this is the expected/desired behaviour, how does a KCL application issue a checkpoint in subsequent calls to processRecords where there are 0 records (i.e. I get a few records, then after a minute or two decide it is time to do a checkpoint)?\r\n\r\nIf I store the last read record and use it for the checkpoint call, the RecordProcessorCheckpointer will throw during a checkpoint when 0 records were received because the record is not within the bounds of the last checkpoint and the largest permitted (which is the last checkpoint).\r\n\r\nThanks"}}