Skip to content

Commit e3f8654

Browse files
committed
Separate out triage and comparison implementation
1 parent 94f0f7f commit e3f8654

File tree

4 files changed

+590
-529
lines changed

4 files changed

+590
-529
lines changed

site/src/api.rs

Lines changed: 3 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,8 @@
1313
//!
1414
//! The responses are calculated in the server.rs file.
1515
16-
use database::{Crate, Date};
16+
use database::Crate;
1717
use serde::{Deserialize, Serialize};
18-
use std::collections::HashMap;
1918
use std::fmt;
2019
use std::result::Result as StdResult;
2120

@@ -40,17 +39,6 @@ impl Serialize for StyledBenchmarkName {
4039
}
4140
}
4241

43-
/// Data associated with a specific date
44-
#[derive(Debug, Clone, Serialize)]
45-
pub struct DateData {
46-
pub date: Option<Date>,
47-
pub pr: Option<u32>,
48-
pub commit: String,
49-
pub data: HashMap<String, Vec<(String, f64)>>,
50-
// crate -> nanoseconds
51-
pub bootstrap: HashMap<String, u64>,
52-
}
53-
5442
pub type ServerResult<T> = StdResult<T, String>;
5543

5644
pub mod info {
@@ -92,7 +80,7 @@ pub struct CommitResponse {
9280
}
9381

9482
pub mod data {
95-
use crate::api::DateData;
83+
use crate::comparison::DateData;
9684
use collector::Bound;
9785
use serde::{Deserialize, Serialize};
9886

@@ -178,7 +166,7 @@ pub mod bootstrap {
178166
}
179167

180168
pub mod days {
181-
use crate::api::DateData;
169+
use crate::comparison::DateData;
182170
use collector::Bound;
183171
use serde::{Deserialize, Serialize};
184172

0 commit comments

Comments
 (0)