Skip to content
This repository has been archived by the owner on Nov 24, 2021. It is now read-only.

Commit

Permalink
chore: bump to 1.6.3
Browse files Browse the repository at this point in the history
  • Loading branch information
d33d33 committed Jun 22, 2017
1 parent db534df commit 9f475c2
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "beamium"
version = "1.6.2"
version = "1.6.3"
authors = [ "d33d33 <[email protected]>" ]

build = "build.rs"
Expand Down
10 changes: 5 additions & 5 deletions src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ pub struct Parameters {
pub scan_period: u64,
pub sink_dir: String,
pub source_dir: String,
pub batch_size: i64,
pub batch_size: u64,
pub batch_count: u64,
pub log_file: String,
pub log_level: slog::Level,
Expand Down Expand Up @@ -393,8 +393,8 @@ fn load_path<P: AsRef<Path>>(file_path: P, config: &mut Config) -> Result<(), Co
let batch_size = try!(doc["parameters"]["batch-size"]
.as_i64()
.ok_or(format!("parameters.batch-size should be a number")));
//let batch_size = try!(cast::u64(batch_size)
// .map_err(|_| format!("parameters.batch-size is invalid")));
let batch_size = try!(cast::u64(batch_size)
.map_err(|_| format!("parameters.batch-size is invalid")));
config.parameters.batch_size = batch_size;
}

Expand Down Expand Up @@ -427,8 +427,8 @@ fn load_path<P: AsRef<Path>>(file_path: P, config: &mut Config) -> Result<(), Co

if !doc["parameters"]["syslog"].is_badvalue() {
let syslog = try!(doc["parameters"]["syslog"]
.as_bool()
.ok_or("parameters.bool should be a boolean"));
.as_bool()
.ok_or("parameters.bool should be a boolean"));
config.parameters.syslog = syslog;

}
Expand Down
2 changes: 1 addition & 1 deletion src/sink/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ pub struct Sink<'a> {
token_header: &'a String,
url: &'a String,
batch_count: u64,
batch_size: i64,
batch_size: u64,
max_size: u64,
ttl: u64,
parallel: u64,
Expand Down
6 changes: 3 additions & 3 deletions src/sink/send.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ pub fn send_thread(token: &str,
todo: Arc<Mutex<VecDeque<PathBuf>>>,
timeout: u64,
batch_count: u64,
batch_size: i64,
batch_size: u64,
sigint: Arc<AtomicBool>) {
loop {
Data::new(sigint.clone(), todo.clone(), batch_count, batch_size)
Expand Down Expand Up @@ -111,12 +111,12 @@ impl Data {
pub fn new(sigint: Arc<AtomicBool>,
todo: Arc<Mutex<VecDeque<PathBuf>>>,
batch_count: u64,
batch_size: i64)
batch_size: u64)
-> Option<Data> {
let mut d = Data {
sigint: sigint,
batch_count: batch_count,
batch_size: batch_size,
batch_size: batch_size as i64,
todo: todo,
processing: None,
processed: Vec::new(),
Expand Down

0 comments on commit 9f475c2

Please sign in to comment.