alibaba / jstorm

Enterprise Stream Process Engine
http://jstorm.io
Apache License 2.0
3.91k stars 1.8k forks source link

关于ack bolt的问题 #275

Open 1647917675 opened 8 years ago

1647917675 commented 8 years ago

acker bolt 的代码 if (Acker.ACKER_ACK_STREAM_ID.equals(stream_id)) {

        if (curr != null) {
            curr.update_ack(input.getValue(1));
        } else {
            // two case
            // one is timeout
            // the other is bolt's ack first come  这里应该感觉基本上都是spout先处理,已经存在 curr了
            //  ack first come 是什么情况
            curr = new AckObject();
            curr.val = input.getLong(1);
            pending.put(id, curr);
unsleepy22 commented 8 years ago

就是消息乱序的情况,有可能还没收到__ack_init,就收到__ack_ack了