Skip to content

Conversation

nicolai86
Copy link
Contributor

@nicolai86 nicolai86 commented Aug 2, 2022

What does this PR do?

This PR changes the CLI to add support for listing apps. For our launch of BYOC support we want to be able to list apps and also filter by cluster which executes the application.

listing apps

❯ lightning list apps
┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━┳━━━━━━━━━━━━━━━┳━━━━━━━━━━━━┓
┃ id                         ┃ name                       ┃ status  ┃ cluster       ┃ created    ┃
┡━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━╇━━━━━━━━━━━━━━━╇━━━━━━━━━━━━┩
│ 01g9g4p2my8a3na6jx4kdxtmzn │ lightning/notebook-manager │ running │ litng-ai-03   │ 2022-08-02 │
│ 01g92nrr7r06zh8nhddzkhg213 │ fresh-boyd-193             │ stopped │ test-raphael9 │ 2022-07-28 │
└────────────────────────────┴────────────────────────────┴─────────┴───────────────┴────────────┘

the --cluster-id flag can be passed to list only apps in a specific cluster:

❯ lightning list apps  --cluster-id test-raphael9
┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━┳━━━━━━━━━┳━━━━━━━━━━━━━━━┳━━━━━━━━━━━━┓
┃ id                         ┃ name           ┃ status  ┃ cluster       ┃ created    ┃
┡━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━╇━━━━━━━━━╇━━━━━━━━━━━━━━━╇━━━━━━━━━━━━┩
│ 01g92nrr7r06zh8nhddzkhg213 │ fresh-boyd-193 │ stopped │ test-raphael9 │ 2022-07-28 │
└────────────────────────────┴────────────────┴─────────┴───────────────┴────────────┘

Does your PR introduce any breaking changes? If yes, please list them.

Before submitting

  • Was this discussed/approved via a GitHub issue? (not for typos and docs)
  • Did you read the contributor guideline, Pull Request section?
  • Did you make sure your PR does only one thing, instead of bundling different changes together?
  • Did you make sure to update the documentation with your changes? (if necessary)
  • Did you write any new necessary tests? (not for typos and docs)
  • Did you verify new and existing tests pass locally with your changes?
  • Did you list all the breaking changes introduced by this pull request?
  • Did you update the CHANGELOG? (not for typos, docs, test updates, or minor internal changes/refactors)

PR review

Anyone in the community is welcome to review the PR.
Before you start reviewing, make sure you have read the review guidelines. In short, see the following bullet-list:

  • Is this pull request ready for review? (if not, please submit in draft mode)
  • Check that all items from Before submitting are resolved
  • Make sure the title is self-explanatory and the description concisely explains the PR
  • Add labels and milestones (and optionally projects) to the PR so it can be classified

Did you have fun?

Make sure you had fun coding 🙃

cc @Borda @tchaton @rohitgr7

@github-actions github-actions bot added the app (removed) Generic label for Lightning App package label Aug 2, 2022
@nicolai86 nicolai86 added the priority: 0 High priority task label Aug 2, 2022
@nicolai86 nicolai86 added this to the app:0.6 milestone Aug 2, 2022
@nicolai86 nicolai86 marked this pull request as ready for review August 2, 2022 20:59
@nicolai86 nicolai86 marked this pull request as draft August 2, 2022 21:01
@nicolai86 nicolai86 marked this pull request as ready for review August 2, 2022 21:12
Copy link
Contributor

@alecmerdler alecmerdler left a comment

Choose a reason for hiding this comment

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

Nice job!

@mergify mergify bot added the has conflicts label Aug 4, 2022
@nicolai86 nicolai86 force-pushed the nicolai86/list-apps branch from 2ad15ae to 1d993b4 Compare August 4, 2022 18:04
@mergify mergify bot removed the has conflicts label Aug 4, 2022
@nicolai86 nicolai86 force-pushed the nicolai86/list-apps branch from 1d993b4 to 0da53f7 Compare August 4, 2022 23:23
@mergify mergify bot added the ready PRs ready to be merged label Aug 5, 2022
Copy link

@hhsecond hhsecond left a comment

Choose a reason for hiding this comment

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

Nice job! Some minor change requests but since it's merging as "experimental", I don't want to block the PR. The exception handling is something I think we should do now though, but again if you are keeping it for later, please track that in a ticket.

Copy link
Contributor

@awaelchli awaelchli left a comment

Choose a reason for hiding this comment

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

Accept to unblock

Copy link

@hhsecond hhsecond left a comment

Choose a reason for hiding this comment

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

Approving to unblock as I am signing off

@nicolai86 nicolai86 force-pushed the nicolai86/list-apps branch from 0da53f7 to 6503a2a Compare August 5, 2022 16:08
@nicolai86 nicolai86 merged commit 26d69ce into master Aug 5, 2022
@nicolai86 nicolai86 deleted the nicolai86/list-apps branch August 5, 2022 20:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
app (removed) Generic label for Lightning App package priority: 0 High priority task ready PRs ready to be merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants