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

Stackdriver Monitoring Provider #1044

Closed
Mistobaan opened this issue Feb 3, 2018 · 35 comments
Closed

Stackdriver Monitoring Provider #1044

Mistobaan opened this issue Feb 3, 2018 · 35 comments

Comments

@Mistobaan
Copy link

Is there any plans to create a stackdriver provider for monitoring ?

something similar to datadog's provider

API https://cloud.google.com/monitoring/api/ref_v3/rest/

@rosbo
Copy link
Contributor

rosbo commented Feb 5, 2018

Hi Fabrizio,

I believe @srivasta was working on this. @srivasta, can you post an update about your progress on this?

Thank you

@Mistobaan
Copy link
Author

friendly ping :D

@srivasta
Copy link
Contributor

I had started working with the stackdriver V3 API which was initially whitelist only. It has been published, so the work can be proceed now. I have a private branch that started working with it, but it is not yet complete. I should be able to get back to working on it next week (there is a work based exercise this week that is making availability sketchy)

@sdouche
Copy link

sdouche commented Apr 8, 2018

Hi,
Any update on this? The StackDriver Monitoring v3 API is now in beta, and it would be cool to use it with Terraform.

Regards.

@robolmos
Copy link

This would be a helpful provider to have.

@selkabli
Copy link

selkabli commented Jun 5, 2018

that will be cool

@mDantas
Copy link

mDantas commented Jun 8, 2018

Very excited to use this. Thanks @srivasta !

@dictvm
Copy link

dictvm commented Jun 11, 2018

@srivasta are you still on this?

@AndrewFarley
Copy link

+1 Ping, inquiring minds want/need to use this feature in Terraform. :)

@danawillow danawillow self-assigned this Jul 2, 2018
@danawillow
Copy link
Contributor

Hey all, this is currently being actively worked on. Stay tuned :)

@pepnova-9
Copy link

pepnova-9 commented Aug 3, 2018

I am very excited and eager to use this.

How is this going on? @danawillow
I hope you can tell when it is available.

Thank you so much again for your work 😃.

@danawillow
Copy link
Contributor

I'm excited too! We've had a few people working on this over its lifetime, which is why it's been taking so long. We do have someone assigned to it now, who I expect will be the person to finally finish it up. I'd expect the code to be ready within the next 2-3 weeks, but if it isn't, feel free to ping me for another update.

@Zamyatin
Copy link

Hey @danawillow was wondering on an update. We have been watching this issue evolve and are quite excited to see how implementation works. I actually had a reminder set to hit y'all up :) Any news?

@danawillow
Copy link
Contributor

Thanks, good call! @SirGitsalot is working on this now, so he'll be able to give any future updates.

@AndrewFarley
Copy link

Looking forward to updates, and would happily test alpha/betas and provide feedback. :) Let us know!

@hayesgm
Copy link

hayesgm commented Sep 6, 2018

Happy also to hear a bit of updates here for forecasting.

@danawillow
Copy link
Contributor

Sorry all, I was out on vacation last week and @SirGitsalot is out all this week, so hopefully next week we'll have some news for you. #1967 is the first PR for this, which has some necessary prereqs.

@dirakx1
Copy link

dirakx1 commented Sep 7, 2018

needing this :).

@sudoforge
Copy link

Please refrain from adding comments that don't provide value, instead, prefer using reactions to show your support for an issue.

This avoids sending out an email, or otherwise generating a notification for everyone subscribed to a thread.

@chrisst chrisst assigned chrisst and unassigned danawillow Sep 21, 2018
@chrisst
Copy link
Contributor

chrisst commented Sep 21, 2018

potato
@SirGitsalot had to get pulled off, so I'll be working on this now.

@chrisst
Copy link
Contributor

chrisst commented Oct 9, 2018

The first resource is out here https://www.terraform.io/docs/providers/google/r/monitoring_alert_policy.html

I'll continue to add some of the others soon but I wanted to make sure to get alert policy in rather then let it get backed up behind several other resources.

@Red-Five
Copy link

Red-Five commented Nov 2, 2018

The first resource is out here https://www.terraform.io/docs/providers/google/r/monitoring_alert_policy.html

I'll continue to add some of the others soon but I wanted to make sure to get alert policy in rather then let it get backed up behind several other resources.

@chrisst Thanks for the policy functionality!
Incase you would like some input on priority ; we would welcome the ability to add a project to a Stackdriver Workspace and the ability to create groups.

@chrisst
Copy link
Contributor

chrisst commented Nov 13, 2018

Stackdriver Groups: #2451

@chrisst
Copy link
Contributor

chrisst commented Nov 13, 2018

Stackdriver Notification Channels: #2452

@chrisst
Copy link
Contributor

chrisst commented Nov 28, 2018

Uptime Checks: #2502

@chrisst
Copy link
Contributor

chrisst commented Dec 14, 2018

All of the stackdriver monitoring resources that are available in the apis got released in v1.20.0 this morning. Closing this now, if there are new features or bugs please open new tickets.

@chrisst chrisst closed this as completed Dec 14, 2018
@mdz
Copy link

mdz commented Dec 16, 2018

Thanks, @chrisst!

@dannycohn
Copy link

@chrisst I don't see any documentation for creating log metrics via TF. Am I missing something?

@chrisst
Copy link
Contributor

chrisst commented Dec 17, 2018

@dannycohn I'm keeping this PR scoped to the stackdriver monitoring api as "stackdriver" is now a whole suite of different apis. Creating log metrics is under the logging.googleapis.com namespace so I didn't include it in these additions, but please file a new issue requesting it and we'll get to it as soon as we can!

@dannycohn
Copy link

@dannycohn I'm keeping this PR scoped to the stackdriver monitoring api as "stackdriver" is now a whole suite of different apis. Creating log metrics is under the logging.googleapis.com namespace so I didn't include it in these additions, but please file a new issue requesting it and we'll get to it as soon as we can!

Looks like one exists #1236

@sergei-ivanov
Copy link

I updated the provider and gave it a go today. Unfortunately, the documentation on Terraform site has not been updated yet (at the time of writing), so I had to go back to the PRs and look up the resource descriptions there.

I was able to import the existing uptime checks and alerting policies, and reconcile the terraform view against the actual state. It looks like email notification channels are created ad hoc when editing the policy, but it was possible to pre-create them via terraform and reuse across a number of alerting policies.

The only snag is that after reapplying the alerting policies that used to have uptime checks in their conditions, these conditions are no longer recognised/displayed as uptime checks in the cloud console. Instead they look like ad hoc custom conditions. This is probably a Google Cloud thing, because I have done gcloud alpha monitoring policies list before and after applying terraform changes, and there are no differences in the conditions there.

@chrisst
Copy link
Contributor

chrisst commented Dec 17, 2018

@sergei-ivanov I added an uptime check and alert policy via the UI and imported them into TF but running apply (after I had resolved all the diffs) hasn't changed how the UI displays the alert policy. If you open a bug with sufficient repro steps and some screen shots I'd be happy to talk with the stack driver team and see if it's a bug upstream.

@sergei-ivanov
Copy link

@chrisst have you tried changing it slightly before applying to force a change through the API? In my case the applied difference was in display name and the list of notifications (which resulted in an in-place modification). It was an old policy introduced a couple of months ago by hand, and I was eager to finally bring it under terraform. I'll try to set up a test policy manually tomorrow and see if I can reproduce the problem in my environment.

@sergei-ivanov
Copy link

I have found out that if I set up an uptime check from scratch in the Cloud Console UI and import it into Terraform, then it is managed by Terraform just fine, and recognised as uptime check by Cloud Console UI. Apparently there's been some change in the way the uptime check maps into raw metrics filter, and retrofitting that change into the old filters in Terraform resulted in them being recognised as uptime checks in the UI again. So that seems to be a non-issue. I'll raise separate bugs / feature requests for other issues that I've found during my testing.
Thank you for a great piece of work!

@ghost
Copy link

ghost commented Jan 14, 2019

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 [email protected]. Thanks!

@ghost ghost locked and limited conversation to collaborators Jan 14, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests