Make Exchanger handler dispatch recoverable after process restart

Đang mở
#1,663 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
35/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Ít trao đổi
Công nghệ
python
Lĩnh vực
backend

Hướng nghiên cứu

Start with src/keri/peer/exchanging.py, especially Exchanger.processEvent() and the persistence and handler-dispatch steps linked in the issue. Trace how persisted exchanges and startup recovery are handled before choosing a durable strategy; the issue does not name specific tests or storage files. Done means focused crash/restart tests show accepted EXNs are recoverable, rejected EXNs stay out of the work path, and repeated handler processing is safe.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Feature request description/rationale

Exchanger.processEvent() persists a successfully verified exchange message and then dispatches it to the registered behavior handler:

https://github.com/WebOfTrust/keripy/blob/e2a1e35ca2b7d3ef1920c4bc956ccfd7400b46b6/src/keri/peer/exchanging.py#L171-L185

There is no durable indication that handler dispatch still needs to occur or a startup path that re-dispatches a persisted exchange whose handler did not finish. If the process stops after logEvent() but before or during behavior.handle(), the EXN can remain saved while the application-layer work triggered by that EXN is lost.

This matters for downstream handlers that drive IPEX and multisig workflows. It is the KERIpy side of the application-layer reliability concern described in WebOfTrust/keria#433.

Expected behavior

Once KERIpy accepts and persists an EXN for handler processing, a process restart must not permanently lose the associated handler work.

KERIpy should use a durable queue, escrow, or another appropriate storage strategy so incomplete handler dispatch can be recovered after startup. The implementation should also define safe repeated processing where recovery may cause an exchange to be presented to a handler more than once.

Suggested scope
  • Preserve pending handler work across process shutdown or failure.
  • Recover and resume or safely repeat incomplete dispatch on startup.
  • Keep rejected or unverifiable EXNs outside the durable work path.
  • Make the ownership boundary between Exchanger persistence and application handler completion explicit.
  • Add focused crash/restart tests around persistence, dispatch, and completion.

Related: WebOfTrust/keria#433

Ngôn ngữ chính
Python
Star
81
Fork
79
Merge trung bình
2 ngày 14 giờ
Pull request đã merge (30 ngày)
25

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của WebOfTrust/keripy

Tất cả issue của WebOfTrust/keripy

Issue tương tự

Thêm issue về Python

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.