Skip to content

Conversation

@adfost
Copy link
Contributor

@adfost adfost commented May 3, 2021

No description provided.

@adfost adfost requested review from bexsoft and dvaldivia May 3, 2021 22:16
@dvaldivia dvaldivia requested a review from Alevsk May 4, 2021 16:28
@dvaldivia dvaldivia added enhancement New feature or request operator Operator Console labels May 4, 2021
@dvaldivia
Copy link
Collaborator

If I run other applications on the same namespace as the Tenant they get listed, please restrict the pods to only Tenant Pods

Screen Shot 2021-05-04 at 9 32 01 AM

Copy link
Collaborator

@dvaldivia dvaldivia left a comment

Choose a reason for hiding this comment

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

See screenshot

{selectedTab === 2 && pods[0].time && (
<TableWrapper
itemActions={[
{
Copy link
Collaborator

Choose a reason for hiding this comment

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

The delete action is not yet implemented, please remove this option

Copy link
Collaborator

Choose a reason for hiding this comment

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

You can send an empty array to item actions, it is not necessary to have an option here always

Copy link
Collaborator

Choose a reason for hiding this comment

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

You can send an empty array to item actions, it is not necessary to have an option here always

@dvaldivia
Copy link
Collaborator

Can you also attach a screenshot of the final screen to this ticket

label?: string;
}

export interface IPod {
Copy link
Collaborator

Choose a reason for hiding this comment

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

We should call it IPodListElement to have more clarity on what does this interface do

result[i].time = niceDays(
(currentTime - parseInt(result[i].timecreated)).toString()
);
console.log(result[i]);
Copy link
Collaborator

Choose a reason for hiding this comment

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

Please remove console.log

{selectedTab === 2 && pods[0].time && (
<TableWrapper
itemActions={[
{
Copy link
Collaborator

Choose a reason for hiding this comment

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

You can send an empty array to item actions, it is not necessary to have an option here always

{selectedTab === 2 && pods[0].time && (
<TableWrapper
itemActions={[
{
Copy link
Collaborator

Choose a reason for hiding this comment

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

You can send an empty array to item actions, it is not necessary to have an option here always

swagger.yml Outdated
status:
type:
string
timecreated:
Copy link
Collaborator

Choose a reason for hiding this comment

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

Please use camel case:

Suggested change
timecreated:
timeCreated:

swagger.yml Outdated
string
timecreated:
type: integer
podip:
Copy link
Collaborator

Choose a reason for hiding this comment

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

Same camel case here:

Suggested change
podip:
podIP:

.then((result: IPod[]) => {
for (let i = 0; i < result.length; i++) {
let currentTime = new Date().getSeconds();
console.log(currentTime);
Copy link
Collaborator

Choose a reason for hiding this comment

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

Please remove console.log

let currentTime = new Date().getSeconds();
console.log(currentTime);
result[i].time = niceDays(
(currentTime - parseInt(result[i].timecreated)).toString()
Copy link
Collaborator

Choose a reason for hiding this comment

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

Not sure if this what is intended, as you are receiving an epoch time from backend and you are substracting the amount of seconds of current time:

Screen Shot 2021-05-04 at 12 37 21

}
retval := []*models.TenantPod{}
for i := range pods.Items {
if pods.Items[i].Name[0:len(params.Tenant)] == params.Tenant {
Copy link
Collaborator

Choose a reason for hiding this comment

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

I broke this logic by deploying a pod for wodpress with the tenant prefix

admin.json Outdated
@@ -0,0 +1,22 @@
{
Copy link
Collaborator

Choose a reason for hiding this comment

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

remove this file

return nil, prepareError(err)
}
listOpts := metav1.ListOptions{
TypeMeta: metav1.TypeMeta{},
Copy link
Collaborator

Choose a reason for hiding this comment

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

remove all unused fields, also this doesn't filter anything like we discussed

dvaldivia
dvaldivia previously approved these changes May 7, 2021
@dvaldivia dvaldivia merged commit 281f8d5 into minio:master May 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request operator Operator Console

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants