Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GCP storage #339

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open

Conversation

mhalambek
Copy link
Contributor

No description provided.

Copy link
Member

@khorolets khorolets left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mhalambek thank you for the PR. I see the point and fully support this feature (I was thinking about it for a long time).

In order to merge this feature into the Indexer for Explorer I need you to change a few things here and there, I've left the comments. Feel free to ping me if you have questions.

@@ -81,6 +97,21 @@ impl Opts {
match &self.chain_id {
ChainId::Mainnet(_) => config_builder.mainnet(),
ChainId::Testnet(_) => config_builder.testnet(),
ChainId::Custom(_) => {
println!("aws: region {}", self.region);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
println!("aws: region {}", self.region);
tracing::debug!(
target: crate::INDEXER_FOR_EXPLORER,
"aws: region {}",
self.region,
);

@@ -35,3 +37,4 @@ near-jsonrpc-client = "0.4.0-beta.0"
near-lake-framework = "0.5.2"

explorer-database = { path = "../database" }
http = "0.2.8"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would you mind moving it before the itertools declarations, please? This is the place for path-dependencies

@@ -34,6 +36,15 @@ pub(crate) struct Opts {
/// Port to enable metrics/health service
#[clap(long, short, env, default_value_t = 3030)]
pub port: u16,
/// S3 bucket name
#[clap(long)]
pub bucket: String,
Copy link
Member

@khorolets khorolets Feb 1, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This makes these parameters required which is not a desired behavior for us. It's actually required only when the custom subcommand is fired.

I see two possible options here:

  1. Make these Option<String> and add corresponding checks when the Custom is provided and print relevant errors about missing parameters.
  2. Make a copy of the StartOptions and require these parameters there.

I guess the second variant is preferable.

@khorolets
Copy link
Member

khorolets commented Apr 24, 2023

@mhalambek hey there! FYI we have implemented the store-genesis feature (your #340 by #342).

Do you have the capacity and desire to pick this PR again and finish it?

@mhalambek mhalambek force-pushed the mhala/gcp-storage branch 3 times, most recently from 9465ab8 to 96ac995 Compare May 3, 2023 22:01
@mhalambek mhalambek force-pushed the mhala/gcp-storage branch from 297147f to 96ac995 Compare May 10, 2023 12:04
@medicz medicz force-pushed the mhala/gcp-storage branch from 96ac995 to 657e4bc Compare December 8, 2023 16:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants