Skip to content

Commit

Permalink
Merge pull request #114 from NextDotID/fix/upstream-dotbit-farcaster
Browse files Browse the repository at this point in the history
LGTM for me. Merge to staging server for testing for now.
  • Loading branch information
nykma authored Dec 13, 2023
2 parents c6b4521 + a088b13 commit 15d90fb
Show file tree
Hide file tree
Showing 11 changed files with 680 additions and 114 deletions.
29 changes: 21 additions & 8 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ surf = "2.0.0"
reqwest = { version = "^0.11", features = ["json", "blocking"] }
isahc = "1.7.2"
async-recursion = "1.0.4"
regex = "1.10.2"

[dev-dependencies]
fake = { version = "2.4", features = ["uuid", "chrono"] }
Expand Down
4 changes: 4 additions & 0 deletions config/main.sample.toml
Original file line number Diff line number Diff line change
Expand Up @@ -46,5 +46,9 @@ token = "4cb4358d-ce8b-4bf5-fill-yourstokenid"
[upstream.datamgr_api]
url = "https://cryptodata.store"

[upstream.warpcast_api]
url = "https://api.warpcast.com"
token = "MK-ABC123..."

[upstream.spaceid_api]
url = "https://api.prd.space.id"
7 changes: 7 additions & 0 deletions src/config/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ pub struct Upstream {
pub lens_api: ConfigLensAPI,
pub unstoppable_api: ConfigUnstoppableDomainsAPI,
pub datamgr_api: ConfigDataMgrAPI,
pub warpcast_api: ConfigWarpcastAPI,
pub spaceid_api: ConfigSpaceIdAPI,
}

Expand Down Expand Up @@ -122,6 +123,12 @@ pub struct ConfigDataMgrAPI {
pub url: String,
}

#[derive(Clone, Deserialize, Default)]
pub struct ConfigWarpcastAPI {
pub url: String,
pub token: String,
}

#[derive(Clone, Deserialize, Default)]
pub struct ConfigSpaceIdAPI {
pub url: String,
Expand Down
2 changes: 1 addition & 1 deletion src/tigergraph/vertex/identity.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1058,7 +1058,7 @@ impl BatchFn<String, Option<IdentityRecord>> for OwnerLoadFn {
#[async_trait::async_trait]
impl BatchFn<String, Option<bool>> for NeighborReverseLoadFn {
async fn load(&mut self, ids: &[String]) -> HashMap<String, Option<bool>> {
tracing::info!("Loading ids for neighbor_reverse_by_ids {:?}", ids);
trace!("Loading ids for neighbor_reverse_by_ids {:?}", ids);
let records = get_neighbor_reverse_by_ids(&self.client, ids.to_vec()).await;
match records {
Ok(records) => records,
Expand Down
Loading

0 comments on commit 15d90fb

Please sign in to comment.