Skip to content

Conversation

YintongMa
Copy link
Contributor

@YintongMa YintongMa commented Jul 29, 2021

@YintongMa YintongMa closed this Jul 30, 2021
@YintongMa YintongMa reopened this Jul 30, 2021
@YintongMa YintongMa requested review from calbach and yonghaoy August 2, 2021 16:10
Copy link
Collaborator

@yonghaoy yonghaoy left a comment

Choose a reason for hiding this comment

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

First path on API changes, haven't review UI change yet. Few general nit:

  1. There are many copy-paste errors from runtime -> persistent disk
  2. I saw some test breakage caused by this change.
  3. No unit test for API changes. Adding tests is generally helpful.

@YintongMa YintongMa requested a review from yonghaoy August 3, 2021 21:05
LeonardoGetPersistentDiskResponse response;
List<LeonardoListPersistentDiskResponse> responseList =
leonardoNotebooksClient.listPersistentDiskByProject(googleProject, false);
responseList.sort(
Copy link
Collaborator

Choose a reason for hiding this comment

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

How you guarantee the last created disk is the one we want? 10 users are using the same workspace, and create PDs at the same time. What would happen then?

Copy link
Contributor

@calbach calbach left a comment

Choose a reason for hiding this comment

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

Sorry for the delayed reviews, will look at this today but possibly not until tonight.

Copy link
Collaborator

@yonghaoy yonghaoy left a comment

Choose a reason for hiding this comment

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

Thanks! looks simpler now!

Copy link
Contributor

@calbach calbach left a comment

Choose a reason for hiding this comment

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

The API looks good - a few cleanups suggested. Can we split the UI changes out into a separate PR? It seems like it should be totally separable to me as there are no breaking API changes here.

Copy link
Contributor

@calbach calbach left a comment

Choose a reason for hiding this comment

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

Note: you will need to merge or rebase with the Angular->React - likely it just affects the diskStore initialization.

Do you have the runtime panel spec changes?

return {
computeType: ComputeType.Standard,
machine: findMachineByName(runtime.gceConfig.machineType),
diskSize: runtime.gceConfig.diskSize,
Copy link
Contributor

Choose a reason for hiding this comment

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

hm, we still have diskSize after this change. WIll that always be set?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Note: you will need to merge or rebase with the Angular->React - likely it just affects the diskStore initialization.

Sorry, do you mean I need to merge/rebase with the latest master since there are some codebase changes of Angular->React ?

Do you have the runtime panel spec changes?

No, there are some code format diffs with the master after I run yarn lint --fix ... I have to revert them manually.

Copy link
Contributor

@calbach calbach left a comment

Choose a reason for hiding this comment

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

Thanks for adding screenshots. I see the PD cost estimator which is cool, but I don't see the commits in this PR. Do you have commits to push still?

@YintongMa YintongMa requested review from calbach and yonghaoy August 19, 2021 18:44
Copy link
Contributor

@calbach calbach left a comment

Choose a reason for hiding this comment

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

OK - if this is working, I think I'm about good to approve pending remaining comments. RE moving logic to backend: it isn't a bad idea but I don't see a clear path so this may be a bit risky. I also definitely want to play around with this a bit - and definitely want to get Shimon/Lou feedback on the new UX interactions, e.g. the separate PD disk estimator.

@calbach
Copy link
Contributor

calbach commented Aug 20, 2021

Sorry, I lost my other comment: it was to revert submodules, and apologies for the additional merge conflicts here.

@yonghaoy
Copy link
Collaborator

OK - if this is working, I think I'm about good to approve pending remaining comments. RE moving logic to backend: it isn't a bad idea but I don't see a clear path so this may be a bit risky. I also definitely want to play around with this a bit - and definitely want to get Shimon/Lou feedback on the new UX interactions, e.g. the separate PD disk estimator.

If rewriting most of this code to move those logic to backend is too hard/frustrate, you can leave this in frontend for now. I think Leo is working on writing this API as well, it might be throw away effort if we make API change now. One thing that can be a further improvement is asking Leo to change their API interface for one API (I remember there is a PD related API but they use UpdateGceConfig?) .
The UI change is good for now. I believe after the existing runtime get auto deleted, the logic would be simpler.

This is great! Thanks!

Copy link
Collaborator

@yonghaoy yonghaoy left a comment

Choose a reason for hiding this comment

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

Since this is proteched by feature branch, I think we can go with this, and polish if needed in following PR

@YintongMa YintongMa requested review from calbach and yonghaoy August 21, 2021 03:07
@YintongMa
Copy link
Contributor Author

The test fails after i merge latest master : ERROR in src/app/pages/app/component.ts(35,29): error TS2307: Cannot find module 'app/services/sign-in.service'.

Copy link
Contributor

@calbach calbach left a comment

Choose a reason for hiding this comment

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

I'm out next week, so don't wait on my approval - this is fine to merge once the rebase issues are addressed

@@ -0,0 +1,310 @@
import {Component, NgZone, OnDestroy, OnInit} from '@angular/core';
Copy link
Contributor

Choose a reason for hiding this comment

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

This file was removed, you'll need to move your logic to somewhere around here: https://github.com/all-of-us/workbench/blob/master/ui/src/app/routing/app-routing.tsx#L272

@YintongMa YintongMa merged commit 6818a55 into master Aug 25, 2021
@YintongMa YintongMa deleted the yintong/UIForPD branch August 25, 2021 21:21
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.

3 participants