Currently, the RustlsConfig can be configured with a fallback RustlsCertificate whose key and cert are preloaded bytes.
In reality, key and cert files can be updated periodically. Requiring a restart to reload the tls configs can be too expensive.
In GreptimeDB, there is a tech to reload files and the bytes will be read every time a new connection is established:
https://github.com/GreptimeTeam/greptimedb/blob/a283e13da744b6bbe3b08e7b0940ac2d3e03e4c6/src/servers/src/tls.rs#L169-L175
Currently, the RustlsConfig can be configured with a fallback RustlsCertificate whose key and cert are preloaded bytes.
In reality, key and cert files can be updated periodically. Requiring a restart to reload the tls configs can be too expensive.
In GreptimeDB, there is a tech to reload files and the bytes will be read every time a new connection is established:
https://github.com/GreptimeTeam/greptimedb/blob/a283e13da744b6bbe3b08e7b0940ac2d3e03e4c6/src/servers/src/tls.rs#L169-L175