Skip to content

[mkdocs] docs: add namespace concept#844

Open
zero4862 wants to merge 3 commits intoNemProject:new-docsfrom
zero4862:docs-namespace-concept
Open

[mkdocs] docs: add namespace concept#844
zero4862 wants to merge 3 commits intoNemProject:new-docsfrom
zero4862:docs-namespace-concept

Conversation

@zero4862
Copy link
Copy Markdown

@zero4862 zero4862 commented Apr 29, 2026

Adapts Namespace concept to NEM technology.

Differences with Symbol:

  • Role: Every mosaic lives under a namespace in NEM; optional alias for an account or mosaic in Symbol.
  • Mosaic lifecycle coupling: NEM mosaics become inactive when their parent namespace expires; Symbol mosaics persist independently and only the alias breaks.
  • Root name length: 16 chars on NEM vs 64 chars on Symbol. Subnamespace levels are 64 in both.
  • Duration: Fixed 525600 blocks (~1 year) on NEM vs 30 days to 5 years on Symbol.
  • Renewal window: Restricted to the last 43200 blocks before expiration on NEM; any time during the lease on Symbol.
  • Lease fee: Fixed on NEM vs duration-proportional XYM on Symbol.
  • Subnamespace cap: NEM has no explicit cap beyond the 3-level depth limit; Symbol caps at 256 subnamespaces per root.
  • Metadata: NEM does not not support metadata.


Subnamespace
: A namespace that belongs to a parent namespace, either the root or another subnamespace.
Subnamespaces expire when the root namespace expires (see [Duration](#duration)).
Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

In Symbol, we say:

A namespace that belongs to a parent root namespace. Subnamespaces expire when the parent namespace expires (see Duration)

What's marked in bold seems not accurate:

  • parent root -> parent: A subnamespace could be defined under another subnamespace, not necessarily the parent root.
  • parent namespace -> *root namespace: Since the parent subnamespace could be another subnamepace, we might want to say root namespace instead.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Agreed, can you add this to the Symbol PR too?

Comment thread mkdocs/pages/en/textbook/namespaces.md Outdated

Namespaces let an account group related mosaics under a meaningful prefix like `mycompany.tokens`.

The account that registers a root namespace is called its _owner_.
Copy link
Copy Markdown
Author

@zero4862 zero4862 Apr 29, 2026

Choose a reason for hiding this comment

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

To review in Symbol:

  • creator vs owner: We define the concept of "owner" here, while Symbol it uses "creator" and "owner". We should standardize this terminology (guides already use "owner"). "Creator" can be interpreted as the account that originally registered the namespace, whereas "owner" I think it reflects more accurately the account that has leased the namespace.

  • create namespace vs register namespace: Replaced "create namespace" with "register namespace" for the same reason.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Good thinking, yes. Can you create the PR for Symbol?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Yes, I can tackle this after completing all the textbook concepts, so I can evaluate the effort of updating Symbol all at once.

Comment on lines +70 to +71
"Grace Period" -> Registered [label="\nRenewal" constraint=false];
"Grace Period" -> "Available Again" [label="Release"];
Copy link
Copy Markdown
Author

@zero4862 zero4862 Apr 29, 2026

Choose a reason for hiding this comment

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

To review in Symbol:

Changed here "Deletion" for "Release". It matches better "Register". "Delete" matches better "Create".

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Agreed. Can you add it to the Symbol PR?

Registering or renewing any kind of namespace requires announcing a transaction, which also has an associated fee.
However, this transaction fee is typically negligible compared to the lease fee.

## Reserved Names
Copy link
Copy Markdown
Author

@zero4862 zero4862 Apr 29, 2026

Choose a reason for hiding this comment

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

Added this new section (reserved names), we could add a similar one in Symbol.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Yes please! :D

Comment thread mkdocs/pages/en/textbook/namespaces.md
@zero4862 zero4862 force-pushed the docs-namespace-concept branch from 4b2e104 to c33a002 Compare April 29, 2026 15:28
@zero4862 zero4862 marked this pull request as ready for review April 29, 2026 15:36
@segfaultxavi segfaultxavi self-requested a review April 30, 2026 10:04
Copy link
Copy Markdown
Contributor

@segfaultxavi segfaultxavi left a comment

Choose a reason for hiding this comment

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

Minor changes only.

Comment thread mkdocs/pages/en/textbook/namespaces.md Outdated

Namespaces let an account group related mosaics under a meaningful prefix like `mycompany.tokens`.

The account that registers a root namespace is called its _owner_.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Good thinking, yes. Can you create the PR for Symbol?

Comment thread mkdocs/pages/en/textbook/namespaces.md Outdated

Subnamespace
: A namespace that belongs to a parent namespace, either the root or another subnamespace.
Subnamespaces expire when the root namespace expires (see [Duration](#duration)).
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Agreed, can you add this to the Symbol PR too?

Comment thread mkdocs/pages/en/textbook/namespaces.md Outdated

`nem`, `user`, `account`, `org`, `com`, `biz`, `net`, `edu`, `mil`, `gov`, `info`.

The `nem` namespace, in particular, is used by the system to host the native currency `nem:xem`.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

There's a colon to separate namespaces here, but previously you said it was periods. Which one is it?

Copy link
Copy Markdown
Author

@zero4862 zero4862 Apr 30, 2026

Choose a reason for hiding this comment

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

NEM namespaces are not used to name mosaics (like in Symbol), but to organize them. Mosaics have their own name. In nem:xem, nem is the namespace name and xem is the mosaic name, separated by a colon.

Subnamespaces are separated by a dot. Example: company.tokens:gold, where company is the namespace, tokens the subnamespace and gold the mosaic name.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Got it. I had not idea.
Then definitely you cannot use this example here without explaining what the colon means.
I understand you will probably explain it in the Mosaics page, but you need to provide at least a minimal explanation here and a link to where the colon is fully explained.

Something like:

Suggested change
The `nem` namespace, in particular, is used by the system to host the native currency `nem:xem`.
The `nem` namespace, in particular, is used by the system to host the native currency `nem:xem`
(note that the colon separates the namespace from the [currency name](./mosaics.md#fully-qualified-name)).

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Done!

Comment on lines +70 to +71
"Grace Period" -> Registered [label="\nRenewal" constraint=false];
"Grace Period" -> "Available Again" [label="Release"];
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Agreed. Can you add it to the Symbol PR?

Registering or renewing any kind of namespace requires announcing a transaction, which also has an associated fee.
However, this transaction fee is typically negligible compared to the lease fee.

## Reserved Names
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Yes please! :D

Comment thread mkdocs/pages/en/textbook/namespaces.md Outdated
@zero4862 zero4862 force-pushed the docs-namespace-concept branch from 12f78fe to 765f950 Compare April 30, 2026 11:40
@zero4862 zero4862 requested a review from segfaultxavi April 30, 2026 11:41
Comment thread mkdocs/pages/en/textbook/namespaces.md Outdated

`nem`, `user`, `account`, `org`, `com`, `biz`, `net`, `edu`, `mil`, `gov`, `info`.

The `nem` namespace, in particular, is used by the system to host the native currency `nem:xem`.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Got it. I had not idea.
Then definitely you cannot use this example here without explaining what the colon means.
I understand you will probably explain it in the Mosaics page, but you need to provide at least a minimal explanation here and a link to where the colon is fully explained.

Something like:

Suggested change
The `nem` namespace, in particular, is used by the system to host the native currency `nem:xem`.
The `nem` namespace, in particular, is used by the system to host the native currency `nem:xem`
(note that the colon separates the namespace from the [currency name](./mosaics.md#fully-qualified-name)).

@zero4862 zero4862 requested a review from segfaultxavi April 30, 2026 16:28
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