Code Monkey home page Code Monkey logo

Comments (4)

gcxfd avatar gcxfd commented on July 17, 2024

加了 RUST_BACKTRACE , 看起来是open的时候就报错了,但是还是没法定位哪儿导致的错误

RUST_BACKTRACE=1 cargo +nightly run -- /tmp/adb put 1 2
   Compiling agatedb v0.1.0 (/Users/z/rmw/rmw_feed/rust/lib/agatedb)
   Compiling adb v0.1.0 (/Users/z/rmw/rmw_feed/rust/lib/agatedb/examples/adb)
    Finished dev [unoptimized + debuginfo] target(s) in 3.18s
     Running `/Users/z/rmw/rmw_feed/rust/lib/agatedb/target/debug/adb /tmp/adb put 1 2`
[src/db.rs:223] &path = "/tmp/adb/00001.mem"
[src/db.rs:223] &path = "/tmp/adb/00002.mem"
Error: IO error: No such file or directory (os error 2)

Caused by:
    No such file or directory (os error 2)

Stack backtrace:
   0: std::backtrace_rs::backtrace::libunwind::trace
             at /rustc/27eb6d7018e397cf98d51c205e3576951d766323/library/std/src/../../backtrace/src/backtrace/mod.rs:66:5
   1: std::backtrace_rs::backtrace::trace_unsynchronized
             at /rustc/27eb6d7018e397cf98d51c205e3576951d766323/library/std/src/../../backtrace/src/backtrace/mod.rs:66:5
   2: std::backtrace::Backtrace::create
             at /rustc/27eb6d7018e397cf98d51c205e3576951d766323/library/std/src/backtrace.rs:328:13
   3: std::backtrace::Backtrace::capture
             at /rustc/27eb6d7018e397cf98d51c205e3576951d766323/library/std/src/backtrace.rs:296:9
   4: anyhow::error::<impl core::convert::From<E> for anyhow::Error>::from
             at /Users/z/.cargo/registry/src/rsproxy.cn-8f6827c7555bfaf8/anyhow-1.0.58/src/error.rs:533:25
   5: <core::result::Result<T,F> as core::ops::try_trait::FromResidual<core::result::Result<core::convert::Infallible,E>>>::from_residual
             at /rustc/27eb6d7018e397cf98d51c205e3576951d766323/library/core/src/result.rs:2125:27
   6: adb::main
             at ./main.rs:46:9
   7: core::ops::function::FnOnce::call_once
             at /rustc/27eb6d7018e397cf98d51c205e3576951d766323/library/core/src/ops/function.rs:248:5
   8: std::sys_common::backtrace::__rust_begin_short_backtrace
             at /rustc/27eb6d7018e397cf98d51c205e3576951d766323/library/std/src/sys_common/backtrace.rs:122:18
   9: std::rt::lang_start::{{closure}}
             at /rustc/27eb6d7018e397cf98d51c205e3576951d766323/library/std/src/rt.rs:145:18
  10: core::ops::function::impls::<impl core::ops::function::FnOnce<A> for &F>::call_once
             at /rustc/27eb6d7018e397cf98d51c205e3576951d766323/library/core/src/ops/function.rs:280:13
  11: std::panicking::try::do_call
             at /rustc/27eb6d7018e397cf98d51c205e3576951d766323/library/std/src/panicking.rs:492:40
  12: std::panicking::try
             at /rustc/27eb6d7018e397cf98d51c205e3576951d766323/library/std/src/panicking.rs:456:19
  13: std::panic::catch_unwind
             at /rustc/27eb6d7018e397cf98d51c205e3576951d766323/library/std/src/panic.rs:137:14
  14: std::rt::lang_start_internal::{{closure}}
             at /rustc/27eb6d7018e397cf98d51c205e3576951d766323/library/std/src/rt.rs:128:48
  15: std::panicking::try::do_call
             at /rustc/27eb6d7018e397cf98d51c205e3576951d766323/library/std/src/panicking.rs:492:40
  16: std::panicking::try
             at /rustc/27eb6d7018e397cf98d51c205e3576951d766323/library/std/src/panicking.rs:456:19
  17: std::panic::catch_unwind
             at /rustc/27eb6d7018e397cf98d51c205e3576951d766323/library/std/src/panic.rs:137:14
  18: std::rt::lang_start_internal
             at /rustc/27eb6d7018e397cf98d51c205e3576951d766323/library/std/src/rt.rs:128:20
  19: std::rt::lang_start
             at /rustc/27eb6d7018e397cf98d51c205e3576951d766323/library/std/src/rt.rs:144:17
  20: _main

from agatedb.

GanZiheng avatar GanZiheng commented on July 17, 2024
  1. 第一个问题应该来源于没有设置 AgateOptions 中的 value_dir
  2. 第二个情况是符合预期的,每次都会新增一个 mem 文件作为 memtable,其他的都是 immutable memtable。

from agatedb.

gcxfd avatar gcxfd commented on July 17, 2024

可以了,多谢。
就是感觉每次新增一个 mem 文件作为 memtable,如果做桌面端应用,长期下来会导致文件很多,最好能有一个后台进程compact下

from agatedb.

BusyJay avatar BusyJay commented on July 17, 2024

For new questions, perhaps it's better send it to Discussions.

from agatedb.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.