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

Workflow Eviction #2

Open
dabercro opened this issue Nov 8, 2018 · 20 comments
Open

Workflow Eviction #2

dabercro opened this issue Nov 8, 2018 · 20 comments
Assignees

Comments

@dabercro
Copy link

dabercro commented Nov 8, 2018

Right now, the console loops through all workflows in its database while updating errors seen. Since workflows with errors add up quickly, this now takes forever.

It would be good to have some way of looping through a subset of workflows. This can either be looking at workflows that are newer than some age, or only looking at workflows that appear with status "manual" in http://cms-unified.web.cern.ch/cms-unified/public/statuses.json (what the old console does).

@vlimant may be able to suggest a table or query that can be directly made to get the workflows that make the statuses.json page.

@dabercro
Copy link
Author

dabercro commented Nov 8, 2018

@vargasa I would assign this to you, but it looks like you need to be a collaborator first. (Invite was just sent.) Let me know if you have any other questions on this issue.

@vargasa vargasa self-assigned this Nov 8, 2018
@vlimant
Copy link

vlimant commented Nov 15, 2018

the json file on the web is not used, the console reads directly in oracle

https://github.com/CMSCompOps/wtc-console/blob/master/src/unified/models.py

@vlimant
Copy link

vlimant commented Nov 15, 2018

there seems to be something here

# TODO old data cleanup here

as a hook for cleaning

@dabercro
Copy link
Author

Ah, I guess I meant, the statuses.json can still be used as a way to determine what the loop should be. How are workflows evicted from that JSON file?

@vlimant
Copy link

vlimant commented Nov 15, 2018

do not tie to the json file. evicting anything that is not in "manual" anymore is an ok way.

@vlimant
Copy link

vlimant commented Nov 15, 2018

although, we might want to keep much more, if we are going to use the new console as the new unified report (which was one of the goal here)

@dabercro
Copy link
Author

Okay @vargasa I think that means that you'll need to connect to the Oracle database to fill the tasks table. Also, we'll need to add a filter (status like "%manual%" for a first pass) that isn't there right now.

@vlimant
Copy link

vlimant commented Nov 15, 2018

.filter(status__icontains='manual') \

maybe

@sharad1126
Copy link

assistance-manual, assistance-manual-recovered, assistance-announced-manual, assistance-announced-manual-recovered are the categories that should have workflows in WTC console because these are the ones that I need to take action on.

@vargasa
Copy link
Collaborator

vargasa commented Nov 29, 2018

@vargasa
Copy link
Collaborator

vargasa commented Dec 5, 2018

Hi @sharad1126 I can confirm that the following status are being fetched from Unified:

<QuerySet [u'assistance-agentfilemismatch-manual', u'assistance-agentfilemismatch-manual-recovered', u'assistance-announced-manual-recovered', u'assistance-manual', u'assistance-manual-recovered']>

This was done by logging:

UnifiedWorkflow.objects.filter(status__icontains='manual').values_list('status',flat=True).distinct()

Which provides a set of unique workflows status from unified that contains the string 'manual'. So maybe the problem is not here (tasks.py) but in the front-end

@vargasa
Copy link
Collaborator

vargasa commented Dec 5, 2018

@sharad1126 I took a couple of workflows from here and they are shown also on wtc-console as it is in my dev instance. How are you accessing wtc-console?

@sharad1126
Copy link

@vargasa I am generally accessing the WTC console through the unified error reports as it directly sends me to the console page of that particular workflow to take an action.

@vargasa
Copy link
Collaborator

vargasa commented Dec 6, 2018 via email

@dabercro
Copy link
Author

dabercro commented Dec 6, 2018

My guess is that the link from Unified still points to the old tool. To make things easier for Sharad, I can try to add a link to the new console from the old one, unless @vlimant wants to make the change or addition in Unified.

@sharad1126
Copy link

@dabercro that's right. I'm still using the old tool. @vargasa here is the link of an error report - https://cms-unified.web.cern.ch/cms-unified/report/prebello_Run2018B-v1-JetHT-17Sep2018_pilot_1024p1_180917_170455_3850. It has an option on the top left called console. I use it to directly use the console which points to the default port. on vocms0113.cern.ch/seeworkflow

@vlimant
Copy link

vlimant commented Dec 6, 2018

in fine, the new wtc-console should have enough information in itself that the unified report would go away. the goal is indeed to have all information of the unified report located in mongodb and have enough visualization for the wtc to perform the operation.
we can add a link on the unified report pointing at the new console using a filtering url to restrict to that particular workflow, for now.
but again, the new console should have enough information in fine, so that the report and the assistance page is not necessary anymore

@sharad1126
Copy link

@vlimant As far as I know, the new console isn't giving me enough information regarding the errors. So for now, I would suggest that we use error reports from unified and then go to the console from there.

@vargasa
Copy link
Collaborator

vargasa commented Dec 6, 2018

It has an option on the top left called console. I use it to directly use the console which points to the default port

I see. This is from the other tool though as I see the cherrypy favicon on the vocms0113 link

the new console isn't giving me enough information regarding the errors.

@vlimant, @dabercro Is all the information in the report that @sharad1126 sent contained in Unified? If it is so as of now is not being retrieved by this console

@dabercro
Copy link
Author

It sounds like Sharad wasn't using the displays in the old console either. We can handle the errors in #3 though. For this issue, we should just confirm that the workflows @sharad1126 needs are visible to him.

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

No branches or pull requests

4 participants