Is there a way to set up a canister such that it refuses any cycle top-ups from external parties?
If there is such a way, why should I delete a canister instead of just black hole-ing it?
Let’s say I want to spin down a canister, here are the following steps for:
1. Deleting a Canister
Transfer cycles
Stop canister
Delete canister
Canister is now deleted
2. Cycle Drain + Black Hole-ing a Canister
Transfer cycles (only leave enough cycles to perform step 2)
Black hole canister (remove self and update controller to the black hole canister)
Canister is now black holed and frozen (non-responsive)
Question: If I can just cycle drain and black hole a canister in 2 async steps to effective delete it, what’s the incentive to take 3 async steps to actually delete a canister?
If a canister is cycle drained, it doesnt get immediately deleted. There is a grace period. What if you wanted your canister to get immediately deleted?
Maybe a usecase for deletion is if you wanted to have compassion for the canister and put it out of it’s misery, rather than leaving it in that existential limbo that you describe
There’s another reason for not wanting to actually delete your canisters: you can always re-use them, without having to pay 0.1T for each canister_create. I believe unistall_code should make them consume 0 cycles (need confirmation on that), and you’d still be able to re-install using the same private key for a long time (currently ~10 years from what I’ve read).
Right, this is to the wallet canister, not a user specified canister - so better to use transfer_cycles beforehand if you want control of where your cycles end up.
Curious if anyone can confirm the above, as well about what amount of space an uninstalled canister occupies on a subnet.
Also, one could just leave the code installed but have it reject every message via inspect_message - I wonder how close this would come to 0 cycles in cost
Based on what I’ve outlined above, if I cycle drain + black hole a canister that’s only 2 inter-canister calls vs. 3 inter-canister calls for draining & deleting the canister, meaning one less step where a message could fail to reach the management canister.