pub trait QueryServerConfiguration {
// Required methods
fn server_configuration(
&self,
) -> Result<Option<StoredServerConfiguration>, StorageError>;
fn store_server_configuration(
&self,
identifier: &str,
backend_url: &str,
response: &[u8],
fetched_at_ns: i64,
) -> Result<(), StorageError>;
fn record_server_configuration_conflict(
&self,
conflicting_identifier: &str,
) -> Result<(), StorageError>;
}Required Methods§
Sourcefn server_configuration(
&self,
) -> Result<Option<StoredServerConfiguration>, StorageError>
fn server_configuration( &self, ) -> Result<Option<StoredServerConfiguration>, StorageError>
The stored copy, or None when this database has never held one.
Sourcefn store_server_configuration(
&self,
identifier: &str,
backend_url: &str,
response: &[u8],
fetched_at_ns: i64,
) -> Result<(), StorageError>
fn store_server_configuration( &self, identifier: &str, backend_url: &str, response: &[u8], fetched_at_ns: i64, ) -> Result<(), StorageError>
Write the copy whole: identifier, URL, response, and fetch time. Never
touches conflicting_identifier, so a matching refresh cannot erase a
recorded conflict (CFG-053).
Sourcefn record_server_configuration_conflict(
&self,
conflicting_identifier: &str,
) -> Result<(), StorageError>
fn record_server_configuration_conflict( &self, conflicting_identifier: &str, ) -> Result<(), StorageError>
Record that the deployment answered with a different identifier (CFG-051). Does nothing when no row exists yet.