From d757518b72fa4bb4f861011d6d5fe170f7711630 Mon Sep 17 00:00:00 2001 From: Lavysh Alexander Date: Tue, 31 Oct 2023 19:41:40 +0300 Subject: [PATCH 1/4] added new events types --- cmd/api/docs/docs.go | 10 ++++++++-- cmd/api/docs/swagger.json | 10 ++++++++-- cmd/api/docs/swagger.yaml | 6 ++++++ internal/storage/types/event_type.go | 6 +++++- internal/storage/types/event_type_enum.go | 12 ++++++++++++ 5 files changed, 39 insertions(+), 5 deletions(-) diff --git a/cmd/api/docs/docs.go b/cmd/api/docs/docs.go index 5d68b483..b995fb22 100644 --- a/cmd/api/docs/docs.go +++ b/cmd/api/docs/docs.go @@ -2587,7 +2587,10 @@ const docTemplate = `{ "submit_proposal", "cosmos.authz.v1beta1.EventGrant", "send_packet", - "ibc_transfer" + "ibc_transfer", + "fungible_token_packet", + "acknowledge_packet", + "update_client" ], "x-enum-varnames": [ "EventTypeUnknown", @@ -2623,7 +2626,10 @@ const docTemplate = `{ "EventTypeSubmitProposal", "EventTypeCosmosauthzv1beta1EventGrant", "EventTypeSendPacket", - "EventTypeIbcTransfer" + "EventTypeIbcTransfer", + "EventTypeFungibleTokenPacket", + "EventTypeAcknowledgePacket", + "EventTypeUpdateClient" ] }, "types.MsgType": { diff --git a/cmd/api/docs/swagger.json b/cmd/api/docs/swagger.json index 89ada16d..df136cd8 100644 --- a/cmd/api/docs/swagger.json +++ b/cmd/api/docs/swagger.json @@ -2580,7 +2580,10 @@ "submit_proposal", "cosmos.authz.v1beta1.EventGrant", "send_packet", - "ibc_transfer" + "ibc_transfer", + "fungible_token_packet", + "acknowledge_packet", + "update_client" ], "x-enum-varnames": [ "EventTypeUnknown", @@ -2616,7 +2619,10 @@ "EventTypeSubmitProposal", "EventTypeCosmosauthzv1beta1EventGrant", "EventTypeSendPacket", - "EventTypeIbcTransfer" + "EventTypeIbcTransfer", + "EventTypeFungibleTokenPacket", + "EventTypeAcknowledgePacket", + "EventTypeUpdateClient" ] }, "types.MsgType": { diff --git a/cmd/api/docs/swagger.yaml b/cmd/api/docs/swagger.yaml index 818759b0..5be0e069 100644 --- a/cmd/api/docs/swagger.yaml +++ b/cmd/api/docs/swagger.yaml @@ -535,6 +535,9 @@ definitions: - cosmos.authz.v1beta1.EventGrant - send_packet - ibc_transfer + - fungible_token_packet + - acknowledge_packet + - update_client type: string x-enum-varnames: - EventTypeUnknown @@ -571,6 +574,9 @@ definitions: - EventTypeCosmosauthzv1beta1EventGrant - EventTypeSendPacket - EventTypeIbcTransfer + - EventTypeFungibleTokenPacket + - EventTypeAcknowledgePacket + - EventTypeUpdateClient types.MsgType: enum: - MsgUnknown diff --git a/internal/storage/types/event_type.go b/internal/storage/types/event_type.go index 2dc9049d..28ff0303 100644 --- a/internal/storage/types/event_type.go +++ b/internal/storage/types/event_type.go @@ -45,7 +45,11 @@ package types cosmos.authz.v1beta1.EventGrant, send_packet, - ibc_transfer + ibc_transfer, + + fungible_token_packet, + acknowledge_packet, + update_client ) */ //go:generate go-enum --marshal --sql --values diff --git a/internal/storage/types/event_type_enum.go b/internal/storage/types/event_type_enum.go index d5ce3b67..d4f508cf 100644 --- a/internal/storage/types/event_type_enum.go +++ b/internal/storage/types/event_type_enum.go @@ -81,6 +81,12 @@ const ( EventTypeSendPacket EventType = "send_packet" // EventTypeIbcTransfer is a EventType of type ibc_transfer. EventTypeIbcTransfer EventType = "ibc_transfer" + // EventTypeFungibleTokenPacket is a EventType of type fungible_token_packet. + EventTypeFungibleTokenPacket EventType = "fungible_token_packet" + // EventTypeAcknowledgePacket is a EventType of type acknowledge_packet. + EventTypeAcknowledgePacket EventType = "acknowledge_packet" + // EventTypeUpdateClient is a EventType of type update_client. + EventTypeUpdateClient EventType = "update_client" ) var ErrInvalidEventType = errors.New("not a valid EventType") @@ -122,6 +128,9 @@ func EventTypeValues() []EventType { EventTypeCosmosauthzv1beta1EventGrant, EventTypeSendPacket, EventTypeIbcTransfer, + EventTypeFungibleTokenPacket, + EventTypeAcknowledgePacket, + EventTypeUpdateClient, } } @@ -172,6 +181,9 @@ var _EventTypeValue = map[string]EventType{ "cosmos.authz.v1beta1.EventGrant": EventTypeCosmosauthzv1beta1EventGrant, "send_packet": EventTypeSendPacket, "ibc_transfer": EventTypeIbcTransfer, + "fungible_token_packet": EventTypeFungibleTokenPacket, + "acknowledge_packet": EventTypeAcknowledgePacket, + "update_client": EventTypeUpdateClient, } // ParseEventType attempts to convert a string to a EventType. From 6938a41eaeead45f5396ab901611fd6516cfc29d Mon Sep 17 00:00:00 2001 From: Lavysh Alexander Date: Tue, 31 Oct 2023 19:48:05 +0300 Subject: [PATCH 2/4] added pack of channel, connection events --- cmd/api/docs/docs.go | 20 ++++++++++++-- cmd/api/docs/swagger.json | 20 ++++++++++++-- cmd/api/docs/swagger.yaml | 16 ++++++++++++ internal/storage/types/event_type.go | 13 ++++++++- internal/storage/types/event_type_enum.go | 32 +++++++++++++++++++++++ 5 files changed, 96 insertions(+), 5 deletions(-) diff --git a/cmd/api/docs/docs.go b/cmd/api/docs/docs.go index b995fb22..514ace31 100644 --- a/cmd/api/docs/docs.go +++ b/cmd/api/docs/docs.go @@ -2590,7 +2590,15 @@ const docTemplate = `{ "ibc_transfer", "fungible_token_packet", "acknowledge_packet", - "update_client" + "create_client", + "update_client", + "connection_open_try", + "connection_open_init", + "connection_open_confirm", + "channel_open_try", + "channel_open_init", + "channel_open_confirm", + "channel_open_ack" ], "x-enum-varnames": [ "EventTypeUnknown", @@ -2629,7 +2637,15 @@ const docTemplate = `{ "EventTypeIbcTransfer", "EventTypeFungibleTokenPacket", "EventTypeAcknowledgePacket", - "EventTypeUpdateClient" + "EventTypeCreateClient", + "EventTypeUpdateClient", + "EventTypeConnectionOpenTry", + "EventTypeConnectionOpenInit", + "EventTypeConnectionOpenConfirm", + "EventTypeChannelOpenTry", + "EventTypeChannelOpenInit", + "EventTypeChannelOpenConfirm", + "EventTypeChannelOpenAck" ] }, "types.MsgType": { diff --git a/cmd/api/docs/swagger.json b/cmd/api/docs/swagger.json index df136cd8..6be2465a 100644 --- a/cmd/api/docs/swagger.json +++ b/cmd/api/docs/swagger.json @@ -2583,7 +2583,15 @@ "ibc_transfer", "fungible_token_packet", "acknowledge_packet", - "update_client" + "create_client", + "update_client", + "connection_open_try", + "connection_open_init", + "connection_open_confirm", + "channel_open_try", + "channel_open_init", + "channel_open_confirm", + "channel_open_ack" ], "x-enum-varnames": [ "EventTypeUnknown", @@ -2622,7 +2630,15 @@ "EventTypeIbcTransfer", "EventTypeFungibleTokenPacket", "EventTypeAcknowledgePacket", - "EventTypeUpdateClient" + "EventTypeCreateClient", + "EventTypeUpdateClient", + "EventTypeConnectionOpenTry", + "EventTypeConnectionOpenInit", + "EventTypeConnectionOpenConfirm", + "EventTypeChannelOpenTry", + "EventTypeChannelOpenInit", + "EventTypeChannelOpenConfirm", + "EventTypeChannelOpenAck" ] }, "types.MsgType": { diff --git a/cmd/api/docs/swagger.yaml b/cmd/api/docs/swagger.yaml index 5be0e069..bf97e5d1 100644 --- a/cmd/api/docs/swagger.yaml +++ b/cmd/api/docs/swagger.yaml @@ -537,7 +537,15 @@ definitions: - ibc_transfer - fungible_token_packet - acknowledge_packet + - create_client - update_client + - connection_open_try + - connection_open_init + - connection_open_confirm + - channel_open_try + - channel_open_init + - channel_open_confirm + - channel_open_ack type: string x-enum-varnames: - EventTypeUnknown @@ -576,7 +584,15 @@ definitions: - EventTypeIbcTransfer - EventTypeFungibleTokenPacket - EventTypeAcknowledgePacket + - EventTypeCreateClient - EventTypeUpdateClient + - EventTypeConnectionOpenTry + - EventTypeConnectionOpenInit + - EventTypeConnectionOpenConfirm + - EventTypeChannelOpenTry + - EventTypeChannelOpenInit + - EventTypeChannelOpenConfirm + - EventTypeChannelOpenAck types.MsgType: enum: - MsgUnknown diff --git a/internal/storage/types/event_type.go b/internal/storage/types/event_type.go index 28ff0303..6627ccfd 100644 --- a/internal/storage/types/event_type.go +++ b/internal/storage/types/event_type.go @@ -49,7 +49,18 @@ package types fungible_token_packet, acknowledge_packet, - update_client + + create_client, + update_client, + + connection_open_try, + connection_open_init, + connection_open_confirm, + + channel_open_try, + channel_open_init, + channel_open_confirm, + channel_open_ack ) */ //go:generate go-enum --marshal --sql --values diff --git a/internal/storage/types/event_type_enum.go b/internal/storage/types/event_type_enum.go index d4f508cf..48878801 100644 --- a/internal/storage/types/event_type_enum.go +++ b/internal/storage/types/event_type_enum.go @@ -85,8 +85,24 @@ const ( EventTypeFungibleTokenPacket EventType = "fungible_token_packet" // EventTypeAcknowledgePacket is a EventType of type acknowledge_packet. EventTypeAcknowledgePacket EventType = "acknowledge_packet" + // EventTypeCreateClient is a EventType of type create_client. + EventTypeCreateClient EventType = "create_client" // EventTypeUpdateClient is a EventType of type update_client. EventTypeUpdateClient EventType = "update_client" + // EventTypeConnectionOpenTry is a EventType of type connection_open_try. + EventTypeConnectionOpenTry EventType = "connection_open_try" + // EventTypeConnectionOpenInit is a EventType of type connection_open_init. + EventTypeConnectionOpenInit EventType = "connection_open_init" + // EventTypeConnectionOpenConfirm is a EventType of type connection_open_confirm. + EventTypeConnectionOpenConfirm EventType = "connection_open_confirm" + // EventTypeChannelOpenTry is a EventType of type channel_open_try. + EventTypeChannelOpenTry EventType = "channel_open_try" + // EventTypeChannelOpenInit is a EventType of type channel_open_init. + EventTypeChannelOpenInit EventType = "channel_open_init" + // EventTypeChannelOpenConfirm is a EventType of type channel_open_confirm. + EventTypeChannelOpenConfirm EventType = "channel_open_confirm" + // EventTypeChannelOpenAck is a EventType of type channel_open_ack. + EventTypeChannelOpenAck EventType = "channel_open_ack" ) var ErrInvalidEventType = errors.New("not a valid EventType") @@ -130,7 +146,15 @@ func EventTypeValues() []EventType { EventTypeIbcTransfer, EventTypeFungibleTokenPacket, EventTypeAcknowledgePacket, + EventTypeCreateClient, EventTypeUpdateClient, + EventTypeConnectionOpenTry, + EventTypeConnectionOpenInit, + EventTypeConnectionOpenConfirm, + EventTypeChannelOpenTry, + EventTypeChannelOpenInit, + EventTypeChannelOpenConfirm, + EventTypeChannelOpenAck, } } @@ -183,7 +207,15 @@ var _EventTypeValue = map[string]EventType{ "ibc_transfer": EventTypeIbcTransfer, "fungible_token_packet": EventTypeFungibleTokenPacket, "acknowledge_packet": EventTypeAcknowledgePacket, + "create_client": EventTypeCreateClient, "update_client": EventTypeUpdateClient, + "connection_open_try": EventTypeConnectionOpenTry, + "connection_open_init": EventTypeConnectionOpenInit, + "connection_open_confirm": EventTypeConnectionOpenConfirm, + "channel_open_try": EventTypeChannelOpenTry, + "channel_open_init": EventTypeChannelOpenInit, + "channel_open_confirm": EventTypeChannelOpenConfirm, + "channel_open_ack": EventTypeChannelOpenAck, } // ParseEventType attempts to convert a string to a EventType. From 20c77911f4f2a4536602c877d63d536db30bdcbf Mon Sep 17 00:00:00 2001 From: Lavysh Alexander Date: Tue, 31 Oct 2023 19:51:21 +0300 Subject: [PATCH 3/4] added connection_open_ack event --- cmd/api/docs/docs.go | 2 ++ cmd/api/docs/swagger.json | 2 ++ cmd/api/docs/swagger.yaml | 2 ++ internal/storage/types/event_type.go | 1 + internal/storage/types/event_type_enum.go | 4 ++++ 5 files changed, 11 insertions(+) diff --git a/cmd/api/docs/docs.go b/cmd/api/docs/docs.go index 514ace31..43f742cf 100644 --- a/cmd/api/docs/docs.go +++ b/cmd/api/docs/docs.go @@ -2595,6 +2595,7 @@ const docTemplate = `{ "connection_open_try", "connection_open_init", "connection_open_confirm", + "connection_open_ack", "channel_open_try", "channel_open_init", "channel_open_confirm", @@ -2642,6 +2643,7 @@ const docTemplate = `{ "EventTypeConnectionOpenTry", "EventTypeConnectionOpenInit", "EventTypeConnectionOpenConfirm", + "EventTypeConnectionOpenAck", "EventTypeChannelOpenTry", "EventTypeChannelOpenInit", "EventTypeChannelOpenConfirm", diff --git a/cmd/api/docs/swagger.json b/cmd/api/docs/swagger.json index 6be2465a..09c096b2 100644 --- a/cmd/api/docs/swagger.json +++ b/cmd/api/docs/swagger.json @@ -2588,6 +2588,7 @@ "connection_open_try", "connection_open_init", "connection_open_confirm", + "connection_open_ack", "channel_open_try", "channel_open_init", "channel_open_confirm", @@ -2635,6 +2636,7 @@ "EventTypeConnectionOpenTry", "EventTypeConnectionOpenInit", "EventTypeConnectionOpenConfirm", + "EventTypeConnectionOpenAck", "EventTypeChannelOpenTry", "EventTypeChannelOpenInit", "EventTypeChannelOpenConfirm", diff --git a/cmd/api/docs/swagger.yaml b/cmd/api/docs/swagger.yaml index bf97e5d1..ce7a5e24 100644 --- a/cmd/api/docs/swagger.yaml +++ b/cmd/api/docs/swagger.yaml @@ -542,6 +542,7 @@ definitions: - connection_open_try - connection_open_init - connection_open_confirm + - connection_open_ack - channel_open_try - channel_open_init - channel_open_confirm @@ -589,6 +590,7 @@ definitions: - EventTypeConnectionOpenTry - EventTypeConnectionOpenInit - EventTypeConnectionOpenConfirm + - EventTypeConnectionOpenAck - EventTypeChannelOpenTry - EventTypeChannelOpenInit - EventTypeChannelOpenConfirm diff --git a/internal/storage/types/event_type.go b/internal/storage/types/event_type.go index 6627ccfd..0cba70f2 100644 --- a/internal/storage/types/event_type.go +++ b/internal/storage/types/event_type.go @@ -56,6 +56,7 @@ package types connection_open_try, connection_open_init, connection_open_confirm, + connection_open_ack, channel_open_try, channel_open_init, diff --git a/internal/storage/types/event_type_enum.go b/internal/storage/types/event_type_enum.go index 48878801..9c2fa1a8 100644 --- a/internal/storage/types/event_type_enum.go +++ b/internal/storage/types/event_type_enum.go @@ -95,6 +95,8 @@ const ( EventTypeConnectionOpenInit EventType = "connection_open_init" // EventTypeConnectionOpenConfirm is a EventType of type connection_open_confirm. EventTypeConnectionOpenConfirm EventType = "connection_open_confirm" + // EventTypeConnectionOpenAck is a EventType of type connection_open_ack. + EventTypeConnectionOpenAck EventType = "connection_open_ack" // EventTypeChannelOpenTry is a EventType of type channel_open_try. EventTypeChannelOpenTry EventType = "channel_open_try" // EventTypeChannelOpenInit is a EventType of type channel_open_init. @@ -151,6 +153,7 @@ func EventTypeValues() []EventType { EventTypeConnectionOpenTry, EventTypeConnectionOpenInit, EventTypeConnectionOpenConfirm, + EventTypeConnectionOpenAck, EventTypeChannelOpenTry, EventTypeChannelOpenInit, EventTypeChannelOpenConfirm, @@ -212,6 +215,7 @@ var _EventTypeValue = map[string]EventType{ "connection_open_try": EventTypeConnectionOpenTry, "connection_open_init": EventTypeConnectionOpenInit, "connection_open_confirm": EventTypeConnectionOpenConfirm, + "connection_open_ack": EventTypeConnectionOpenAck, "channel_open_try": EventTypeChannelOpenTry, "channel_open_init": EventTypeChannelOpenInit, "channel_open_confirm": EventTypeChannelOpenConfirm, From 027d06fa374d0ee47ac0eb166a5a7d5154c71bb7 Mon Sep 17 00:00:00 2001 From: Lavysh Alexander Date: Tue, 31 Oct 2023 20:02:02 +0300 Subject: [PATCH 4/4] added write_acknowledgement and recv_packet --- cmd/api/docs/docs.go | 8 ++++++-- cmd/api/docs/swagger.json | 8 ++++++-- cmd/api/docs/swagger.yaml | 4 ++++ internal/storage/mock/address.go | 1 + internal/storage/mock/balance.go | 1 + internal/storage/mock/block.go | 1 + internal/storage/mock/block_stats.go | 1 + internal/storage/mock/constant.go | 1 + internal/storage/mock/denom_metadata.go | 1 + internal/storage/mock/event.go | 1 + internal/storage/mock/generic.go | 1 + internal/storage/mock/message.go | 1 + internal/storage/mock/namespace.go | 1 + internal/storage/mock/state.go | 1 + internal/storage/mock/stats.go | 1 + internal/storage/mock/tx.go | 1 + internal/storage/mock/validator.go | 1 + internal/storage/types/event_type.go | 5 ++++- internal/storage/types/event_type_enum.go | 8 ++++++++ pkg/node/mock/api.go | 1 + 20 files changed, 43 insertions(+), 5 deletions(-) diff --git a/cmd/api/docs/docs.go b/cmd/api/docs/docs.go index 43f742cf..d5dea296 100644 --- a/cmd/api/docs/docs.go +++ b/cmd/api/docs/docs.go @@ -2599,7 +2599,9 @@ const docTemplate = `{ "channel_open_try", "channel_open_init", "channel_open_confirm", - "channel_open_ack" + "channel_open_ack", + "recv_packet", + "write_acknowledgement" ], "x-enum-varnames": [ "EventTypeUnknown", @@ -2647,7 +2649,9 @@ const docTemplate = `{ "EventTypeChannelOpenTry", "EventTypeChannelOpenInit", "EventTypeChannelOpenConfirm", - "EventTypeChannelOpenAck" + "EventTypeChannelOpenAck", + "EventTypeRecvPacket", + "EventTypeWriteAcknowledgement" ] }, "types.MsgType": { diff --git a/cmd/api/docs/swagger.json b/cmd/api/docs/swagger.json index 09c096b2..545b4351 100644 --- a/cmd/api/docs/swagger.json +++ b/cmd/api/docs/swagger.json @@ -2592,7 +2592,9 @@ "channel_open_try", "channel_open_init", "channel_open_confirm", - "channel_open_ack" + "channel_open_ack", + "recv_packet", + "write_acknowledgement" ], "x-enum-varnames": [ "EventTypeUnknown", @@ -2640,7 +2642,9 @@ "EventTypeChannelOpenTry", "EventTypeChannelOpenInit", "EventTypeChannelOpenConfirm", - "EventTypeChannelOpenAck" + "EventTypeChannelOpenAck", + "EventTypeRecvPacket", + "EventTypeWriteAcknowledgement" ] }, "types.MsgType": { diff --git a/cmd/api/docs/swagger.yaml b/cmd/api/docs/swagger.yaml index ce7a5e24..f734e99a 100644 --- a/cmd/api/docs/swagger.yaml +++ b/cmd/api/docs/swagger.yaml @@ -547,6 +547,8 @@ definitions: - channel_open_init - channel_open_confirm - channel_open_ack + - recv_packet + - write_acknowledgement type: string x-enum-varnames: - EventTypeUnknown @@ -595,6 +597,8 @@ definitions: - EventTypeChannelOpenInit - EventTypeChannelOpenConfirm - EventTypeChannelOpenAck + - EventTypeRecvPacket + - EventTypeWriteAcknowledgement types.MsgType: enum: - MsgUnknown diff --git a/internal/storage/mock/address.go b/internal/storage/mock/address.go index 7d380590..074a326e 100644 --- a/internal/storage/mock/address.go +++ b/internal/storage/mock/address.go @@ -5,6 +5,7 @@ // // mockgen -source=address.go -destination=mock/address.go -package=mock -typed // + // Package mock is a generated GoMock package. package mock diff --git a/internal/storage/mock/balance.go b/internal/storage/mock/balance.go index 684c1bc2..eef0d935 100644 --- a/internal/storage/mock/balance.go +++ b/internal/storage/mock/balance.go @@ -5,6 +5,7 @@ // // mockgen -source=balance.go -destination=mock/balance.go -package=mock -typed // + // Package mock is a generated GoMock package. package mock diff --git a/internal/storage/mock/block.go b/internal/storage/mock/block.go index b3af1472..ccc4dc4f 100644 --- a/internal/storage/mock/block.go +++ b/internal/storage/mock/block.go @@ -5,6 +5,7 @@ // // mockgen -source=block.go -destination=mock/block.go -package=mock -typed // + // Package mock is a generated GoMock package. package mock diff --git a/internal/storage/mock/block_stats.go b/internal/storage/mock/block_stats.go index bbf39bbd..81abfe06 100644 --- a/internal/storage/mock/block_stats.go +++ b/internal/storage/mock/block_stats.go @@ -5,6 +5,7 @@ // // mockgen -source=block_stats.go -destination=mock/block_stats.go -package=mock -typed // + // Package mock is a generated GoMock package. package mock diff --git a/internal/storage/mock/constant.go b/internal/storage/mock/constant.go index ee1891af..24bd282d 100644 --- a/internal/storage/mock/constant.go +++ b/internal/storage/mock/constant.go @@ -5,6 +5,7 @@ // // mockgen -source=constant.go -destination=mock/constant.go -package=mock -typed // + // Package mock is a generated GoMock package. package mock diff --git a/internal/storage/mock/denom_metadata.go b/internal/storage/mock/denom_metadata.go index 1c9c6e60..e07c0f02 100644 --- a/internal/storage/mock/denom_metadata.go +++ b/internal/storage/mock/denom_metadata.go @@ -5,6 +5,7 @@ // // mockgen -source=denom_metadata.go -destination=mock/denom_metadata.go -package=mock -typed // + // Package mock is a generated GoMock package. package mock diff --git a/internal/storage/mock/event.go b/internal/storage/mock/event.go index 52cdd576..8c2ff172 100644 --- a/internal/storage/mock/event.go +++ b/internal/storage/mock/event.go @@ -5,6 +5,7 @@ // // mockgen -source=event.go -destination=mock/event.go -package=mock -typed // + // Package mock is a generated GoMock package. package mock diff --git a/internal/storage/mock/generic.go b/internal/storage/mock/generic.go index fa9d0e6c..16a3031a 100644 --- a/internal/storage/mock/generic.go +++ b/internal/storage/mock/generic.go @@ -5,6 +5,7 @@ // // mockgen -source=generic.go -destination=mock/generic.go -package=mock -typed // + // Package mock is a generated GoMock package. package mock diff --git a/internal/storage/mock/message.go b/internal/storage/mock/message.go index f4d418fb..f0fc3950 100644 --- a/internal/storage/mock/message.go +++ b/internal/storage/mock/message.go @@ -5,6 +5,7 @@ // // mockgen -source=message.go -destination=mock/message.go -package=mock -typed // + // Package mock is a generated GoMock package. package mock diff --git a/internal/storage/mock/namespace.go b/internal/storage/mock/namespace.go index 9c31aa3f..2a603d89 100644 --- a/internal/storage/mock/namespace.go +++ b/internal/storage/mock/namespace.go @@ -5,6 +5,7 @@ // // mockgen -source=namespace.go -destination=mock/namespace.go -package=mock -typed // + // Package mock is a generated GoMock package. package mock diff --git a/internal/storage/mock/state.go b/internal/storage/mock/state.go index 37c546da..21cc4d68 100644 --- a/internal/storage/mock/state.go +++ b/internal/storage/mock/state.go @@ -5,6 +5,7 @@ // // mockgen -source=state.go -destination=mock/state.go -package=mock -typed // + // Package mock is a generated GoMock package. package mock diff --git a/internal/storage/mock/stats.go b/internal/storage/mock/stats.go index 1d17c6ae..e2dceafd 100644 --- a/internal/storage/mock/stats.go +++ b/internal/storage/mock/stats.go @@ -5,6 +5,7 @@ // // mockgen -source=stats.go -destination=mock/stats.go -package=mock -typed // + // Package mock is a generated GoMock package. package mock diff --git a/internal/storage/mock/tx.go b/internal/storage/mock/tx.go index 88c02e45..3daa2a54 100644 --- a/internal/storage/mock/tx.go +++ b/internal/storage/mock/tx.go @@ -5,6 +5,7 @@ // // mockgen -source=tx.go -destination=mock/tx.go -package=mock -typed // + // Package mock is a generated GoMock package. package mock diff --git a/internal/storage/mock/validator.go b/internal/storage/mock/validator.go index ceb55561..d0f17023 100644 --- a/internal/storage/mock/validator.go +++ b/internal/storage/mock/validator.go @@ -5,6 +5,7 @@ // // mockgen -source=validator.go -destination=mock/validator.go -package=mock -typed // + // Package mock is a generated GoMock package. package mock diff --git a/internal/storage/types/event_type.go b/internal/storage/types/event_type.go index 0cba70f2..2dc1f6a5 100644 --- a/internal/storage/types/event_type.go +++ b/internal/storage/types/event_type.go @@ -61,7 +61,10 @@ package types channel_open_try, channel_open_init, channel_open_confirm, - channel_open_ack + channel_open_ack, + + recv_packet, + write_acknowledgement ) */ //go:generate go-enum --marshal --sql --values diff --git a/internal/storage/types/event_type_enum.go b/internal/storage/types/event_type_enum.go index 9c2fa1a8..1170999a 100644 --- a/internal/storage/types/event_type_enum.go +++ b/internal/storage/types/event_type_enum.go @@ -105,6 +105,10 @@ const ( EventTypeChannelOpenConfirm EventType = "channel_open_confirm" // EventTypeChannelOpenAck is a EventType of type channel_open_ack. EventTypeChannelOpenAck EventType = "channel_open_ack" + // EventTypeRecvPacket is a EventType of type recv_packet. + EventTypeRecvPacket EventType = "recv_packet" + // EventTypeWriteAcknowledgement is a EventType of type write_acknowledgement. + EventTypeWriteAcknowledgement EventType = "write_acknowledgement" ) var ErrInvalidEventType = errors.New("not a valid EventType") @@ -158,6 +162,8 @@ func EventTypeValues() []EventType { EventTypeChannelOpenInit, EventTypeChannelOpenConfirm, EventTypeChannelOpenAck, + EventTypeRecvPacket, + EventTypeWriteAcknowledgement, } } @@ -220,6 +226,8 @@ var _EventTypeValue = map[string]EventType{ "channel_open_init": EventTypeChannelOpenInit, "channel_open_confirm": EventTypeChannelOpenConfirm, "channel_open_ack": EventTypeChannelOpenAck, + "recv_packet": EventTypeRecvPacket, + "write_acknowledgement": EventTypeWriteAcknowledgement, } // ParseEventType attempts to convert a string to a EventType. diff --git a/pkg/node/mock/api.go b/pkg/node/mock/api.go index da0d6c19..9024b77b 100644 --- a/pkg/node/mock/api.go +++ b/pkg/node/mock/api.go @@ -5,6 +5,7 @@ // // mockgen -source=api.go -destination=mock/api.go -package=mock -typed // + // Package mock is a generated GoMock package. package mock