Compare commits

...

2 Commits

Author SHA1 Message Date
neri 7e2d1d8c71 Revert "add a custom response for full storage"
This reverts commit eddbeec7ef.
2022-05-09 23:07:24 +02:00
neri c6a9eae828 change repos.ctdo.de to git.ctdo.de 2022-05-09 23:04:13 +02:00
6 changed files with 9 additions and 19 deletions

View File

@ -173,20 +173,10 @@ async fn write_to_file(
))); )));
} }
} }
file.write_all(&chunk) file.write_all(&chunk).await.map_err(|write_err| {
.await log::error!("could not write file {:?}", write_err);
.map_err(|write_err| match write_err.kind() { error::ErrorInternalServerError("could not write file")
std::io::ErrorKind::StorageFull => { })?;
log::warn!("storage is full {:?}", write_err);
error::ErrorServiceUnavailable(
"storage is full, you will need to wait for some files to expire",
)
}
_ => {
log::error!("could not write file {:?}", write_err);
error::ErrorInternalServerError("could not write file")
}
})?;
} }
Ok(written_bytes) Ok(written_bytes)
} }

View File

@ -61,7 +61,7 @@ authentifizieren
<footer> <footer>
<a <a
class="repo" class="repo"
href="https://repos.ctdo.de/neri/datatrash" href="https://git.ctdo.de/neri/datatrash"
target="_blank" target="_blank"
rel="noopener noreferrer" rel="noopener noreferrer"
> >

View File

@ -19,7 +19,7 @@
<footer> <footer>
<a <a
class="repo" class="repo"
href="https://repos.ctdo.de/neri/datatrash" href="https://git.ctdo.de/neri/datatrash"
target="_blank" target="_blank"
rel="noopener noreferrer" rel="noopener noreferrer"
> >

View File

@ -21,7 +21,7 @@
<footer> <footer>
<a <a
class="repo" class="repo"
href="https://repos.ctdo.de/neri/datatrash" href="https://git.ctdo.de/neri/datatrash"
target="_blank" target="_blank"
rel="noopener noreferrer" rel="noopener noreferrer"
> >

View File

@ -17,7 +17,7 @@
<footer> <footer>
<a <a
class="repo" class="repo"
href="https://repos.ctdo.de/neri/datatrash" href="https://git.ctdo.de/neri/datatrash"
target="_blank" target="_blank"
rel="noopener noreferrer" rel="noopener noreferrer"
> >

View File

@ -28,7 +28,7 @@
<footer> <footer>
<a <a
class="repo" class="repo"
href="https://repos.ctdo.de/neri/datatrash" href="https://git.ctdo.de/neri/datatrash"
target="_blank" target="_blank"
rel="noopener noreferrer" rel="noopener noreferrer"
> >