File tree Expand file tree Collapse file tree 1 file changed +12
-0
lines changed
Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -250,6 +250,18 @@ impl Server {
250250 log. new ( o ! ( "component" => "dropshot_external_techport" ) ) ,
251251 )
252252 . config ( techport_server_config)
253+ . version_policy ( dropshot:: VersionPolicy :: Dynamic ( Box :: new (
254+ dropshot:: ClientSpecifiesVersionInHeader :: new (
255+ omicron_common:: api:: VERSION_HEADER ,
256+ nexus_external_api:: latest_version ( ) ,
257+ )
258+ // Since we don't have control over all clients to the external
259+ // API, we allow the api-version header to not be specified
260+ // (picking the latest version in that case). However, all
261+ // clients that *are* under our control should specify the
262+ // api-version header.
263+ . on_missing ( nexus_external_api:: latest_version ( ) ) ,
264+ ) ) )
253265 . tls ( tls_config. map ( dropshot:: ConfigTls :: Dynamic ) )
254266 . start ( )
255267 . map_err ( |error| {
You can’t perform that action at this time.
0 commit comments