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

Send job & org data #4472

Conversation

rooftopcellist
Copy link
Member

@rooftopcellist rooftopcellist commented Aug 13, 2019

SUMMARY

Related: #4473

Expands the query to copy the unified_jobs table for analytics collection to include the organization name.

ISSUE TYPE
  • Feature Pull Request
COMPONENT NAME
  • API
ADDITIONAL INFORMATION

Stay tuned of performance notes.

@softwarefactory-project-zuul
Copy link
Contributor

Build failed.

@rooftopcellist
Copy link
Member Author

recheck

@softwarefactory-project-zuul
Copy link
Contributor

Build succeeded.

@rooftopcellist
Copy link
Member Author

Interesting considerations:

  • We have decided to determine the jobs that are in an organization based on the project used to launch the jobs, rather than the org the inventory used is in.
  • We need to decide how to handle orphaned jobs (jobs whose projects/inventories have been deleted)

@rooftopcellist rooftopcellist force-pushed the collection_org_job_info branch from 79c3824 to 2e58bc5 Compare August 14, 2019 15:06
@softwarefactory-project-zuul
Copy link
Contributor

Build failed.

@rooftopcellist rooftopcellist force-pushed the collection_org_job_info branch from 2e58bc5 to 282b736 Compare August 14, 2019 21:20
@softwarefactory-project-zuul
Copy link
Contributor

Build failed.

@rooftopcellist
Copy link
Member Author

recheck

@softwarefactory-project-zuul
Copy link
Contributor

Build succeeded.

AND main_project.unifiedjobtemplate_ptr_id = main_job.project_id
AND main_unifiedjob.polymorphic_ctype_id = django_content_type.id
AND main_unifiedjob.launch_type != 'sync'
AND main_organization.id = main_project.organization_id
Copy link
Contributor

Choose a reason for hiding this comment

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

@AlanCoding @rooftopcellist we're going to have to reconsider this after your merge of the "org on JT" feature.

Copy link
Member Author

Choose a reason for hiding this comment

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

@ryanpetrello I have discussed this with @AlanCoding and we decided to merge this first and then make any necessary changes when Alan's PR lands.

Copy link
Contributor

Choose a reason for hiding this comment

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

Perfect!

Copy link
Member

@elyezer elyezer left a comment

Choose a reason for hiding this comment

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

LGTM

@softwarefactory-project-zuul
Copy link
Contributor

Build failed (gate pipeline). For information on how to proceed, see
http://docs.openstack.org/infra/manual/developers.html#automated-testing

Copy link
Member

@elyezer elyezer left a comment

Choose a reason for hiding this comment

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

I will change my review to request changes since I observed that we are having duplicated rows on the generated report, for example:

id,polymorphic_ctype_id,model,organization_id,organization_name,created,name,unified_job_template_id,launch_type,schedule_id,execution_node,controller_node,cancel_flag,status,failed,started,finished,elapsed,job_explanation,instance_group_id
9,40,projectupdate,1,Default,2019-08-19 19:29:10.901595+00,Demo Project,6,dependency,,localhost,"",f,successful,f,2019-08-19 19:29:16.849771+00,2019-08-19 19:29:20.24345+00,3.394,"",1
9,40,projectupdate,1,Default,2019-08-19 19:29:10.901595+00,Demo Project,6,dependency,,localhost,"",f,successful,f,2019-08-19 19:29:16.849771+00,2019-08-19 19:29:20.24345+00,3.394,"",1
9,40,projectupdate,1,Default,2019-08-19 19:29:10.901595+00,Demo Project,6,dependency,,localhost,"",f,successful,f,2019-08-19 19:29:16.849771+00,2019-08-19 19:29:20.24345+00,3.394,"",1

Already talked to @rooftopcellist and he will take a look.

@softwarefactory-project-zuul
Copy link
Contributor

Build failed.

@rooftopcellist rooftopcellist force-pushed the collection_org_job_info branch 2 times, most recently from 365c3bf to 27e5602 Compare August 23, 2019 14:26
@softwarefactory-project-zuul
Copy link
Contributor

Build succeeded.

@elyezer
Copy link
Member

elyezer commented Aug 23, 2019

This is now producing better results but I still getting duplicated entries:

[['30', '37', 'job', '6', 'Organization - DifferenceNative�', '2019-08-23 20:35:23.359658+00', 'JobTemplate - BoyfriendJoin�', '37', 'manual', '', 'localhost', '', 'f', 'successful', 'f', '2019-08-23 20:35:23.630005+00', '2019-08-23 20:35:29.576914+00', '5.947', '', '1'], ['30', '37', 'job', '16', 'Organization - MarketReaction�', '2019-08-23 20:35:23.359658+00', 'JobTemplate - BoyfriendJoin�', '37', 'manual', '', 'localhost', '', 'f', 'successful', 'f', '2019-08-23 20:35:23.630005+00', '2019-08-23 20:35:29.576914+00', '5.947', '', '1']]

That job template:

Screenshot from 2019-08-23 16-47-23

Is associated with a single project:

Screenshot from 2019-08-23 16-46-48

And it is only associated with the Organization - MarketReaction� organization.

@rooftopcellist rooftopcellist force-pushed the collection_org_job_info branch from 27e5602 to cd3645e Compare August 26, 2019 14:22
@softwarefactory-project-zuul
Copy link
Contributor

Build succeeded.

Copy link
Member

@elyezer elyezer left a comment

Choose a reason for hiding this comment

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

With the recent changes I am not seeing the issue I was anymore

@rooftopcellist
Copy link
Member Author

regate

@softwarefactory-project-zuul
Copy link
Contributor

Build succeeded (gate pipeline).

@softwarefactory-project-zuul softwarefactory-project-zuul bot merged commit c74f826 into ansible:devel Aug 26, 2019
@softwarefactory-project-zuul softwarefactory-project-zuul bot merged commit cd3645e into ansible:devel Aug 26, 2019
ryanpetrello pushed a commit to ryanpetrello/awx that referenced this pull request Aug 5, 2020
Upgrade community.vmware for better error surfacing
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants