curved-jordan-5346
10/28/2025, 5:58 AMcurved-jordan-5346
10/28/2025, 5:59 AMechoing-dinner-19531
10/28/2025, 9:08 AMlively-crayon-44649
10/28/2025, 9:44 AMlively-crayon-44649
10/28/2025, 9:44 AMcurved-jordan-5346
10/28/2025, 9:46 AMcurved-jordan-5346
10/28/2025, 9:49 AMlively-crayon-44649
10/28/2025, 9:50 AMlively-crayon-44649
10/28/2025, 9:50 AMcurved-jordan-5346
10/28/2025, 9:53 AMlively-crayon-44649
10/28/2025, 9:54 AM// Making this up, should probably think about whether this works/is data-race-free etc.
let locked = false
const x = new Resource("x", { ... }, {
hooks: {
beforeCreate: [() => {
while (locked) { await new Promise(resolve => setTimeout(resolve, 1_000)) }
locked = true
}],
afterCreate: [() => { locked = false }],
},
})lively-crayon-44649
10/28/2025, 9:54 AMlively-crayon-44649
10/28/2025, 9:54 AMlively-crayon-44649
10/28/2025, 9:54 AMcurved-jordan-5346
10/28/2025, 9:58 AMcurved-jordan-5346
10/31/2025, 2:30 AM...
from time import sleep
...
def sleep_hook(args: pulumiResourceHookArgs):
sleep(1)
...
_ = aws.ses.ReceiptRule(
...
opts=pulumi.ResourceOptions(
hooks=pulumi.ResourceHookBinding(
before_create=[sleep_hook],
before_update=[sleep_hook]
)curved-jordan-5346
10/31/2025, 8:38 AMpulumi-aws thx for the suggestion https://github.com/pulumi/pulumi-aws/issues/5939lively-crayon-44649
10/31/2025, 9:31 AMcurved-jordan-5346
10/31/2025, 9:48 AM