minor changes
- adjust `main` log levels - lower default upload chunk size to utilize common cache sizes
This commit is contained in:
parent
4c88ea7291
commit
f2b063ba85
2 changed files with 5 additions and 5 deletions
|
|
@ -8,7 +8,7 @@ use std::{
|
|||
|
||||
use clap::Parser;
|
||||
use console::{StyledObject, style};
|
||||
use log::{debug, info, trace};
|
||||
use log::{info, trace};
|
||||
|
||||
use shrupl::{
|
||||
AppState, Cli, error,
|
||||
|
|
@ -90,14 +90,14 @@ fn main() {
|
|||
match p {
|
||||
// Error 404 (File not found)
|
||||
error::Parameter::FileID(fid) => {
|
||||
debug!("requeueing file {fid:?}");
|
||||
info!("requeueing file {fid:?}");
|
||||
|
||||
state.abort_upload();
|
||||
}
|
||||
// Error 404 (Share not found)
|
||||
error::Parameter::ShareID(sid) => {
|
||||
// TODO ask
|
||||
debug!("rebuilding share {sid:?}");
|
||||
info!("rebuilding share {sid:?}");
|
||||
|
||||
// rebuild share
|
||||
let Ok(s) = state.rebuild_share(&args) else {
|
||||
|
|
@ -114,7 +114,7 @@ fn main() {
|
|||
};
|
||||
tries += 1;
|
||||
|
||||
debug!("State rewound, retrying last chunk (tries: {tries})");
|
||||
info!("State rewound, retrying last chunk (tries: {tries})");
|
||||
state = s;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -52,7 +52,7 @@ pub struct Cli {
|
|||
/// Chunk size for uploading, in MiB
|
||||
#[arg(
|
||||
short, long,
|
||||
default_value_t = 10, value_name = "M",
|
||||
default_value_t = 4, value_name = "M",
|
||||
value_parser = value_parser!(u32).range(1..).map(|s| s as usize),
|
||||
)]
|
||||
pub chunk_size: usize,
|
||||
|
|
|
|||
Loading…
Reference in a new issue