Jarred Sumner
c99059db9f
Remove usages of std.x
2023-01-03 18:53:40 -08:00
Jarred Sumner
c0dd284136
Upgrade to latest Zig ( #1610 )
...
* @min and @max
* builtins and some trivial ones
* Most of them
* more
* more!
* More Progress
* wip
* Update tagged_pointer.zig
* Update http_client_async.zig
* Most of the iterable dir changes
* alright
* Remove usages of deprecated formatters
* 📷
* fmt
* Update shimmer.zig
* wip
* wip
* wip
* progress
* more
* Latest
* stuck on error
* latest
* workaround stage2
* wip
* Update string_immutable.zig
* wip
* Migrate `Dirent` and `require("fs')` to use JSC<>Zig bindings
* Fix build errors
* Fixup most of the test failures
* Fix `make headers`
* Fix "outside package path" error
* Fixup aligned alloc
* Add missing file
* linux
* More linux fixes
* use latest peechy
* Fix transpiler test failure
* Forgot about these
* Fixup test failure
* Update node-timers.test.ts
* [node:htt] Fix `undefined is not an object` error
Fixes https://github.com/oven-sh/bun/issues/1618
* Update http.exports.js
* Make this test less flaky
* fix hashes
* Fix hex formatting and zls issues
* Download zig version
* Update Dockerfile
* Update Dockerfile
* Update uws
* Update Dockerfile
* Set llvm version
* Update README.md
* Update uws
* Update Dockerfile
* Update io_linux.zig
* Update bun.zig
* Log output
* workaround strange @cInclude error
* Make ffi tests better
* Don't use cImport
* Update c.zig
* Update c-bindings.cpp
* call setOutputDir
* Update Dockerfile
* Use a longer name
* latest
* Update serve.test.ts
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
Co-authored-by: Veikka Tuominen <git@vexu.eu >
2022-12-28 00:51:22 -08:00
Jarred Sumner
714ce7619d
[internal] Make string comparisons faster
2022-12-04 06:53:53 -08:00
Jarred Sumner
9f4d7690ac
[fetch] Treat 302 like 303
2022-12-01 21:15:34 -08:00
Jarred Sumner
5854d39525
[fetch] Implement redirect: "manual"
2022-12-01 21:09:43 -08:00
Jarred Sumner
b631ea7d72
import everything from "bun" where possible
2022-11-29 02:42:56 -08:00
Jarred Sumner
a4b67ccbff
fix protocol relative urls again
2022-11-20 07:03:50 -08:00
Jarred Sumner
003237b086
Typo
2022-11-20 01:45:57 -08:00
Jarred Sumner
e41d7a0bd5
[fetch] Add optimization for chunked encoding
2022-11-20 01:43:40 -08:00
Jarred Sumner
b230e7a73a
[fetch] Fix sporadic data corruption bug in HTTP client and add fast path
...
- This removes memory pooling from the HTTP client which sometimes caused invalid memory to be written to the response body.
- This adds a fast path for small HTTP/HTTPS responses that makes it a single memory allocation for the response body, instead of copying & allocating a temporary buffer
cc @Electroid
2022-11-19 22:34:57 -08:00
Jarred Sumner
cac11ee826
[fetch] Fix bug with redirecting to a protocol-relative URL
2022-11-19 22:14:10 -08:00
Jarred Sumner
f8d9a8be87
[fetch] Fix bug with redirects losing the port number
2022-11-19 22:13:30 -08:00
Dylan Conway
c4cf38601b
switch default encoding order ( #1510 )
2022-11-14 22:00:45 -08:00
Jarred SUmner
1cce9da80a
Fix memory leak in gzip pool + add test for gzip'd data
2022-11-12 18:32:53 -08:00
Jarred Sumner
21bf3ddaf2
Redo how we poll pipes ( #1496 )
...
* Fix pipe
* Handle unregistered
* Fix failing test
2022-11-12 18:30:12 -08:00
Jarred Sumner
da257336b0
Fix #1354
2022-11-09 15:11:14 -08:00
Jarred Sumner
d90a638101
Re-enable workaround for 127.0.0.01
2022-11-09 01:12:35 -08:00
Jarred Sumner
02c920f4fd
TCP & TLS Socket API ( #1374 )
...
* TCP Socket API
* Wip
* Add snippet for StringDecoder
* Rename `close` to `stop`, replace `close` with `end`
* Add a tcp echo server test
* Some docs
* Update README.md
* Fix build
* Update README.md
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
2022-10-25 00:44:25 -07:00
Jarred Sumner
820e6605f8
Simplify the code that reads HTTP client request bodies
2022-10-15 22:47:18 -07:00
Jarred Sumner
c2c9173eff
Fix https://github.com/oven-sh/bun/issues/1263
...
What happened: when moving to uSockets for the http client, I forgot to call `SSL_set_tlsext_host_name` and uSockets apparently doesn't do that
2022-10-08 01:06:35 -07:00
Jarred Sumner
cd9b47315c
Reduce memory usage of HTTP requests by 8 KB
2022-10-02 01:59:59 -07:00
Jarred Sumner
8d11ab3c35
Verbose flag
2022-09-30 01:05:40 -07:00
Jarred Sumner
f0bc50eb71
meant to include this in the previous commit
2022-09-20 00:45:19 -07:00
Jarred Sumner
9754c5b32b
Fix larger bodies
2022-09-19 05:50:10 -07:00
Jarred Sumner
3a50ae92ec
Fix broken sending http body
2022-09-18 04:00:40 -07:00
Jarred Sumner
fe77f6a2f3
Update http_client_async.zig
2022-09-18 02:34:58 -07:00
Jarred Sumner
cd35218141
Add a way to disable timeout and keepalive
2022-09-18 02:30:52 -07:00
Jarred Sumner
745cc5c655
Handle missing 0\r\n chunk in HTTP client
2022-09-17 21:45:03 -07:00
Jarred Sumner
3719c3b736
Update & configure SSL a little
2022-09-17 21:45:03 -07:00
Jarred Sumner
4b9f6baf79
Make fetch throw a SystemError on reject
2022-09-16 22:50:46 -07:00
Jarred Sumner
a675cbd13b
Fix issue with chunked transfer encoding
2022-09-16 22:38:09 -07:00
Jarred Sumner
0ce709d96a
Make new HTTP client more stable
2022-09-16 00:53:03 -07:00
Jarred Sumner
0935ab14d6
Fix Linux 200ms http client delay
...
https://man7.org/linux/man-pages/man2/send.2.html See the section on MSG_MORE
2022-09-13 17:47:50 -07:00
Jarred Sumner
0130efeedf
Hardcode localhost on macOS
2022-09-11 14:59:48 -07:00
Jarred Sumner
9a5aa059f9
New HTTP client ( #1231 )
...
* wip
* It mostly works!
* Support `bun install`
* Support `bun create`
* Support chunked transfer encoding
* Handle Keep Alive when redirecting to a different domain
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
2022-09-11 13:37:17 -07:00
Jarred Sumner
7b628ca09c
Fixes https://github.com/oven-sh/bun/issues/1127
2022-08-29 03:26:07 -07:00
Jarred Sumner
c1734c6ec5
More reliable macOS event loop ( #1166 )
...
* More reliable macOS event loop
* Reduce CPU usage of idling
* Add another implementation
* Add benchmark
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com >
2022-08-28 21:28:05 -07:00
Jarred Sumner
ac20150d04
Update http_client_async.zig
2022-08-17 08:18:13 -07:00
Jarred Sumner
93b663e43d
New Zig <> C++ bindings generator. +20% faster HTTP server
2022-08-17 07:37:14 -07:00
Jarred SUmner
0815c83974
Improve event loop reliability on Linux
2022-08-13 06:07:18 -07:00
Jarred Sumner
5d7ed5cbce
Improve memlock limit error
2022-08-07 16:51:14 -07:00
Jarred Sumner
105350b826
Mention WSL version requirement
2022-07-22 12:20:04 -07:00
r00ster91
16452c16da
Remove unnecessary Output.flushs before Global.exit and Global.crash ( #535 )
...
* fix: add missing newline
* refactor: std.process.exit -> Global.exit
* fix: std.os.abort -> Global.exit
I'm not sure about this one. Please verify.
* cleanup: remove unnecessary `Output.flush`s
2022-07-10 06:44:57 -07:00
Jarred Sumner
fb6d438485
Fix copy
2022-07-07 03:33:05 -07:00
Jarred Sumner
e4670b7513
Improve error message for outdated linux kernel
2022-07-06 23:30:19 -07:00
Jarred Sumner
66a297888f
Remove incorrect assertion
2022-06-29 04:29:42 -07:00
Jarred Sumner
07050901a6
[fetch] Fix data corruption bug
2022-06-27 05:29:25 -07:00
Jarred Sumner
cf0ee82926
this assertion isn't good enough
2022-06-22 06:56:47 -07:00
Jarred Sumner
a37f86e89d
bun:sqlite (#167 )
...
* ✂️
* Add the slow version
* draw the rest of the owl
* Fix crash when allocating lots of memory
* [Bun.Transipiler] Support passing objects
* [JS Parser] Support passing objects to macros via Bun.Transpiler
* Update JSSQLStatement.cpp
* Embed SQLite
* Add SQLite to Dockerfile
* [sqlite] Add quick one-off queries without creating a whole object
* [sqlite] Add `columnsCount`, rename raw() to `values()`, remove `rebind`
* Implement `bun:sqlite`
* return null
* Fix updating query
* Update bun.d.ts
* more tests
* Support variadic arguments, write tests and add types
* Update sqlite.d.ts
* Update sqlite.d.ts
* latest
* Implement `Database.loadExtension` and `Database.setCustomSQLite`
* Support `require.resolve`
* [napi] Improve string performance
* [bun.js] Support some of `node:module`
* another test
* [sqlite] Support serialize & deserialize
* [`bun:ffi`] Implement `CFunction` and `linkSymbols`
* [bun.js] Fix crash in `Buffer.from`
* Update sqlite.test.js
* Document linkSymbols
* docs
* Update README.md
2022-05-16 15:46:20 -07:00
Jarred Sumner
3e969244ac
[bun.js] Add a Server.stop function
2022-04-11 04:58:29 -07:00