Skip to content

Commit

Permalink
[INTAUTO-308] - Adding Solana specific chain client and state (#15576)
Browse files Browse the repository at this point in the history
  • Loading branch information
pablolagreca authored Dec 12, 2024
1 parent 5083d47 commit 1e87a19
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 2 deletions.
6 changes: 6 additions & 0 deletions deployment/ccip/changeset/solana_state.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
package changeset

// SolChainState holds a Go binding for all the currently deployed CCIP programs
// on a chain. If a binding is nil, it means here is no such contract on the chain.
type SolCCIPChainState struct {
}
3 changes: 2 additions & 1 deletion deployment/ccip/changeset/state.go
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,8 @@ type CCIPOnChainState struct {
// Populated go bindings for the appropriate version for all contracts.
// We would hold 2 versions of each contract here. Once we upgrade we can phase out the old one.
// When generating bindings, make sure the package name corresponds to the version.
Chains map[uint64]CCIPChainState
Chains map[uint64]CCIPChainState
SolChains map[uint64]SolCCIPChainState
}

func (s CCIPOnChainState) View(chains []uint64) (map[string]view.ChainView, error) {
Expand Down
2 changes: 1 addition & 1 deletion deployment/environment.go
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ type Environment struct {
Logger logger.Logger
ExistingAddresses AddressBook
Chains map[uint64]Chain
SolChains map[uint64]SolChain
NodeIDs []string
Offchain OffchainClient
GetContext func() context.Context
Expand Down Expand Up @@ -331,7 +332,6 @@ func NodeInfo(nodeIDs []string, oc NodeChainConfigsLister) (Nodes, error) {
Enabled: 1,
Ids: nodeIDs,
}

}
nodesFromJD, err := oc.ListNodes(context.Background(), &nodev1.ListNodesRequest{
Filter: filter,
Expand Down
5 changes: 5 additions & 0 deletions deployment/solana_chain.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
package deployment

// SolChain represents a Solana chain.
type SolChain struct {
}

0 comments on commit 1e87a19

Please sign in to comment.