Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source
Source file commitment_event.ml
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176(*****************************************************************************)(* *)(* Open Source License *)(* Copyright (c) 2022 TriliTech <contact@trili.tech> *)(* *)(* Permission is hereby granted, free of charge, to any person obtaining a *)(* copy of this software and associated documentation files (the "Software"),*)(* to deal in the Software without restriction, including without limitation *)(* the rights to use, copy, modify, merge, publish, distribute, sublicense, *)(* and/or sell copies of the Software, and to permit persons to whom the *)(* Software is furnished to do so, subject to the following conditions: *)(* *)(* The above copyright notice and this permission notice shall be included *)(* in all copies or substantial portions of the Software. *)(* *)(* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR*)(* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, *)(* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL *)(* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER*)(* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING *)(* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER *)(* DEALINGS IN THE SOFTWARE. *)(* *)(*****************************************************************************)openPublisher_worker_typesmoduleSimple=structincludeInternal_event.Simpleletsection=["smart_rollup_node";"commitment"]letstarting=declare_0~section~name:"smart_rollup_node_commitment_publisher_starting"~msg:"Starting commitment publisher for the smart rollup node"~level:Info()letstopping=declare_0~section~name:"smart_rollup_node_commitment_publisher_stopping"~msg:"Stopping commitment publisher for the smart rollup node"~level:Info()letlast_cemented_commitment_updated=declare_2~section~name:"smart_rollup_node_commitment_lcc_updated"~msg:"Last cemented commitment was updated to hash {hash} at inbox level \
{level}"~level:Debug("hash",Commitment.Hash.encoding)("level",Data_encoding.int32)letlast_published_commitment_updated=declare_2~section~name:"smart_rollup_node_commitment_lpc_updated"~msg:"Last published commitment was updated to hash {hash} at inbox level \
{level}"~level:Debug("hash",Commitment.Hash.encoding)("level",Data_encoding.int32)letcompute_commitment=declare_1~section~name:"smart_rollup_node_commitment_compute"~msg:"Computing and storing new commitment for level {level}"~level:Info("level",Data_encoding.int32)letnew_commitment=declare_2~section~name:"smart_rollup_node_new_commitment"~msg:"New commitment {hash} for inbox level {level}"~level:Notice("hash",Commitment.Hash.encoding)("level",Data_encoding.int32)letpublish_commitment=declare_2~section~name:"smart_rollup_node_commitment_publish_commitment"~msg:"Publishing commitment {hash} for inbox level {level}"~level:Info("hash",Commitment.Hash.encoding)("level",Data_encoding.int32)letrecover_bond=declare_1~section~name:"smart_rollup_node_recover_bond"~msg:"Recover bond for {staker}"~level:Info("staker",Signature.Public_key_hash.encoding)letpublish_execute_whitelist_update=declare_3~section~name:"smart_rollup_node_publish_execute_whitelist_update"~msg:"Publishing execute whitelist update for cemented commitment {hash}, \
outbox level {outbox_level} and index {message_index}"~level:Info("hash",Commitment.Hash.encoding)("outbox_level",Data_encoding.int32)("message_index",Data_encoding.int31)modulePublisher=structletsection=section@["publisher"]letrequest_failed=declare_3~section~name:"request_failed"~msg:"[Warning] Request {view} failed ({worker_status}): {errors}"~level:Warning("view",Request.encoding)~pp1:Request.pp("worker_status",Worker_types.request_status_encoding)~pp2:Worker_types.pp_status("errors",Error_monad.trace_encoding)~pp3:Error_monad.pp_print_traceletrequest_completed=declare_2~section~name:"request_completed"~msg:"{view} {worker_status}"~level:Debug("view",Request.encoding)("worker_status",Worker_types.request_status_encoding)~pp1:Request.pp~pp2:Worker_types.pp_statusendendletstarting=Simple.(emitstarting)letstopping=Simple.(emitstopping)letsection=Simple.sectionletlast_cemented_commitment_updatedheadlevel=Simple.(emitlast_cemented_commitment_updated(head,level))letlast_published_commitment_updatedheadlevel=Simple.(emitlast_published_commitment_updated(head,level))letcompute_commitmentlevel=Simple.(emitcompute_commitmentlevel)letnew_commitmentheadlevel=Simple.(emitnew_commitment(head,level))letpublish_commitmentheadlevel=Simple.(emitpublish_commitment(head,level))letrecover_bondstaker=Simple.(emitrecover_bondstaker)letpublish_execute_whitelist_updatehashlevelindex=Simple.(emitpublish_execute_whitelist_update(hash,level,index))modulePublisher=structletrequest_failedviewworker_statuserrors=Simple.(emitPublisher.request_failed(view,worker_status,errors))letrequest_completedviewworker_status=Simple.(emitPublisher.request_completed(view,worker_status))end