LCOV - code coverage report
Current view: top level - libs/compute_api/src - requests.rs (source / functions) Coverage Total Hit
Test: b4ae4c4857f9ef3e144e982a35ee23bc84c71983.info Lines: 0.0 % 3 0
Test Date: 2024-10-22 22:13:45 Functions: 0.0 % 36 0

            Line data    Source code
       1              : //! Structs representing the JSON formats used in the compute_ctl's HTTP API.
       2              : use crate::{
       3              :     privilege::Privilege,
       4              :     spec::{ComputeSpec, ExtVersion, PgIdent},
       5              : };
       6              : use serde::Deserialize;
       7              : 
       8              : /// Request of the /configure API
       9              : ///
      10              : /// We now pass only `spec` in the configuration request, but later we can
      11              : /// extend it and something like `restart: bool` or something else. So put
      12              : /// `spec` into a struct initially to be more flexible in the future.
      13            0 : #[derive(Deserialize, Debug)]
      14              : pub struct ConfigurationRequest {
      15              :     pub spec: ComputeSpec,
      16              : }
      17              : 
      18            0 : #[derive(Deserialize, Debug)]
      19              : pub struct ExtensionInstallRequest {
      20              :     pub extension: PgIdent,
      21              :     pub database: PgIdent,
      22              :     pub version: ExtVersion,
      23              : }
      24              : 
      25            0 : #[derive(Deserialize, Debug)]
      26              : pub struct SetRoleGrantsRequest {
      27              :     pub database: PgIdent,
      28              :     pub schema: PgIdent,
      29              :     pub privileges: Vec<Privilege>,
      30              :     pub role: PgIdent,
      31              : }
        

Generated by: LCOV version 2.1-beta