Johnathan Kupferer

Results 8 comments of Johnathan Kupferer

The `--namespace` option looks like it will address many of the use cases I'm looking at. I do have one use case where the watched namespace(s) are determined at runtime...

I would think it should have two separate watch streams in this example. Thank you for your exploration on this.

@nolar Perfect! I'll try it out. Thank you!

Ah! I see my confusion. I didn't understand the nature of the `stopped` parameter... rethinking my approach... What I am really trying to accomplish is scheduling an action to happen...

I suppose I could use an asnyc daemon that just sleeps? Like... ``` @kopf.daemon('kopfexamples', cancellation_timeout=1.0) async def do_timed_thing(spec, **kwargs): try: await asyncio.sleep(spec.get('delay', 10)) do_the_thing() except asyncio.CancelledError: print("We are done. Bye.")...

Though... thinking about this more... my use case could also involve the delay changing before execution. Like someone updating the `spec.delay` in the example above...

The specific delay I am implementing is an auto-delete for a resource. The operator observes the creation of the resource object which triggers an action to occur. The resource status...

I thought about using a TemporaryError here, but it did not seem appropriate to have the logs reporting errors when it wasn't an error condition. I suppose that would be...