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

rpc-alt: resolveNameServiceAddress #21161

Open
wants to merge 4 commits into
base: amnn/rpc-test-refactor
Choose a base branch
from

Conversation

amnn
Copy link
Contributor

@amnn amnn commented Feb 10, 2025

Description

Adds an implementation for suix_resolveNameServiceAddress to rpc-alt. Also factors out the name_service module from sui-json-rpc into its own crate.

As part of this change, the watermarks and cp_sequence_numbers tables introduced by the indexing framework are exposed through sui-indexer-alt-schema, so that readers can read from these tables without taking a dependency on the (writer) framework.

Test plan

New E2E tests:

sui$ cargo nextest run -p sui-indexer-alt-e2e-tests

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):
  • gRPC:
  • JSON-RPC:
  • GraphQL:
  • CLI:
  • Rust SDK:

@amnn amnn self-assigned this Feb 10, 2025
Copy link

vercel bot commented Feb 10, 2025

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

Name Status Preview Comments Updated (UTC)
sui-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Feb 14, 2025 0:49am
2 Skipped Deployments
Name Status Preview Comments Updated (UTC)
multisig-toolkit ⬜️ Ignored (Inspect) Visit Preview Feb 14, 2025 0:49am
sui-kiosk ⬜️ Ignored (Inspect) Visit Preview Feb 14, 2025 0:49am

@amnn amnn temporarily deployed to sui-typescript-aws-kms-test-env February 10, 2025 16:27 — with GitHub Actions Inactive
@amnn amnn requested a review from manolisliolios February 10, 2025 16:28
Copy link
Contributor Author

Choose a reason for hiding this comment

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

The last usage of internal_context disappeared during the refactorings to have load_latest return an Object instead of StoredObject -- we can add it back if we need it (with_internal_context is still around).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Nothing has changed in this file -- it's just been re-ordered (and combined with its unit tests).

@amnn amnn force-pushed the amnn/rpc-test-refactor branch from 6346807 to 7ba0aa9 Compare February 10, 2025 19:08
@amnn amnn temporarily deployed to sui-typescript-aws-kms-test-env February 10, 2025 19:08 — with GitHub Actions Inactive
@amnn amnn temporarily deployed to sui-typescript-aws-kms-test-env February 10, 2025 23:42 — with GitHub Actions Inactive
@amnn amnn temporarily deployed to sui-typescript-aws-kms-test-env February 12, 2025 14:51 — with GitHub Actions Inactive
@amnn amnn temporarily deployed to sui-typescript-aws-kms-test-env February 12, 2025 14:58 — with GitHub Actions Inactive
@amnn amnn temporarily deployed to sui-typescript-aws-kms-test-env February 12, 2025 15:00 — with GitHub Actions Inactive
@amnn amnn force-pushed the amnn/rpc-test-refactor branch from 1b0bcab to 24120c7 Compare February 12, 2025 15:48
@amnn amnn temporarily deployed to sui-typescript-aws-kms-test-env February 12, 2025 15:48 — with GitHub Actions Inactive
@amnn amnn temporarily deployed to sui-typescript-aws-kms-test-env February 12, 2025 20:00 — with GitHub Actions Inactive
@amnn amnn force-pushed the amnn/rpc-test-refactor branch from 24120c7 to a2dcf95 Compare February 12, 2025 22:39
Copy link
Contributor

@manolisliolios manolisliolios left a comment

Choose a reason for hiding this comment

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

Looks great @amnn, thanks!

amnn added 4 commits February 14, 2025 12:44
## Description

Don't exclude framework tables from `sui-indexer-alt-schema`, so that
they can be used in the reader without the reader having to depend on
the framework.

## Test plan

These tables will be used in an upcoming change.
## Description
Pull out `sui-name-service` from `sui-json-rpc`, because it is used in
multiple other crates. This change also re-orders the contents of the
`name_service` module and brings its tests into one file.

## Test plan
CI
## Description

Simplifying the helper function that finds the latest version of an
object and returns it to return the serialized form, rather than the
`StoredObject`. This is based on an observation that:

- All the callers to this function eventually deserialize it.
- The other fields on `StoredObject` (id and version) are available on
  the deserialized object as well.

## Test plan

CI
## Description

Adds support for SuiNS name resolution.

## Test plan

New E2E tests, based on `FullCluster`:

```
sui$ cargo nextest run -p sui-indexer-alt-e2e-tests \
  -- test_resolve name_service
```
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