How to enable s3 archival in cadence 0.13

hi team, I try to enale s3 archival in cadence 0.13

cadence --do samples-domain domain update \
  --retention 1 \
  --history_archival_status enabled \
  --history_uri s3://cadence-archival \
  --visibility_archival_status enabled \
  --visibility_uri s3://cadence-archival

got the error
Error Details: code:internal message:cadence internal uncategorized error, msg: unable to find archiver config for the given scheme

so I login cadence container, update the /etc/cadence/config/docker.yaml as

  history:
    status: "enabled"
    enableRead: true
    provider:
      s3store:
        region: "ap-south-1"
  visibility:
    status: "enabled"
    enableRead: true
    provider:
      s3store:
        region: "ap-south-1"

now how can I restart the cadence server to load the new config? or should I do the other way to enable s3 archival?

I tried the cadence-server, it only has start option
btw, I am testing it in local docker-compose env

1 Like

Looks like there are no hooks provided in our existing config_template.yaml for docker image to override defaults for archival config. Filed a feature to add support for overriding archival config.

If you are running Temporal using docker-compose then by default it brings up the server with archival turned on using file based archival config. I just filed an issue to disable it by default and have a separate docker-compose-archival.yaml for folks who want to try it out with archival turned on.

In the meantime you have to update the following 2 sections in the server config manually to override archival config:

archival:
  history:
    state: "enabled"
    enableRead: true
    provider:
      s3store:
        region: ...
        endpoint: ...
  visibility:
    state: "enabled"
    enableRead: true
    provider:
      s3store:
        region: ...
        endpoint: ...

namespaceDefaults:
  archival:
    history:
      state: "enabled"
      URI: ...
    visibility:
      state: "enabled"
      URI: ...

Thanks Samar for your reply.

I can modify the server config manually in local docker env, after that, how can I restart the cadence server to load the new config in the local docker env?

You need to bounce the process to load new config.

looks like I cannot kill the process

    1 root      0:24 cadence-server --root /etc/cadence --env docker start --services=history,matching,frontend,worker

also tried to docker restart, after that, the config /etc/cadence/config/docker.yaml was rollback to original value

You need to build your own docker image with the config updates. I filed an issue on temporal to allow passing in custom archival config.

Are these settings applicable at server level or at namespace level?
there is enable visibility archive and enable history archive at namespace too, how is this different from namespace level settings?