Skip to content

Ethereum API: Add CORS settings#90

Merged
sanderpick merged 2 commits intodevelopfrom
sander/ethapi-cors2
Jun 11, 2024
Merged

Ethereum API: Add CORS settings#90
sanderpick merged 2 commits intodevelopfrom
sander/ethapi-cors2

Conversation

@sanderpick
Copy link
Copy Markdown
Contributor

The core changes are copied from here: consensus-shipyard/ipc#1021. The upstream PR has some settings tests. I didn't add those here to reduce future merge conflicts.

This also includes some infra script wiring to expose the http auth token and max cache blocks.

Supersedes #71

Fixes #80

Signed-off-by: Sander Pick <sanderpick@gmail.com>
Signed-off-by: Sander Pick <sanderpick@gmail.com>
@sanderpick sanderpick force-pushed the sander/ethapi-cors2 branch from 8a50873 to 0c85f48 Compare June 10, 2024 15:46
@sanderpick sanderpick requested a review from avichalp June 10, 2024 16:04
TOPDOWN_MAX_PROPOSAL_RANGE = { value = "100", condition = { env_not_set = [
"TOPDOWN_MAX_PROPOSAL_RANGE",
] } }
TOPDOWN_MAX_CACHE_BLOCKS = { value = "20000", condition = { env_not_set = [
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Is this being used to minimize the RPC calls?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

ah no, this is unrelated... i added it when exposing adding parent auth token. it exposes the ability to set how many blocks of history can be used in the parent topdown syncer. https://github.com/amazingdatamachine/ipc/blob/d720e6bf2b73017c89d575f6b62580706f7b572f/fendermint/vm/topdown/src/lib.rs#L58

Copy link
Copy Markdown
Collaborator

@avichalp avichalp left a comment

Choose a reason for hiding this comment

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

Looks good

@sanderpick sanderpick merged commit 588813f into develop Jun 11, 2024
@sanderpick sanderpick deleted the sander/ethapi-cors2 branch June 11, 2024 14:49
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.

Ethereum API: Allow all CORS

2 participants