Skip to main content

Update, renew and destroy

A site belongs to the address that owns its Site object and its blobs. Only that address can change it: the tools and the network reject changes from anyone else.

In the app, My sites lists the Site objects of your wallet with their URL and offers these three operations. In the CLI they are actualizar/desplegar, renovar and destruir (see Sites CLI). Both work the same way, described below.

Update​

Updating publishes a new version of the folder on the same Site, so the URL does not change.

  1. The files are compared with the published site by their SHA-256. Files with the same content are not uploaded again: they keep their blob and their patch. If only their headers change, the resource is recreated on IOTA with the same patch.
  2. The blobs still in use are renewed up to the current epoch plus the epochs you choose. If one of them no longer belongs to you or has expired, its files are uploaded again.
  3. New and changed files are uploaded in new quilts.
  4. The Site is updated: resources, routes, redirects, name and metadata. Large changes are split into as many transactions as needed (up to about 900 calls and 100 KB each).
  5. Finally, the deletable blobs that no resource uses any more are deleted.

Updating with the same files and more epochs uploads nothing: it only renews the blobs.

Renew​

Renewing extends the blobs that the site uses, without uploading anything: each blob whose end epoch is earlier than the current epoch plus the chosen epochs is extended up to that epoch, paying only storage (no write fee).

  • One purchase covers at most 53 epochs from now.
  • If you no longer have a valid Blob for some file of the site (it expired or you transferred it), it cannot be renewed: publish the site again (update) to upload those files.
  • There is no automatic renewal service for user sites yet. Renew before the end epoch.

Destroy​

Destroying removes the site for good:

  1. The deletable blobs of the site that you own are deleted.
  2. The resources, routes and redirects are removed from the Site, so their storage deposits come back to you.
  3. The Site object is burned.

It cannot be undone: publishing the folder again creates a new Site, with a new ID and URL. Any IOTA Names name that pointed to the old one must be pointed to the new one.

The nodes delete the data of a blob only when no Blob registers that blob ID any more. If another site (yours or someone else's) has exactly the same files, its quilt has the same blob ID and stays available.

Costs​

  • Updating pays storage for the new quilts, the renewal of the blobs in use and the gas of the transactions. Each new resource has a deposit of about 0.005 IOTA; replaced resources return theirs.
  • Renewing pays only storage and gas.
  • Destroying pays gas and returns the deposits: on testnet, destroying a small example site of 4 files returned 0.019 IOTA net.