[pbs-devel] [PATCH proxmox-backup v2 00/16] move rest server into extra crate

Dietmar Maurer dietmar at proxmox.com
Tue Sep 21 07:58:38 CEST 2021


Changes in v2:

- renamed the crate from "pbs-server" into "proxmox-rest-server"
- depend on proxmox "0.13.3"
- worker_state: move tasktype() code to src/api2/node/tasks.rs
- dependency fixes for proxmox_restore_daemon crate (fabian)

Dietmar Maurer (16):
  start new proxmox-rest-server workspace
  move ApiConfig, FileLogger and CommandoSocket to proxmox-rest-server
    workspace
  move src/tools/daemon.rs to proxmox-rest-server workspace
  move src/server/environment.rs to proxmox-rest-server crate
  move src/server/formatter.rs to proxmox-rest-server crate
  move src/tools/compression.rs to proxmox-rest-server crate
  move normalize_uri_path and extract_cookie to proxmox-rest-server
    crate
  rest server: simplify get_index() method signature
  make get_index and ApiConfig property (callback)
  rest server: return UserInformation from ApiAuth::check_auth
  rest server: do not use pbs_api_types::Authid
  rest server: cleanup auth-log handling
  move src/server/rest.rs to proxmox-rest-server crate
  move proxmox_restore_daemon code into extra crate
  basically a (semantic) revert of commit
    991be99c37c6f55f43a3d9a2c54edb2a8dc6d4f2 "buildsys: workaround
    linkage issues from openid/curl build server stuff separate"
  worker_state: move tasktype() code to src/api2/node/tasks.rs

 Cargo.toml                                    |   5 +-
 Makefile                                      |  10 +-
 pbs-api-types/Cargo.toml                      |   2 +-
 pbs-client/Cargo.toml                         |   2 +-
 pbs-config/Cargo.toml                         |   2 +-
 pbs-datastore/Cargo.toml                      |   2 +-
 pbs-fuse-loop/Cargo.toml                      |   2 +-
 pbs-systemd/Cargo.toml                        |   2 +-
 pbs-tape/Cargo.toml                           |   2 +-
 pbs-tools/Cargo.toml                          |   2 +-
 proxmox-backup-client/Cargo.toml              |   2 +-
 proxmox-backup-debug/Cargo.toml               |   2 +-
 proxmox-file-restore/Cargo.toml               |   2 +-
 proxmox-rest-server/Cargo.toml                |  30 ++++
 .../src/api_config.rs                         |  76 +++++++--
 .../src}/command_socket.rs                    |  18 ++-
 .../src}/compression.rs                       |   0
 .../src}/daemon.rs                            |  14 +-
 proxmox-rest-server/src/environment.rs        |  94 +++++++++++
 .../src}/file_logger.rs                       |  46 +++---
 .../src}/formatter.rs                         |   0
 proxmox-rest-server/src/lib.rs                | 141 ++++++++++++++++
 .../src}/rest.rs                              | 147 +++++------------
 .../src}/state.rs                             |   4 +-
 proxmox-restore-daemon/Cargo.toml             |  36 +++++
 .../src/main.rs                               |  24 ++-
 .../src}/proxmox_restore_daemon/api.rs        |   0
 .../src}/proxmox_restore_daemon/auth.rs       |  20 ++-
 .../src}/proxmox_restore_daemon/disk.rs       |   0
 .../src}/proxmox_restore_daemon/mod.rs        |   0
 .../src}/proxmox_restore_daemon/watchdog.rs   |   0
 pxar-bin/Cargo.toml                           |   2 +-
 src/api2/access/mod.rs                        |  38 ++---
 src/api2/access/openid.rs                     | 134 ++++++++-------
 src/api2/admin/datastore.rs                   |   5 +-
 src/api2/backup/environment.rs                |   2 +-
 src/api2/node/mod.rs                          |   6 +-
 src/api2/node/tasks.rs                        |  11 +-
 src/api2/reader/environment.rs                |   2 +-
 src/backup/datastore.rs                       |   3 +-
 src/backup/verify.rs                          |   6 +-
 src/bin/proxmox-backup-api.rs                 |  56 ++++++-
 src/bin/proxmox-backup-proxy.rs               | 153 +++++++++++++++---
 src/server/auth.rs                            |  39 ++---
 src/server/environment.rs                     |  53 ------
 src/server/h2service.rs                       |   9 +-
 src/server/mod.rs                             |  21 +--
 src/server/worker_task.rs                     |  33 ++--
 src/tools/mod.rs                              |  98 -----------
 tests/worker-task-abort.rs                    |   9 +-
 50 files changed, 833 insertions(+), 534 deletions(-)
 create mode 100644 proxmox-rest-server/Cargo.toml
 rename src/server/config.rs => proxmox-rest-server/src/api_config.rs (68%)
 rename {src/server => proxmox-rest-server/src}/command_socket.rs (94%)
 rename {src/tools => proxmox-rest-server/src}/compression.rs (100%)
 rename {src/tools => proxmox-rest-server/src}/daemon.rs (97%)
 create mode 100644 proxmox-rest-server/src/environment.rs
 rename {src/tools => proxmox-rest-server/src}/file_logger.rs (81%)
 rename {src/server => proxmox-rest-server/src}/formatter.rs (100%)
 create mode 100644 proxmox-rest-server/src/lib.rs
 rename {src/server => proxmox-rest-server/src}/rest.rs (85%)
 rename {src/server => proxmox-rest-server/src}/state.rs (97%)
 create mode 100644 proxmox-restore-daemon/Cargo.toml
 rename src/bin/proxmox-restore-daemon.rs => proxmox-restore-daemon/src/main.rs (90%)
 rename {src/bin => proxmox-restore-daemon/src}/proxmox_restore_daemon/api.rs (100%)
 rename {src/bin => proxmox-restore-daemon/src}/proxmox_restore_daemon/auth.rs (63%)
 rename {src/bin => proxmox-restore-daemon/src}/proxmox_restore_daemon/disk.rs (100%)
 rename {src/bin => proxmox-restore-daemon/src}/proxmox_restore_daemon/mod.rs (100%)
 rename {src/bin => proxmox-restore-daemon/src}/proxmox_restore_daemon/watchdog.rs (100%)
 delete mode 100644 src/server/environment.rs

-- 
2.30.2






More information about the pbs-devel mailing list