Does Pulumi not support in-place storage update f...
# general
a
Does Pulumi not support in-place storage update for timestream influxDB?
Copy code
aws:timestreaminfluxdb:DbInstance (scan-event-influxdb-eu-west-1):
    error: creating Amazon Timestream for InfluxDB DB Instance ("scan-event-influxdb-eu-west-1-instance"): operation error Timestream InfluxDB: CreateDbInstance, https response error StatusCode: 400, RequestID: 451efc9d-4854-4e44-ba88-e349b623f095, ConflictException: The DbInstance with id [989171ap4k], name [scan-event-influxdb-eu-west-1-instance], customer [590309927493] already exists: operation error Timestream InfluxDB: CreateDbInstance, https response error StatusCode: 400, RequestID: 451efc9d-4854-4e44-ba88-e349b623f095, ConflictException: The DbInstance with id [....], name [scan-event-influxdb-eu-west-1-instance], customer [...] already exists
👀 1
l
Nothing to do with Pulumi. That's an AWS restriction.
No wait.. please hold caller....
It looks like it is Pulumi that adds the replace-on-change requirement for that property. That's not right, it shouldn't be there.
It's not in the API, the AWS SDK or in Terraform.
No, I'm wrong again. According to the docs, it's not forcing a change, it's just mandatory
So the question becomes, why is it creating a new DB when it says that it won't?
Why does the error message say the name is scan-event-influxdb-eu-west-1-instance but Pulumi says the name is scan-event-influxdb-eu-west-1?
I see that this is a relatively new change. It was released in January this year by AWS. The upstream provider started supporting it in 5.91.0, which pulumi-aws upgraded to in v6.73.0. Are you using AWS plugin 6.73 or newer?
Dated March 14th. about 7 weeks after AWS and same day as upstream provider.
a
image.png
https://pulumi-community.slack.com/archives/C84L4E3N1/p1759465070498469?thread_ts=1759457723.075649&cid=C84L4E3N1 because the instance name is different pulumi resource name
Copy code
// Create the InfluxDB instance.
    this.influxDbInstance = new aws.timestreaminfluxdb.DbInstance(
      `${name}`,
      {
        name: `${name}-instance`,
        bucket,
        username,
        password,
        organization,
        dbInstanceType: 'db.influx.medium',
        dbStorageType: 'InfluxIOIncludedT1',
        allocatedStorage: 100, // In GB
        publiclyAccessible: false,
        vpcSubnetIds: privateSubnetIds,
        vpcSecurityGroupIds: [this.influxDbSecurityGroup.id],
        deploymentType: 'WITH_MULTIAZ_STANDBY',
        tags: projectTags,
      },
      { provider },
    );
👍 1
l
That's 3 minor versions after the initial release to the upstream provider. Could there have been a bug that has since been resolved? If you can, you might upgrade the plugin versions and see if it's still happening
a
Yes updating to v6.82.2 fixed the issue. Thanks Paul!!
👍 1
Also how do we configure retention policy in influxDB using pulumi?
l
Is that a configuration on the database itself? I don't think that's configurable via either the upstream provider or this one. It's not in aws-native either. If it's configurable, most likely it would be via the DB parameter group. You can use the AWS SDK for that for now, until it's supported by the providers. Or just create the parameter group via the console and hard-code the ID in your code, until the providers catch up. https://docs.aws.amazon.com/ts-influxdb/latest/ts-influxdb-api/API_CreateDbParameterGroup.html
Though I'm not sure it's there, either. I see a parameter for determining how often to check the retention policy, but not the policy itself. https://docs.aws.amazon.com/ts-influxdb/latest/ts-influxdb-api/API_InfluxDBv2Parameters.html