More Abacus -> Hyperlane renames (#1330)

pull/1333/head^2
Trevor Porter 2 years ago committed by GitHub
parent f15632f26c
commit bea8903982
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 12
      rust/README.md
  2. 15
      rust/agents/scraper/src/settings.rs
  3. 6
      rust/hyperlane-base/src/settings/mod.rs
  4. 4
      rust/hyperlane-core/src/types/message.rs
  5. 4
      solidity/contracts/test/TestHyperlaneConnectionClient.sol
  6. 4
      solidity/contracts/test/TestRouter.sol
  7. 2
      solidity/update_abis.sh
  8. 34
      tools/grafana/validator-dashboard.json
  9. 2
      typescript/infra/helm/helloworld-kathy/templates/external-secret.yaml
  10. 2
      typescript/infra/helm/key-funder/templates/env-var-external-secret.yaml
  11. 6
      typescript/utils/src/types.ts
  12. 2
      typescript/utils/src/utils.ts

@ -62,22 +62,22 @@ We use the tokio async runtime environment. Please see the docs
### Repo layout
- `abacus-base`
- lowest dependency abacus utilities
- `hyperlane-base`
- lowest dependency hyperlane utilities
- contains shared utilities for building off-chain agents
- this includes
- trait implementations for different chains
- shared configuration file formats
- basic setup for an off-chain agent
- `abacus-core`
- depends on abacus-base
- `hyperlane-core`
- depends on hyperlane-base
- contains implementations of core primitives
- this includes
- traits (interfaces) for the on-chain contracts
- model implementations of the contracts in rust
- merkle tree implementations (for provers)
- `chains/abacus-ethereum`
- depends on abacus-core (and transitively abacus-base)
- `chains/hyperlane-ethereum`
- depends on hyperlane-core (and transitively hyperlane-base)
- interfaces to the ethereum contracts
- `agents`
- each of the off-chain agents implemented thus far

@ -2,20 +2,6 @@ use eyre::WrapErr;
use std::collections::HashMap;
use std::env;
<<<<<<< HEAD
use hyperlane_base::chains::IndexSettings;
use hyperlane_base::decl_settings;
use hyperlane_base::ChainSetup;
// TODO: Make it so the inherited settings better communicate that the `outbox`
// config is not needed for the scraper.
decl_settings!(Scraper {
/// Configurations for contracts on the outbox chains
outboxes: HashMap<String, ChainSetup>,
/// Index settings by chain
indexes: HashMap<String, IndexSettings>,
});
=======
use hyperlane_base::load_settings_object;
use hyperlane_base::{AgentSettings, DomainSettings, NewFromAgentSettings};
@ -97,4 +83,3 @@ impl NewFromAgentSettings for ScraperSettings {
})
}
}
>>>>>>> main

@ -598,9 +598,9 @@ impl Settings {
Config::builder()
.add_source(File::with_name("config/default"))
.add_source(File::with_name(&env_path))
// Add in settings from the environment (with a prefix of ABACUS)
// Eg.. `ABACUS_DEBUG=1 would set the `debug` key
.add_source(Environment::with_prefix("ABACUS"))
// Add in settings from the environment (with a prefix of HYPERLANE)
// Eg.. `HYPERLANE_DEBUG=1 would set the `debug` key
.add_source(Environment::with_prefix("HYPERLANE"))
.build()?
.try_deserialize()
}

@ -3,7 +3,7 @@ use sha3::{Digest, Keccak256};
use crate::{Decode, Encode, HyperlaneError};
const ABACUS_MESSAGE_PREFIX_LEN: usize = 77;
const HYPERLANE_MESSAGE_PREFIX_LEN: usize = 77;
/// A Stamped message that has been committed at some nonce
pub type RawHyperlaneMessage = Vec<u8>;
@ -74,7 +74,7 @@ impl Encode for HyperlaneMessage {
writer.write_all(&self.destination.to_be_bytes())?;
writer.write_all(self.recipient.as_ref())?;
writer.write_all(&self.body)?;
Ok(ABACUS_MESSAGE_PREFIX_LEN + self.body.len())
Ok(HYPERLANE_MESSAGE_PREFIX_LEN + self.body.len())
}
}

@ -4,8 +4,8 @@ import {HyperlaneConnectionClient} from "../HyperlaneConnectionClient.sol";
import {IMailbox} from "../../interfaces/IMailbox.sol";
contract TestHyperlaneConnectionClient is HyperlaneConnectionClient {
function initialize(address _abacusConnectionManager) external initializer {
__HyperlaneConnectionClient_initialize(_abacusConnectionManager);
function initialize(address _mailbox) external initializer {
__HyperlaneConnectionClient_initialize(_mailbox);
}
function localDomain() external view returns (uint32) {

@ -6,8 +6,8 @@ import "../Router.sol";
contract TestRouter is Router {
event InitializeOverload();
function initialize(address _abacusConnectionManager) external initializer {
__Router_initialize(_abacusConnectionManager);
function initialize(address _mailbox) external initializer {
__Router_initialize(_mailbox);
emit InitializeOverload();
}

@ -4,7 +4,7 @@ copy() {
# Optionally allow path to be passed in, and extract the contract name
# as the string following the last instance of `/`
CONTRACT_NAME="${1##*/}"
jq .abi < artifacts/contracts/"$1".sol/"$CONTRACT_NAME".json > ../rust/chains/abacus-ethereum/abis/"$CONTRACT_NAME".abi.json
jq .abi < artifacts/contracts/"$1".sol/"$CONTRACT_NAME".json > ../rust/chains/hyperlane-ethereum/abis/"$CONTRACT_NAME".abi.json
}
copy Inbox && copy Outbox && copy validator-manager/InboxValidatorManager && copy InterchainGasPaymaster

@ -122,7 +122,7 @@
"uid": "<prometheus>"
},
"editorMode": "code",
"expr": "1 / avg by(chain)(rate(abacus_block_height{abacus_deployment=~\"$deployment\",chain=~\"$chain\",agent=\"validator\"}[$__rate_interval]))",
"expr": "1 / avg by(chain)(rate(hyperlane_block_height{hyperlane_deployment=~\"$deployment\",chain=~\"$chain\",agent=\"validator\"}[$__rate_interval]))",
"interval": "$bucket",
"legendFormat": "__auto",
"range": true,
@ -184,7 +184,7 @@
"uid": "<prometheus>"
},
"editorMode": "code",
"expr": "max(abacus_block_height{agent=\"validator\", }) by (chain)",
"expr": "max(hyperlane_block_height{agent=\"validator\", }) by (chain)",
"legendFormat": "__auto",
"range": true,
"refId": "A"
@ -246,7 +246,7 @@
},
"editorMode": "code",
"exemplar": false,
"expr": "max by(chain) (abacus_latest_checkpoint{agent=\"validator\", chain=~\"$chain\", phase=\"validator_processed\"})",
"expr": "max by(chain) (hyperlane_latest_checkpoint{agent=\"validator\", chain=~\"$chain\", phase=\"validator_processed\"})",
"instant": false,
"interval": "$bucket",
"legendFormat": "__auto",
@ -336,7 +336,7 @@
"uid": "<prometheus>"
},
"editorMode": "code",
"expr": "max by (chain)(abacus_latest_checkpoint{agent=\"validator\", chain=~\"$chain\", phase=\"validator_processed\"}) - max by (chain)(abacus_latest_checkpoint{agent=\"validator\", chain=~\"$chain\", phase=\"validator_processed\"} offset $bucket)",
"expr": "max by (chain)(hyperlane_latest_checkpoint{agent=\"validator\", chain=~\"$chain\", phase=\"validator_processed\"}) - max by (chain)(hyperlane_latest_checkpoint{agent=\"validator\", chain=~\"$chain\", phase=\"validator_processed\"} offset $bucket)",
"interval": "$bucket",
"legendFormat": "__auto",
"range": true,
@ -427,7 +427,7 @@
"uid": "<prometheus>"
},
"editorMode": "code",
"expr": "max by(chain) (abacus_latest_checkpoint{agent=\"validator\", chain=~\"$chain\", phase=\"validator_observed\"}) - min by (chain)(abacus_latest_checkpoint{agent=\"validator\", chain=~\"$chain\", phase=\"validator_observed\"})",
"expr": "max by(chain) (hyperlane_latest_checkpoint{agent=\"validator\", chain=~\"$chain\", phase=\"validator_observed\"}) - min by (chain)(hyperlane_latest_checkpoint{agent=\"validator\", chain=~\"$chain\", phase=\"validator_observed\"})",
"interval": "$bucket",
"legendFormat": "__auto",
"range": true,
@ -527,7 +527,7 @@
},
"editorMode": "code",
"exemplar": false,
"expr": "max by(chain) (abacus_latest_checkpoint{agent=\"validator\", chain=~\"$chain\", phase=\"validator_observed\"}) - min by(chain) (abacus_latest_checkpoint{agent=\"validator\", chain=~\"$chain\", phase=\"validator_processed\"})",
"expr": "max by(chain) (hyperlane_latest_checkpoint{agent=\"validator\", chain=~\"$chain\", phase=\"validator_observed\"}) - min by(chain) (hyperlane_latest_checkpoint{agent=\"validator\", chain=~\"$chain\", phase=\"validator_processed\"})",
"instant": false,
"interval": "$bucket",
"legendFormat": "__auto",
@ -616,7 +616,7 @@
},
"editorMode": "code",
"exemplar": false,
"expr": "abacus_outbox_state{agent=\"validator\", }",
"expr": "hyperlane_outbox_state{agent=\"validator\", }",
"instant": true,
"legendFormat": "{{chain}} @ {{instance}}",
"range": false,
@ -709,7 +709,7 @@
"uid": "<prometheus>"
},
"editorMode": "code",
"expr": "sum by (chain)(increase(abacus_contract_call_count{ chain=~\"$chain\", agent=\"validator\"}[$bucket]))",
"expr": "sum by (chain)(increase(hyperlane_contract_call_count{ chain=~\"$chain\", agent=\"validator\"}[$bucket]))",
"interval": "$bucket",
"legendFormat": "{{chain}}",
"range": true,
@ -802,7 +802,7 @@
"uid": "<prometheus>"
},
"editorMode": "code",
"expr": "sum by (chain) (rate(abacus_contract_call_count{agent=\"validator\"}[$__rate_interval]))",
"expr": "sum by (chain) (rate(hyperlane_contract_call_count{agent=\"validator\"}[$__rate_interval]))",
"interval": "$bucket",
"legendFormat": "__auto",
"range": true,
@ -895,7 +895,7 @@
"uid": "<prometheus>"
},
"editorMode": "code",
"expr": "avg by (chain)(rate(abacus_contract_call_count{agent=\"validator\",chain=~\"$chain\"}[$__rate_interval]) - rate(abacus_contract_call_duration_seconds{agent=\"validator\",chain=~\"$chain\"}[$__rate_interval]))",
"expr": "avg by (chain)(rate(hyperlane_contract_call_count{agent=\"validator\",chain=~\"$chain\"}[$__rate_interval]) - rate(hyperlane_contract_call_duration_seconds{agent=\"validator\",chain=~\"$chain\"}[$__rate_interval]))",
"interval": "$bucket",
"legendFormat": "{{chain}}",
"range": true,
@ -997,7 +997,7 @@
"uid": "<prometheus>"
},
"editorMode": "code",
"expr": "sum by (contract_name, function_name)(increase(abacus_contract_call_count{ chain=~\"$chain\", agent=\"validator\"}[$bucket]))",
"expr": "sum by (contract_name, function_name)(increase(hyperlane_contract_call_count{ chain=~\"$chain\", agent=\"validator\"}[$bucket]))",
"interval": "$bucket",
"legendFormat": "{{contract_name}}::{{function_name}}",
"range": true,
@ -1089,7 +1089,7 @@
"uid": "<prometheus>"
},
"editorMode": "code",
"expr": "sum by (function_name,contract_name)(rate(abacus_contract_call_count{agent=\"validator\",chain=~\"$chain\"}[$__rate_interval]))",
"expr": "sum by (function_name,contract_name)(rate(hyperlane_contract_call_count{agent=\"validator\",chain=~\"$chain\"}[$__rate_interval]))",
"interval": "$bucket",
"legendFormat": "{{contract_name}}::{{function_name}}",
"range": true,
@ -1181,7 +1181,7 @@
"uid": "<prometheus>"
},
"editorMode": "code",
"expr": "avg by (function_name,contract_name)(rate(abacus_contract_call_count{agent=\"validator\",chain=~\"$chain\"}[$__rate_interval]) - rate(abacus_contract_call_duration_seconds{agent=\"validator\",chain=~\"$chain\"}[$__rate_interval]))",
"expr": "avg by (function_name,contract_name)(rate(hyperlane_contract_call_count{agent=\"validator\",chain=~\"$chain\"}[$__rate_interval]) - rate(hyperlane_contract_call_duration_seconds{agent=\"validator\",chain=~\"$chain\"}[$__rate_interval]))",
"interval": "$bucket",
"legendFormat": "{{contract_name}}::{{function_name}}",
"range": true,
@ -1279,7 +1279,7 @@
"type": "prometheus",
"uid": "<prometheus>"
},
"definition": "label_values(abacus_block_height, abacus_deployment)",
"definition": "label_values(hyperlane_block_height, hyperlane_deployment)",
"hide": 0,
"includeAll": false,
"label": "Deployment",
@ -1287,7 +1287,7 @@
"name": "deployment",
"options": [],
"query": {
"query": "label_values(abacus_block_height, abacus_deployment)",
"query": "label_values(hyperlane_block_height, hyperlane_deployment)",
"refId": "StandardVariableQuery"
},
"refresh": 1,
@ -1310,7 +1310,7 @@
"type": "prometheus",
"uid": "<prometheus>"
},
"definition": "label_values(abacus_block_height{abacus_deployment=~\"$deployment\"}, chain)",
"definition": "label_values(hyperlane_block_height{hyperlane_deployment=~\"$deployment\"}, chain)",
"hide": 0,
"includeAll": true,
"label": "Chain",
@ -1318,7 +1318,7 @@
"name": "chain",
"options": [],
"query": {
"query": "label_values(abacus_block_height{abacus_deployment=~\"$deployment\"}, chain)",
"query": "label_values(hyperlane_block_height{hyperlane_deployment=~\"$deployment\"}, chain)",
"refId": "StandardVariableQuery"
},
"refresh": 1,

@ -21,7 +21,7 @@ spec:
update-on-redeploy: "{{ now }}"
data:
GCP_SECRET_OVERRIDES_ENABLED: "true"
GCP_SECRET_OVERRIDE_ABACUS_{{ .Values.hyperlane.runEnv | upper }}_KEY_DEPLOYER: {{ print "'{{ .deployer_key | toString }}'" }}
GCP_SECRET_OVERRIDE_HYPERLANE_{{ .Values.hyperlane.runEnv | upper }}_KEY_DEPLOYER: {{ print "'{{ .deployer_key | toString }}'" }}
{{/*
* For each network, create an environment variable with the RPC endpoint.
* The templating of external-secrets will use the data section below to know how

@ -21,7 +21,7 @@ spec:
update-on-redeploy: "{{ now }}"
data:
GCP_SECRET_OVERRIDES_ENABLED: "true"
GCP_SECRET_OVERRIDE_ABACUS_{{ .Values.hyperlane.runEnv | upper }}_KEY_DEPLOYER: {{ print "'{{ .deployer_key | toString }}'" }}
GCP_SECRET_OVERRIDE_HYPERLANE_{{ .Values.hyperlane.runEnv | upper }}_KEY_DEPLOYER: {{ print "'{{ .deployer_key | toString }}'" }}
{{/*
* For each network, create an environment variable with the RPC endpoint.
* The templating of external-secrets will use the data section below to know how

@ -35,12 +35,6 @@ export type CallData = {
data: string;
};
export enum AbacusState {
UNINITIALIZED = 0,
ACTIVE,
FAILED,
}
export enum MessageStatus {
NONE = 0,
PROCESSED,

@ -149,7 +149,7 @@ export function messageId(message: HexString): string {
}
/**
* Parse a serialized Abacus message from raw bytes.
* Parse a serialized Hyperlane message from raw bytes.
*
* @param message
* @returns

Loading…
Cancel
Save