fluxcd / flux

Successor: https://github.com/fluxcd/flux2
https://fluxcd.io
Apache License 2.0
6.9k stars 1.08k forks source link

Remove telemetry code #3633

Closed dholbach closed 2 years ago

dholbach commented 2 years ago

Following up from #2990 and discussion afterwards, it was pointed out to us that for telemetry data we should follow https://linuxfoundation.org/telemetry-data-policy/

As Flux v1 will be end-of-life soon anyway, it might make sense to just go and disable the code in question.

stefanprodan commented 2 years ago

I'm for deleting the telemetry code from v1 https://github.com/fluxcd/flux/tree/master/pkg/checkpoint

pjbgf commented 2 years ago

+1 for removing the telemetry code.

kingdonb commented 2 years ago

If we delete the telemetry code, then users who depend on the checkpoint feature to know when there is a new version available will no longer receive the notice.

Is there a way to delete the code that does not remove this feature? Otherwise it is a breaking change as anything that emits a log message has been considered as part of the public API since maintenance mode.

stefanprodan commented 2 years ago

Is there a way to delete the code that does not remove this feature?

No, to know which version is latest, Flux needs to call home.

kingdonb commented 2 years ago

We could substitute a call to GitHub REST API, query the tag refs, and pass back no information

Or we could go on using the same Checkpoint API, but pass in 0.0.0 since it does not matter which version of Flux v1 they are using, they should all be flagged as needing an upgrade. That would satisfy the policy requirement to not create telemetry data I think, but it does not stop us from potentially building a list of who is phoning home. I'll have to read the telemetry policy to understand its intention and purpose, but I would guess that's still not going to fly (and phoning home to GitHub is not much better.)

IOW, at some point all Flux v1 versions should be signaling that it's time to upgrade to v2 and emitting this warning every checkpoint interval whether or not they are on the latest Flux v1, and we have #3628 which suggests this time is coming soon (or has already arrived.)

stefanprodan commented 2 years ago

I propose we delete the checkpoint code and replace it with a message that tells people to upgrade to v2 along with a link to the migration docs.

kingdonb commented 2 years ago

I've removed the telemetry in #3636 and the output of checkpoint code looks like this now:

ts=2022-08-26T21:44:13.882228313Z caller=checkpoint.go:15 component=checkpoint msg="update available" latest=v0.33.0 URL=https://fluxcd.io/docs/migration/

I can change the msg to something grander than "update available" if you think we should use the word deprecated for example for emphasis, let me know what else you think it should say and I'll add it 👍

We should be ready to release this on ~Monday~ maybe Tuesday, knowing that Monday is a bank holiday for some folks, I'll be working though, so I can release it on Monday, along with fixes for the other issues I have tagged with Milestone 1.25.4 that I'm still working on