Skip to content

Add data plane metrics to CronjobSource#1790

Merged
knative-prow-robot merged 9 commits into
knative:masterfrom
sayanh:enable-metrics-cronjobsource
Sep 16, 2019
Merged

Add data plane metrics to CronjobSource#1790
knative-prow-robot merged 9 commits into
knative:masterfrom
sayanh:enable-metrics-cronjobsource

Conversation

@sayanh
Copy link
Copy Markdown
Contributor

@sayanh sayanh commented Sep 2, 2019

Helps #1693

Proposed Changes

  • Enable metrics cronjobsource

Release Note

 CronJobSource now reports event counts

@knative-prow-robot knative-prow-robot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Sep 2, 2019
@knative-prow-robot knative-prow-robot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Sep 2, 2019
@knative-prow-robot
Copy link
Copy Markdown
Contributor

Hi @sayanh. Thanks for your PR.

I'm waiting for a knative member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@googlebot googlebot added the cla: yes Indicates the PR's author has signed the CLA. label Sep 2, 2019
@knative-prow-robot knative-prow-robot added the area/test-and-release Test infrastructure, tests or release label Sep 2, 2019
@sayanh sayanh force-pushed the enable-metrics-cronjobsource branch from a8fae2e to caff537 Compare September 3, 2019 09:11
@sayanh sayanh force-pushed the enable-metrics-cronjobsource branch from caff537 to 5c04c4e Compare September 3, 2019 09:20
@nachocano
Copy link
Copy Markdown
Contributor

/hold
until #1784 is merged

@knative-prow-robot knative-prow-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Sep 3, 2019
@coryrc
Copy link
Copy Markdown
Contributor

coryrc commented Sep 3, 2019

/cc @Fredy-Z
/uncc @coryrc

@knative-prow-robot knative-prow-robot requested review from chizhg and removed request for coryrc September 3, 2019 17:40
@sayanh sayanh changed the title Enable metrics cronjobsource Adding data plane metrics to CronjobSource Sep 3, 2019
@chizhg
Copy link
Copy Markdown
Contributor

chizhg commented Sep 3, 2019

/uncc @Fredy-Z

@knative-prow-robot knative-prow-robot removed the request for review from chizhg September 3, 2019 20:42
@sayanh sayanh force-pushed the enable-metrics-cronjobsource branch 2 times, most recently from f73d5ac to 6adc33e Compare September 10, 2019 11:55
@knative-prow-robot knative-prow-robot added size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. and removed size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Sep 10, 2019
@sayanh sayanh marked this pull request as ready for review September 10, 2019 11:55
@knative-prow-robot knative-prow-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Sep 10, 2019
@sayanh sayanh changed the title Adding data plane metrics to CronjobSource Add data plane metrics to CronjobSource Sep 10, 2019
@sayanh sayanh force-pushed the enable-metrics-cronjobsource branch from 4745c99 to 52bc290 Compare September 13, 2019 20:10
"knative.dev/pkg/source"
)

type mockReporter struct{}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

can we add the eventCount mocking as in here?


to validate that we are calling the method?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

sure

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

thanks!

deploymentLister: deploymentInformer.Lister(),
eventTypeLister: eventTypeInformer.Lister(),
env: *env,
context: ctx,
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

rename to loggingContext, as with apiserversource?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

sure, done

@nachocano
Copy link
Copy Markdown
Contributor

@sayanh thanks for doing this. I added very minor stuff, and if Adam is OK, we can get this one in.

@nachocano
Copy link
Copy Markdown
Contributor

/hold cancel

@knative-prow-robot knative-prow-robot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Sep 13, 2019
@nachocano
Copy link
Copy Markdown
Contributor

/lgtm

@Harwayne for approval

@knative-prow-robot knative-prow-robot added the lgtm Indicates that a PR is ready to be merged. label Sep 13, 2019
@sayanh sayanh force-pushed the enable-metrics-cronjobsource branch from 94e3116 to a7e6524 Compare September 13, 2019 22:04
@knative-prow-robot knative-prow-robot removed the lgtm Indicates that a PR is ready to be merged. label Sep 13, 2019
Copy link
Copy Markdown
Contributor

@Harwayne Harwayne left a comment

Choose a reason for hiding this comment

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

Looks great! Just a few remaining comments.

Comment thread pkg/reconciler/cronjobsource/cronjobsource.go Outdated
Comment thread pkg/reconciler/cronjobsource/cronjobsource.go Outdated
return cj, err
}

func (r *Reconciler) UpdateFromLoggingConfigMap(cfg *corev1.ConfigMap) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Let's add a // TODO determine how to push the updated logging config to existing data plane Pods.

sayanh and others added 3 commits September 14, 2019 11:10
Co-Authored-By: Adam Harwayne <harwayne@google.com>
Co-Authored-By: Adam Harwayne <harwayne@google.com>
Copy link
Copy Markdown
Contributor

@Harwayne Harwayne left a comment

Choose a reason for hiding this comment

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

/lgtm
/approve

@knative-prow-robot knative-prow-robot added the lgtm Indicates that a PR is ready to be merged. label Sep 16, 2019
@knative-prow-robot
Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: Harwayne, sayanh

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@knative-prow-robot knative-prow-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Sep 16, 2019
@knative-metrics-robot
Copy link
Copy Markdown

The following is the coverage report on pkg/.
Say /test pull-knative-eventing-go-coverage to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/adapter/cronjobevents/adapter.go 90.3% 91.4% 1.1
pkg/reconciler/cronjobsource/cronjobsource.go 68.0% 69.2% 1.2

@knative-prow-robot knative-prow-robot merged commit 2cf4d81 into knative:master Sep 16, 2019
@sayanh sayanh deleted the enable-metrics-cronjobsource branch September 16, 2019 08:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. area/test-and-release Test infrastructure, tests or release cla: yes Indicates the PR's author has signed the CLA. lgtm Indicates that a PR is ready to be merged. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants