Skip to content

Commit e43ec20

Browse files
fmt changes
1 parent 83be66f commit e43ec20

File tree

1 file changed

+52
-11
lines changed

1 file changed

+52
-11
lines changed

src/storage/localfs.rs

Lines changed: 52 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,11 @@ impl ObjectStorage for LocalFS {
137137
1,
138138
&Utc::now().date_naive().to_string(),
139139
);
140-
increment_object_store_calls_by_date("localfs", "HEAD", &Utc::now().date_naive().to_string());
140+
increment_object_store_calls_by_date(
141+
"localfs",
142+
"HEAD",
143+
&Utc::now().date_naive().to_string(),
144+
);
141145
Err(ObjectStorageError::UnhandledError(Box::new(
142146
std::io::Error::new(
143147
std::io::ErrorKind::Unsupported,
@@ -164,7 +168,11 @@ impl ObjectStorage for LocalFS {
164168
1,
165169
&Utc::now().date_naive().to_string(),
166170
);
167-
increment_object_store_calls_by_date("localfs", "GET", &Utc::now().date_naive().to_string());
171+
increment_object_store_calls_by_date(
172+
"localfs",
173+
"GET",
174+
&Utc::now().date_naive().to_string(),
175+
);
168176
Ok(x.into())
169177
}
170178
Err(e) => {
@@ -234,8 +242,13 @@ impl ObjectStorage for LocalFS {
234242
"localfs",
235243
"LIST",
236244
files_scanned,
237-
&Utc::now().date_naive().to_string());
238-
increment_object_store_calls_by_date("localfs", "LIST", &Utc::now().date_naive().to_string());
245+
&Utc::now().date_naive().to_string(),
246+
);
247+
increment_object_store_calls_by_date(
248+
"localfs",
249+
"LIST",
250+
&Utc::now().date_naive().to_string(),
251+
);
239252
Ok(path_arr)
240253
}
241254

@@ -423,7 +436,11 @@ impl ObjectStorage for LocalFS {
423436
1,
424437
&Utc::now().date_naive().to_string(),
425438
);
426-
increment_object_store_calls_by_date("localfs", "PUT", &Utc::now().date_naive().to_string());
439+
increment_object_store_calls_by_date(
440+
"localfs",
441+
"PUT",
442+
&Utc::now().date_naive().to_string(),
443+
);
427444
}
428445
Err(_) => {
429446
STORAGE_REQUEST_RESPONSE_TIME
@@ -483,7 +500,11 @@ impl ObjectStorage for LocalFS {
483500
1,
484501
&Utc::now().date_naive().to_string(),
485502
);
486-
increment_object_store_calls_by_date("localfs", "DELETE", &Utc::now().date_naive().to_string());
503+
increment_object_store_calls_by_date(
504+
"localfs",
505+
"DELETE",
506+
&Utc::now().date_naive().to_string(),
507+
);
487508
}
488509
Err(err) => {
489510
let status_code = match err.kind() {
@@ -511,7 +532,11 @@ impl ObjectStorage for LocalFS {
511532
STORAGE_REQUEST_RESPONSE_TIME
512533
.with_label_values(&["localfs", "HEAD", "200"])
513534
.observe(check_elapsed);
514-
increment_object_store_calls_by_date("localfs", "HEAD", &Utc::now().date_naive().to_string());
535+
increment_object_store_calls_by_date(
536+
"localfs",
537+
"HEAD",
538+
&Utc::now().date_naive().to_string(),
539+
);
515540
}
516541
Err(err) => {
517542
let status_code = match err.kind() {
@@ -603,7 +628,11 @@ impl ObjectStorage for LocalFS {
603628
STORAGE_REQUEST_RESPONSE_TIME
604629
.with_label_values(&["localfs", "LIST", "200"])
605630
.observe(list_elapsed);
606-
increment_object_store_calls_by_date("localfs", "LIST", &Utc::now().date_naive().to_string());
631+
increment_object_store_calls_by_date(
632+
"localfs",
633+
"LIST",
634+
&Utc::now().date_naive().to_string(),
635+
);
607636
ReadDirStream::new(read_dir)
608637
}
609638
Err(err) => {
@@ -650,7 +679,11 @@ impl ObjectStorage for LocalFS {
650679
STORAGE_REQUEST_RESPONSE_TIME
651680
.with_label_values(&["localfs", "LIST", "200"])
652681
.observe(list_elapsed);
653-
increment_object_store_calls_by_date("localfs", "LIST", &Utc::now().date_naive().to_string());
682+
increment_object_store_calls_by_date(
683+
"localfs",
684+
"LIST",
685+
&Utc::now().date_naive().to_string(),
686+
);
654687
ReadDirStream::new(read_dir)
655688
}
656689
Err(err) => {
@@ -778,7 +811,11 @@ impl ObjectStorage for LocalFS {
778811
STORAGE_REQUEST_RESPONSE_TIME
779812
.with_label_values(&["localfs", "LIST", "200"])
780813
.observe(list_elapsed);
781-
increment_object_store_calls_by_date("localfs", "LIST", &Utc::now().date_naive().to_string());
814+
increment_object_store_calls_by_date(
815+
"localfs",
816+
"LIST",
817+
&Utc::now().date_naive().to_string(),
818+
);
782819
read_dir
783820
}
784821
Err(err) => {
@@ -867,7 +904,11 @@ impl ObjectStorage for LocalFS {
867904
STORAGE_REQUEST_RESPONSE_TIME
868905
.with_label_values(&["localfs", "PUT", "200"])
869906
.observe(upload_elapsed);
870-
increment_object_store_calls_by_date("localfs", "PUT", &Utc::now().date_naive().to_string());
907+
increment_object_store_calls_by_date(
908+
"localfs",
909+
"PUT",
910+
&Utc::now().date_naive().to_string(),
911+
);
871912
Ok(())
872913
}
873914
Err(err) => {

0 commit comments

Comments
 (0)