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

[GraphQL] generate-config sub-command #18336

Merged
merged 1 commit into from
Aug 19, 2024
Merged

Conversation

amnn
Copy link
Member

@amnn amnn commented Jun 20, 2024

Description

Add a command for generating a config TOML file for the GraphQL service with all its parameters set to their default values. (We used to have a similar command for the YAML file which we weren't using, but we still use the TOML file).

Test plan

cargo run --bin sui-graphql-rpc -- generate-config /tmp/config.toml

Stack


Release notes

Check each box that your changes affect. If none of the boxes relate to your changes, release notes aren't required.

For each box you select, include information after the relevant heading that describes the impact of your changes that a user might notice and any actions they must take to implement updates.

  • Protocol:
  • Nodes (Validators and Full nodes):
  • Indexer:
  • JSON-RPC:
  • GraphQL: New sub-command for sui-graphql-rpc, generate-config for creating a TOML config with all default values set.
  • CLI:
  • Rust SDK:

@amnn amnn self-assigned this Jun 20, 2024
Copy link

vercel bot commented Jun 20, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
sui-docs 🛑 Canceled (Inspect) Aug 19, 2024 11:08am
3 Skipped Deployments
Name Status Preview Comments Updated (UTC)
multisig-toolkit ⬜️ Ignored (Inspect) Visit Preview Aug 19, 2024 11:08am
sui-kiosk ⬜️ Ignored (Inspect) Visit Preview Aug 19, 2024 11:08am
sui-typescript-docs ⬜️ Ignored (Inspect) Visit Preview Aug 19, 2024 11:08am

@amnn amnn requested a review from a team as a code owner August 19, 2024 10:33
Base automatically changed from amnn/gql-schema to amnn/gql-pkg-v-page August 19, 2024 10:41
@amnn amnn force-pushed the amnn/gql-pkg-v-page branch 2 times, most recently from 6538bcd to fb94724 Compare August 19, 2024 10:50
Base automatically changed from amnn/gql-pkg-v-page to amnn/gql-obj-versions August 19, 2024 10:50
## Description

Add a command for generating a `config.toml` file for the GraphQL
service with all its parameters set to their default values.

## Test plan

```
cargo run --bin sui-graphql-rpc -- generate-config /tmp/config.toml
```
@amnn amnn merged commit bec3dd8 into amnn/gql-obj-versions Aug 19, 2024
10 of 14 checks passed
@amnn amnn deleted the amnn/gql-gen-cfg branch August 19, 2024 10:52
amnn added a commit that referenced this pull request Aug 19, 2024
## Description

Replace the original implementation of the dump-packages command (which
requires access to an indexer database) with an implementation that
reads from a GraphQL service. The former is not readily accessible, but
the latter should be.

The new tool is also able to run incrementally: Fetching only packages
created before a certain checkpoint, or pick up where a previous
invocation took off to fetch new packages that were introduced since.

## Test plan

Ran a test invocation, on our experimental read replica. With a max page
size of 200, I was able to fetch 17000 packages (all the packages at the
time the read replica was created) in 3 minutes.

## Stack

- #17543
- #17692 
- #17693 
- #17696 
- #18287 
- #18288 
- #18336

---

## Release notes

Check each box that your changes affect. If none of the boxes relate to
your changes, release notes aren't required.

For each box you select, include information after the relevant heading
that describes the impact of your changes that a user might notice and
any actions they must take to implement updates.

- [ ] Protocol: 
- [ ] Nodes (Validators and Full nodes): 
- [ ] Indexer: 
- [ ] JSON-RPC: 
- [ ] GraphQL: 
- [ ] CLI: 
- [ ] Rust SDK:
amnn added a commit that referenced this pull request Aug 20, 2024
## Description

Add a command for generating a config TOML file for the GraphQL service
with all its parameters set to their default values. (We used to have a
similar command for the YAML file which we weren't using, but we still
use the TOML file).

## Test plan

```
cargo run --bin sui-graphql-rpc -- generate-config /tmp/config.toml
```

## Stack

- #17543
- #17692 
- #17693 
- #17696 
- #18287 
- #18288 

---

## Release notes

Check each box that your changes affect. If none of the boxes relate to
your changes, release notes aren't required.

For each box you select, include information after the relevant heading
that describes the impact of your changes that a user might notice and
any actions they must take to implement updates.

- [ ] Protocol: 
- [ ] Nodes (Validators and Full nodes): 
- [ ] Indexer: 
- [ ] JSON-RPC: 
- [x] GraphQL: New sub-command for `sui-graphql-rpc`, `generate-config`
for creating a TOML config with all default values set.
- [ ] CLI: 
- [ ] Rust SDK:
amnn added a commit that referenced this pull request Aug 20, 2024
## Description

Replace the original implementation of the dump-packages command (which
requires access to an indexer database) with an implementation that
reads from a GraphQL service. The former is not readily accessible, but
the latter should be.

The new tool is also able to run incrementally: Fetching only packages
created before a certain checkpoint, or pick up where a previous
invocation took off to fetch new packages that were introduced since.

## Test plan

Ran a test invocation, on our experimental read replica. With a max page
size of 200, I was able to fetch 17000 packages (all the packages at the
time the read replica was created) in 3 minutes.

## Stack

- #17543
- #17692 
- #17693 
- #17696 
- #18287 
- #18288 
- #18336

---

## Release notes

Check each box that your changes affect. If none of the boxes relate to
your changes, release notes aren't required.

For each box you select, include information after the relevant heading
that describes the impact of your changes that a user might notice and
any actions they must take to implement updates.

- [ ] Protocol: 
- [ ] Nodes (Validators and Full nodes): 
- [ ] Indexer: 
- [ ] JSON-RPC: 
- [ ] GraphQL: 
- [ ] CLI: 
- [ ] Rust SDK:
amnn added a commit that referenced this pull request Aug 20, 2024
## Description

Add a command for generating a config TOML file for the GraphQL service
with all its parameters set to their default values. (We used to have a
similar command for the YAML file which we weren't using, but we still
use the TOML file).

## Test plan

```
cargo run --bin sui-graphql-rpc -- generate-config /tmp/config.toml
```

## Stack

- #17543
- #17692 
- #17693 
- #17696 
- #18287 
- #18288 

---

## Release notes

Check each box that your changes affect. If none of the boxes relate to
your changes, release notes aren't required.

For each box you select, include information after the relevant heading
that describes the impact of your changes that a user might notice and
any actions they must take to implement updates.

- [ ] Protocol: 
- [ ] Nodes (Validators and Full nodes): 
- [ ] Indexer: 
- [ ] JSON-RPC: 
- [x] GraphQL: New sub-command for `sui-graphql-rpc`, `generate-config`
for creating a TOML config with all default values set.
- [ ] CLI: 
- [ ] Rust SDK:
amnn added a commit that referenced this pull request Aug 20, 2024
## Description

Replace the original implementation of the dump-packages command (which
requires access to an indexer database) with an implementation that
reads from a GraphQL service. The former is not readily accessible, but
the latter should be.

The new tool is also able to run incrementally: Fetching only packages
created before a certain checkpoint, or pick up where a previous
invocation took off to fetch new packages that were introduced since.

## Test plan

Ran a test invocation, on our experimental read replica. With a max page
size of 200, I was able to fetch 17000 packages (all the packages at the
time the read replica was created) in 3 minutes.

## Stack

- #17543
- #17692 
- #17693 
- #17696 
- #18287 
- #18288 
- #18336

---

## Release notes

Check each box that your changes affect. If none of the boxes relate to
your changes, release notes aren't required.

For each box you select, include information after the relevant heading
that describes the impact of your changes that a user might notice and
any actions they must take to implement updates.

- [ ] Protocol: 
- [ ] Nodes (Validators and Full nodes): 
- [ ] Indexer: 
- [ ] JSON-RPC: 
- [ ] GraphQL: 
- [ ] CLI: 
- [ ] Rust SDK:
tx-tomcat pushed a commit to tx-tomcat/sui-network that referenced this pull request Aug 27, 2024
## Description

Add a command for generating a config TOML file for the GraphQL service
with all its parameters set to their default values. (We used to have a
similar command for the YAML file which we weren't using, but we still
use the TOML file).

## Test plan

```
cargo run --bin sui-graphql-rpc -- generate-config /tmp/config.toml
```

## Stack

- MystenLabs#17543
- MystenLabs#17692 
- MystenLabs#17693 
- MystenLabs#17696 
- MystenLabs#18287 
- MystenLabs#18288 

---

## Release notes

Check each box that your changes affect. If none of the boxes relate to
your changes, release notes aren't required.

For each box you select, include information after the relevant heading
that describes the impact of your changes that a user might notice and
any actions they must take to implement updates.

- [ ] Protocol: 
- [ ] Nodes (Validators and Full nodes): 
- [ ] Indexer: 
- [ ] JSON-RPC: 
- [x] GraphQL: New sub-command for `sui-graphql-rpc`, `generate-config`
for creating a TOML config with all default values set.
- [ ] CLI: 
- [ ] Rust SDK:
tx-tomcat pushed a commit to tx-tomcat/sui-network that referenced this pull request Aug 27, 2024
## Description

Replace the original implementation of the dump-packages command (which
requires access to an indexer database) with an implementation that
reads from a GraphQL service. The former is not readily accessible, but
the latter should be.

The new tool is also able to run incrementally: Fetching only packages
created before a certain checkpoint, or pick up where a previous
invocation took off to fetch new packages that were introduced since.

## Test plan

Ran a test invocation, on our experimental read replica. With a max page
size of 200, I was able to fetch 17000 packages (all the packages at the
time the read replica was created) in 3 minutes.

## Stack

- MystenLabs#17543
- MystenLabs#17692 
- MystenLabs#17693 
- MystenLabs#17696 
- MystenLabs#18287 
- MystenLabs#18288 
- MystenLabs#18336

---

## Release notes

Check each box that your changes affect. If none of the boxes relate to
your changes, release notes aren't required.

For each box you select, include information after the relevant heading
that describes the impact of your changes that a user might notice and
any actions they must take to implement updates.

- [ ] Protocol: 
- [ ] Nodes (Validators and Full nodes): 
- [ ] Indexer: 
- [ ] JSON-RPC: 
- [ ] GraphQL: 
- [ ] CLI: 
- [ ] Rust SDK:
suiwombat pushed a commit that referenced this pull request Sep 16, 2024
## Description

Add a command for generating a config TOML file for the GraphQL service
with all its parameters set to their default values. (We used to have a
similar command for the YAML file which we weren't using, but we still
use the TOML file).

## Test plan

```
cargo run --bin sui-graphql-rpc -- generate-config /tmp/config.toml
```

## Stack

- #17543
- #17692 
- #17693 
- #17696 
- #18287 
- #18288 

---

## Release notes

Check each box that your changes affect. If none of the boxes relate to
your changes, release notes aren't required.

For each box you select, include information after the relevant heading
that describes the impact of your changes that a user might notice and
any actions they must take to implement updates.

- [ ] Protocol: 
- [ ] Nodes (Validators and Full nodes): 
- [ ] Indexer: 
- [ ] JSON-RPC: 
- [x] GraphQL: New sub-command for `sui-graphql-rpc`, `generate-config`
for creating a TOML config with all default values set.
- [ ] CLI: 
- [ ] Rust SDK:
suiwombat pushed a commit that referenced this pull request Sep 16, 2024
## Description

Replace the original implementation of the dump-packages command (which
requires access to an indexer database) with an implementation that
reads from a GraphQL service. The former is not readily accessible, but
the latter should be.

The new tool is also able to run incrementally: Fetching only packages
created before a certain checkpoint, or pick up where a previous
invocation took off to fetch new packages that were introduced since.

## Test plan

Ran a test invocation, on our experimental read replica. With a max page
size of 200, I was able to fetch 17000 packages (all the packages at the
time the read replica was created) in 3 minutes.

## Stack

- #17543
- #17692 
- #17693 
- #17696 
- #18287 
- #18288 
- #18336

---

## Release notes

Check each box that your changes affect. If none of the boxes relate to
your changes, release notes aren't required.

For each box you select, include information after the relevant heading
that describes the impact of your changes that a user might notice and
any actions they must take to implement updates.

- [ ] Protocol: 
- [ ] Nodes (Validators and Full nodes): 
- [ ] Indexer: 
- [ ] JSON-RPC: 
- [ ] GraphQL: 
- [ ] CLI: 
- [ ] Rust SDK:
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.

2 participants