summaryrefslogtreecommitdiff
path: root/runtime/snapshot.rs
AgeCommit message (Collapse)Author
2024-11-18feat(ext/http): Make http server parameters configurable (#26785)Yusuke Tanaka
This commit makes http server parameters configurable on the extension initialization via two callbacks users can provide. The main motivation behind this change is to allow `deno_http` users to tune the HTTP/2 server to suit their needs, although Deno CLI users will not benefit from it as no JavaScript interface is exposed to set these parameters currently. It is up to users whether to provide hook functions. If not provided, the default configuration from hyper crate will be used.
2024-11-14fix: otel resiliency (#26857)snek
Improving the breadth of collected data, and ensuring that the collected data is more likely to be successfully reported. - Use `log` crate in more places - Hook up `log` crate to otel - Switch to process-wide otel processors - Handle places that use `process::exit` Also adds a more robust testing framework, with a deterministic tracing setting. Refs: https://github.com/denoland/deno/issues/26852
2024-11-13feat: OpenTelemetry Tracing API and Exporting (#26710)snek
Initial import of OTEL code supporting tracing. Metrics soon to come. Implements APIs for https://jsr.io/@deno/otel so that code using OpenTelemetry.js just works tm. There is still a lot of work to do with configuration and adding built-in tracing to core APIs, which will come in followup PRs. --------- Co-authored-by: Luca Casonato <hello@lcas.dev>
2024-11-06fix(ext/node): better inspector support (#26471)snek
implement local inspector future changes: - wire up InspectorServer to enable open/close/url - wire up connectToMainThread Fixes https://github.com/denoland/deno/issues/25004
2024-11-04refactor(runtime/permissions): use concrete error types (#26464)Leo Kettmeir
2024-10-04refactor: improve node permission checks (#26028)David Sherret
Does less work when requesting permissions with `-A`
2024-09-30refactor: bury descriptor parsing in PermissionsContainer (#25936)David Sherret
Closes https://github.com/denoland/deno/issues/25634
2024-09-27fix(node): Pass NPM_PROCESS_STATE to subprocesses via temp file instead of ↵Nathan Whitaker
env var (#25896) Fixes https://github.com/denoland/deno/issues/25401. Fixes https://github.com/denoland/deno/issues/25841. Fixes https://github.com/denoland/deno/issues/25891.
2024-09-16refactor(permissions): split up Descriptor into Allow, Deny, and Query (#25508)David Sherret
This makes the permission system more versatile.
2024-08-27feat(ext/kv): configurable limit params (#25174)Yusuke Tanaka
This commit makes various limit parameters in `deno_kv` configurable. Currently these values are declared as constants and thus can't be modified from outside. However, there may be situations where we want to change it. This commit makes this possible by introducing a new struct `KvConfig` that needs to be given as the 2nd param in `init_ops`.
2024-08-06feat: vm rewrite (#24596)snek
rewrite vm implementation to increase compat. vm.Module+importModuleDynamically callbacks should be added in a followup.
2024-07-25refactor: decouple node resolution from deno_core (#24724)David Sherret
2024-06-12fix(ext/node): fix vm memory usage and context initialization (#23976)Divy Srivastava
Fixes https://github.com/denoland/deno/issues/22441 Fixes https://github.com/denoland/deno/issues/23913 Fixes https://github.com/denoland/deno/issues/23852 Fixes https://github.com/denoland/deno/issues/23917
2024-06-06refactor: remove `PermissionsContainer` in deno_runtime (#24119)David Sherret
Also removes permissions being passed in for node resolution. It was completely useless because we only checked it for reading package.json files, but Deno reading package.json files for resolution is perfectly fine. My guess is this is also a perf improvement because Deno is doing less work.
2024-05-08chore: enable clippy::print_stdout and clippy::print_stderr (#23732)David Sherret
1. Generally we should prefer to use the `log` crate. 2. I very often accidentally commit `eprintln`s. When we should use `println` or `eprintln`, it's not too bad to be a bit more verbose and ignore the lint rule.
2024-05-01feat(runtime): allow adding custom extensions to snapshot (#23569)Mathias Lafeldt
This makes `create_runtime_snapshot` more useful for embedders who add their own extension(s) to the runtime in build scripts. --------- Signed-off-by: Matt Mastracci <matthew@mastracci.com> Co-authored-by: Matt Mastracci <matthew@mastracci.com>
2024-04-19feat(runtime): Allow embedders to perform additional access checks on file ↵Matt Mastracci
open (#23208) Embedders may have special requirements around file opening, so we add a new `check_open` permission check that is called as part of the file open process.
2024-03-12refactor: add `deno_permissions` crate (#22236)Divy Srivastava
Issue https://github.com/denoland/deno/issues/22222 ![image](https://github.com/denoland/deno/assets/34997667/2af8474b-b919-4519-98ce-9d29bc7829f2) This PR moves `runtime/permissions` code to a upstream crate called `deno_permissions`. The `deno_permissions::PermissionsContainer` is put into the OpState and can be used instead of the current trait-based permissions system. For this PR, I've migrated `deno_fetch` to the new crate but kept the rest of the trait-based system as a wrapper of `deno_permissions` crate. Doing the migration all at once is error prone and hard to review. Comparing incremental compile times for `ext/fetch` on Mac M1: | profile | `cargo build --bin deno` | `cargo plonk build --bin deno` | | --------- | ------------- | ------------------- | | `debug` | 20 s | 0.8s | | `release` | 4 mins 12 s | 1.4s |
2024-03-05chore: upgrade deno_core (#22699)Bartek Iwańczuk
Co-authored-by: Matt Mastracci <matthew@mastracci.com>
2024-02-27chore: bump deno_core (#22596)Matt Mastracci
Migrations: - snapshot code updated - runtime stats API tweaks
2024-02-17chore: bump deno_core (#22443)Matt Mastracci
Migrations: - Use the new SnapshotSerializer for TSC/compiler snapshots
2024-02-13chore: deno_core bump (#22407)Matt Mastracci
- Adding `None` flag for warmup script. - Modify opcall trace interface to match new Rust implementation
2024-02-06refactor: don't expose worker ops to user code (#22276)Bartek Iwańczuk
2024-01-22feat(web): ImageBitmap (#21898)Leo Kettmeir
2024-01-05fix(ext/node): add fs.cp, fs.cpSync, promises.cp (#21745)Divy Srivastava
Fixes https://github.com/denoland/deno/issues/20803 Fixes https://github.com/denoland/deno/issues/21723 Performance: copying a 48GiB rust `target` folder (recursive) | Platform | `deno` | `node v21.5` | Improvement | | -------- | ------- | ------- | ------- | | macOS (APFS) | 3.1secs | 127.99 secs | **42x** | | Windows | 18.3secs | 67.2secs | **3.8x** | Copying files with varying sizes: ![image](https://github.com/denoland/deno/assets/34997667/58932652-6f7a-47f5-8504-896dc9ab4ddc)
2024-01-01chore: update copyright to 2024 (#21753)David Sherret
2023-12-11fix(ext/node): basic vm.runInNewContext implementation (#21527)Divy Srivastava
Simple implementation to support webpack (& Next.js): https://github.com/webpack/webpack/blob/87660921808566ef3b8796f8df61bd79fc026108/lib/javascript/JavascriptParser.js#L4329
2023-12-09feat: bring back WebGPU (#20812)Leo Kettmeir
Signed-off-by: Leo Kettmeir <crowlkats@toaxl.com> Co-authored-by: Kenta Moriuchi <moriken@kimamass.com> Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2023-12-04perf(node/fs): faster `existsSync` when not exists (#21458)David Sherret
2023-12-02refactor: snapshotting of runtime/ and cli/ (#21430)Bartek Iwańczuk
This commit removes some of the technical debt related to snapshotting JS code: - "cli/ops/mod.rs" and "cli/build.rs" no longer define "cli" extension which was not required anymore - Cargo features for "deno_runtime" crate have been unified in "cli/Cargo.toml" - "cli/build.rs" uses "deno_runtime::snapshot::create_runtime_snapshot" API instead of copy-pasting the code - "cli/js/99_main.js" was completely removed as it's not necessary anymore Towards https://github.com/denoland/deno/issues/21137
2023-11-15perf: static bootstrap options in snapshot (#21213)Divy Srivastava
Closes https://github.com/denoland/deno/issues/21133
2023-11-14refactor: snapshot module for deno_runtime (#21162)Divy Srivastava
Closes #21134