Skip to content

Commit c07d968

Browse files
feat(ibc-union): evm: index important event fields
1 parent 2f4920a commit c07d968

File tree

3 files changed

+27
-25
lines changed

3 files changed

+27
-25
lines changed

evm/contracts/core/02-client/IBCClient.sol

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,12 @@ import "../24-host/IBCCommitment.sol";
77
import "../02-client/IIBCClient.sol";
88

99
library IBCClientLib {
10-
event RegisterClient(string clientType, address clientAddress);
10+
event RegisterClient(string indexed clientType, address clientAddress);
1111
event CreateClient(
12-
string clientType, uint32 clientId, string counterpartyChainId
12+
string indexed clientType, uint32 indexed clientId, string counterpartyChainId
1313
);
14-
event UpdateClient(uint32 clientId, uint64 height);
15-
event Misbehaviour(uint32 clientId);
14+
event UpdateClient(uint32 indexed clientId, uint64 height);
15+
event Misbehaviour(uint32 indexed clientId);
1616
}
1717

1818
/**

evm/contracts/core/03-connection/IBCConnection.sol

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,23 +7,25 @@ import "../03-connection/IIBCConnection.sol";
77

88
library IBCConnectionLib {
99
event ConnectionOpenInit(
10-
uint32 connectionId, uint32 clientId, uint32 counterpartyClientId
10+
uint32 indexed connectionId,
11+
uint32 indexed clientId,
12+
uint32 counterpartyClientId
1113
);
1214
event ConnectionOpenTry(
13-
uint32 connectionId,
14-
uint32 clientId,
15+
uint32 indexed connectionId,
16+
uint32 indexed clientId,
1517
uint32 counterpartyClientId,
1618
uint32 counterpartyConnectionId
1719
);
1820
event ConnectionOpenAck(
19-
uint32 connectionId,
20-
uint32 clientId,
21+
uint32 indexed connectionId,
22+
uint32 indexed clientId,
2123
uint32 counterpartyClientId,
2224
uint32 counterpartyConnectionId
2325
);
2426
event ConnectionOpenConfirm(
25-
uint32 connectionId,
26-
uint32 clientId,
27+
uint32 indexed connectionId,
28+
uint32 indexed clientId,
2729
uint32 counterpartyClientId,
2830
uint32 counterpartyConnectionId
2931
);

evm/contracts/core/04-channel/IBCChannel.sol

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -11,43 +11,43 @@ import "../../lib/Hex.sol";
1111

1212
library IBCChannelLib {
1313
event ChannelOpenInit(
14-
address portId,
15-
uint32 channelId,
14+
address indexed portId,
15+
uint32 indexed channelId,
1616
bytes counterpartyPortId,
1717
uint32 connectionId,
18-
string version
18+
string indexed version
1919
);
2020
event ChannelOpenTry(
21-
address portId,
22-
uint32 channelId,
21+
address indexed portId,
22+
uint32 indexed channelId,
2323
bytes counterpartyPortId,
2424
uint32 counterpartyChannelId,
2525
uint32 connectionId,
26-
string counterpartyVersion
26+
string indexed counterpartyVersion
2727
);
2828
event ChannelOpenAck(
29-
address portId,
30-
uint32 channelId,
29+
address indexed portId,
30+
uint32 indexed channelId,
3131
bytes counterpartyPortId,
3232
uint32 counterpartyChannelId,
3333
uint32 connectionId
3434
);
3535
event ChannelOpenConfirm(
36-
address portId,
37-
uint32 channelId,
36+
address indexed portId,
37+
uint32 indexed channelId,
3838
bytes counterpartyPortId,
3939
uint32 counterpartyChannelId,
4040
uint32 connectionId
4141
);
4242
event ChannelCloseInit(
43-
address portId,
44-
uint32 channelId,
43+
address indexed portId,
44+
uint32 indexed channelId,
4545
bytes counterpartyPortId,
4646
uint32 counterpartyChannelId
4747
);
4848
event ChannelCloseConfirm(
49-
address portId,
50-
uint32 channelId,
49+
address indexed portId,
50+
uint32 indexed channelId,
5151
bytes counterpartyPortId,
5252
uint32 counterpartyChannelId
5353
);

0 commit comments

Comments
 (0)