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

Unconditional Gateway Deployment and Refinements #1228

Open
karlem opened this issue Dec 4, 2024 · 0 comments
Open

Unconditional Gateway Deployment and Refinements #1228

karlem opened this issue Dec 4, 2024 · 0 comments
Assignees

Comments

@karlem
Copy link
Contributor

karlem commented Dec 4, 2024

Description:
Enhance the gateway deployment process to allow unconditional deployment, even in unanchored mode. Refactor related methods for clarity and enforce restrictions on operations requiring a parent subnet.


Tasks:

  1. Unconditional Deployment

    • Add a constructor parameter (e.g., isAnchored) to define if the gateway is running anchored or unanchored.
    • Update gateway initialization to handle unanchored mode appropriately.
  2. Refactor Pathways for Root Gateways

    • Extend is_root logic to also cover unanchored mode (e.g., subnet_id == null).
    • Introduce a helper method (isUnanchoredOrRoot()) to centralize this logic.
  3. Rename gateway.enabled()

    • Rename gateway.enabled() to gateway.isAnchored() for improved clarity.
    • Update all references and document the change.
  4. Restrict Parent-Dependent Methods

    • Prohibit operations requiring a parent (e.g., sending bottom-up messages) for unanchored or root gateways.
    • Add validation logic in relevant methods with clear revert messages.

Goal:
Allow flexible deployment of gateways while maintaining clear semantics and safeguarding operations that rely on anchored state.


Additional Notes:
Please ensure tests are updated or added for the new constructor behavior, pathway logic, and restricted methods.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Backlog
Development

No branches or pull requests

1 participant