-
Notifications
You must be signed in to change notification settings - Fork 9.4k
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
New Resource: Timestream Scheduled Query #22507
Comments
How hard would this task be for a first-timer? |
Could look like... resource "aws_timestreamquery_create" {
scheduled_query_name = "example-rollup"
query_string = "SELECT [...] GROUP BY bin(time, 1m), service"
schedule_expression = "cron(0/5 * * * ? *)"
execution_role_arn = aws_iam_role.example-rollup.arn
dimension_mapping = [
{
name = "service"
value_type = "varchar"
}
]
multi_measure_mappings = {
target_measure_name = "1m"
attribute_mappings = [
{
source_column = "max"
value_type = "DOUBLE"
},
source_column = "min"
value_type = "DOUBLE
}
]
}
notification_configuration {
sns_configuration {
sns_topic = aws_sns_topic.example-rollup-results.arn
}
}
error_configuration {
s3_configuration {
bucket_name = aws_s3_bucket.example-rollup.id
object_key_prefix = "1m/"
}
}
} The API itself has support for expanding the error-report and notification-configuration blocks for additional types. |
Our company has just started using timestream, including scheduled queries, and we are a big fan of infrastructure as code. I've noticed this hasn't been picked up yet, and I'm happy to make a contribution! I'm brand new at contributing to the terraform aws provider, brand new at Go, and largely brand new at open source contributing, but will do my best 😅 . But please stop me if you know of someone else doing this work. I'm following the contribution guidelines, and created a fork here: https://github.com/jelazos7/terraform-provider-aws/tree/f-timestream-sched-query As for the resource name, i saw that was a question -- I'm thinking "aws_timestreamquery_scheduled_query" looks to be the most fitting, based on the way the sdk is structured (here's the javascript one for example: https://docs.aws.amazon.com/AWSJavaScriptSDK/latest/AWS/TimestreamQuery.html#createScheduledQuery-property) I've made a request to join slack, so I won't be so cagey about development progress. |
FYI for anyone else that gets mislead by this bug... this already exists: FYI @jelazos7 |
Darn, someone beat me to it. Awesome though, thanks!!
…On Wed, Jan 17, 2024, 4:36 PM Stu S ***@***.***> wrote:
FYI for anyone else that gets mislead by this bug... this already exists:
https://registry.terraform.io/providers/hashicorp/awscc/latest/docs/resources/timestream_scheduled_query
FYI @jelazos7 <https://github.com/jelazos7>
—
Reply to this email directly, view it on GitHub
<#22507 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAJ5EPDNYUQE56BQXOFLYBTYPA76FAVCNFSM5LUKEGR2U5DIOJSWCZC7NNSXTN2JONZXKZKDN5WW2ZLOOQ5TCOBZGY4DMNJVG42A>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
d@jelazos7 , @StuAtGit https://registry.terraform.io/providers/hashicorp/awscc/latest/docs/resources/timestream_scheduled_query. The awscc provider which this is part of is in technical preview and not recommended for production workloads, according to https://developer.hashicorp.com/terraform/tutorials/aws/aws-cloud-control?in=terraform%2Faws . Ideally, the resource for timestream scheduled queries would be added to both providers, at least while the awscc provider is in technical preview. |
Warning This issue has been closed, meaning that any additional comments are hard for our team to see. Please assume that the maintainers will not see them. Ongoing conversations amongst community members are welcome, however, the issue will be locked after 30 days. Moving conversations to another venue, such as the AWS Provider forum, is recommended. If you have additional concerns, please open a new issue, referencing this one where needed. |
This functionality has been released in v5.85.0 of the Terraform AWS Provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading. For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template. Thank you! |
Community Note
Description
A new feature for aws timestream was anounced at re:Invent 2021 called Scheduled Queries.
The current provider does not yet support creation of scheduled queries. Terraform Docs
AWS example on how to create a scheduled query using the SKD. Here
Forgive me for any mistakes in this request, this is my first time reporting an issue. 🙂
New or Affected Resource(s)
Potential Terraform Configuration
References
The text was updated successfully, but these errors were encountered: