Skip to content
This repository was archived by the owner on Jul 4, 2025. It is now read-only.

Conversation

@louis-jan
Copy link
Contributor

@louis-jan louis-jan commented Jul 23, 2024

Describe Your Changes

This PR is a draft of incomplete work refactoring the Cortex CLI to remove coupled logics, thus enabling it to use CortexJS and send requests to the engine server.

This would help to address:

  • The loading time of the Cortex CLI is slow because it needs to reload all of the dependencies for every single command.
  • States between commands are not synchronized, since every command is an instance of the Cortex CLI app.
  • Reduce the workload on the Cortex CLI; it's just a 1-1 API mapping.

Every command will get access to the CortexJS client instance.

sequenceDiagram
    participant CLI as Cortex CLI
    participant CMD as Commands
    participant CJS as cortexjs
    participant ES as Engine Server

    CLI->>CMD: Provides
    CMD->>CJS: Imports
    CMD->>CJS: Uses
    CJS->>ES: Sends API requests
Loading

Fixes Issues

  • Closes #
  • Closes #

Self Checklist

  • Added relevant comments, esp in complex areas
  • Updated docs (for bug fixes / features)
  • Created issues for follow-up changes or refactoring needed

@louis-jan louis-jan force-pushed the refactor/cortex-cli-as-client branch 5 times, most recently from 02feca6 to b654a74 Compare July 25, 2024 14:08
@marknguyen1302 marknguyen1302 marked this pull request as ready for review July 25, 2024 16:31
@louis-jan louis-jan force-pushed the refactor/cortex-cli-as-client branch from cc000ed to 1399bc6 Compare July 25, 2024 18:05
@louis-jan louis-jan merged commit f82f5d7 into dev Jul 26, 2024
@louis-jan louis-jan deleted the refactor/cortex-cli-as-client branch July 26, 2024 03:32
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants