This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
description: Guidelines for performing data migrations on convex | |
globs: convex/** | |
alwaysApply: false | |
--- | |
Data migrations are really easy on Convex. | |
# Adding a new field | |
Here's the general flow for adding a new field. Let's say we have a messages table | |
```ts | |
// convex/schema.ts |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#![feature(test)] | |
extern crate rayon; | |
extern crate test; | |
#[cfg(test)] | |
mod tests { | |
use test::Bencher; | |
use rayon::prelude::*; | |
#[bench] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BUGCHECK_STR: STATUS_ILLEGAL_INSTRUCTION | |
DEFAULT_BUCKET_ID: STATUS_ILLEGAL_INSTRUCTION | |
LAST_CONTROL_TRANSFER: from 730e1068 to 73127b68 | |
STACK_TEXT: | |
0014f084 730e1068 0000004c 0014f0c4 774138e7 dropbox_watchdog!std::sys::imp::ext::ffi::{{impl}}::from_wide+0xf8 | |
0014f9bc 002c10ae 00000000 00162307 00000006 dropbox_watchdog!spawn_monitoring_process+0x68 | |
WARNING: Stack unwind information not available. Following frames may be wrong. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/rust/Cargo.toml b/rust/Cargo.toml | |
index b24d5cf..c715446 100644 | |
--- a/rust/Cargo.toml | |
+++ b/rust/Cargo.toml | |
@@ -6,4 +6,6 @@ authors = [ "David Shoemaker <[email protected]>" ] | |
[dependencies] | |
image = "*" | |
+itertools = "*" | |
+rayon = "*" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Before | |
0.80user 0.00system 0:00.81elapsed 99%CPU | |
After | |
1.62user 0.02system 0:00.26elapsed 624%CPU |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[root] | |
name = "test_repo" | |
version = "0.1.0" | |
dependencies = [ | |
"slog 1.0.0-alpha3 (registry+https://github.com/rust-lang/crates.io-index)", | |
"slog-atomic 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "crossbeam" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jamwt@dash:~/contrib/repro/test_repo$ cargo build | |
Unpacking slog v1.0.0-alpha3 (registry file:///home/jamwt/contrib/repro/test_repo/../registry) | |
Compiling slog v1.0.0-alpha3 | |
Compiling test_repo v0.1.0 (file:///home/jamwt/contrib/repro/test_repo) | |
Finished debug [unoptimized + debuginfo] target(s) in 2.28 secs | |
jamwt@dash:~/contrib/repro/test_repo$ vi Cargo.toml | |
jamwt@dash:~/contrib/repro/test_repo$ cargo build | |
error: no matching package named `slog` found (required by `slog-atomic`) | |
location searched: registry https://github.com/rust-lang/crates.io-index | |
version required: * |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jamwt@dash:~/devel/client/rust/registry$ cat index/sl/og/slog | json_pp | |
{ | |
"features" : { | |
"release_max_level_off" : [], | |
"max_level_trace" : [], | |
"release_max_level_trace" : [], | |
"max_level_warn" : [], | |
"max_level_debug" : [], | |
"release_max_level_warn" : [], | |
"max_level_off" : [], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jamwt@dash:~/devel/client/rust/registry$ tar -xf slog-atomic-0.2.0.crate -O slog-atomic-0.2.0/Cargo.toml | |
[package] | |
name = "slog-atomic" | |
version = "0.2.0" | |
authors = ["Dawid Ciężarkiewicz <[email protected]>"] | |
description = "Unix terminal drain and formatter for slog-rs" | |
keywords = ["slog", "logging", "log", "atomic"] | |
license = "MPL-2.0" | |
documentation = "https://dpc.github.io/slog-rs/" | |
homepage = "https://github.com/dpc/slog-rs" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
DEBUG:cargo: handle_error; err=CliError { error: Some(no matching package named `slog` found (required by `slog-term`) | |
location searched: registry https://github.com/rust-lang/crates.io-index | |
version required: *), unknown: false, exit_code: 101 } | |
error: no matching package named `slog` found (required by `slog-term`) | |
location searched: registry https://github.com/rust-lang/crates.io-index | |
version required: * | |
jamwt@dash:~/devel/client/rust/nucleus/com |
NewerOlder