| Commit message (Collapse) | Author | Age | Files | Lines |
| ... | |
| |
|
|
|
| |
Now one can give a partial specification of the object and still get the
other attributes to have their default values.
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
There are a few limitations of the current approach that I didn't
figure out how to solve yet:
1. when stopping the server, mainly for shutting down the Node.js
process when running the tests, we need to open and close the pipe in
write mode at least once, otherwise it hangs forever. After opening
and closing it, the "autoClose" functionality of the
`fs.createReadStream()` kicks in, and it closes, otherwise the test
hangs forever as Node.js still has open handles. That's why the
`server.close()` function has a gratuitous call to
`fs.createWriteStream(pipe).end()`: so that when stopping the server,
the pipe is always closed at least once;
2. when actually running the application, if one tries an IPC command
like:
$ echo '{ "action": "config-dump" }' > web.pipe
It works, but only for the first time. As this shell line opened the
pipe, wrote to it and then closed it, the reader that
`makePipeReader()` constructed closed, but didn't open it again. So
when running the exact same IPC command for a second time, the shell
hangs, as there is no process on the other side listening for the
command and consuming the pipe.
Shortcoming nº 2 is much more important to be solved, as we can live
with shortcoming nª 1 for some time. Both are to be fixed in the near
future.
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
|
|
| |
Add static files as in production, too.
|
| | |
|
| | |
|
| | |
|
| |
|
|
| |
instead
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
| |
Also add a `defaultInterceptors` variable in `src/hero.mjs` to avoid
needing to redefine it in every application.
|
| | |
|
| | |
|
| |
|
|
|
|
| |
- delete all SQLite Node-API code: we'll use the C++ one instead;
- implement hero.mjs, with tests!
- use ESM all over.
|
| | |
|
| | |
|
| |
|
|
| |
_POSIX_C_SOURCE
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
| |
- have dynamic discovered dependencies via `mkdeps.hs`, and also move
the listing of JavaScript files to it.
- copy over stub C files for setting up the project skeleton.
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Also in this change:
- now we call ln(1) in the "install" target without using the -r
"relative" flag, as it isn't POSIX;
- add `+` as a prefix to the "assert-tests" command, so we tell sub-make
calls to also run things in parallel. In this case, the
"make DESTDIR=... install" calls;
- use the implicit `index.js` entrypoint and do away completly with
`package.json`;
- change from `import` to `require` as Node.js ESM modules don't support
`$NODE_PATH`[0]: "NODE_PATH is not part of resolving import
specifiers. Please use symlinks if this behavior is desired." 🤦;
The parallel sub-make behaviour isn't available in current specification
of make (POSIX issue 7) but is included in the upcoming[1] version 8:
> If a rule invokes a sub-make either via the MAKE macro or via a
> command line that begins with '+', the sub-make is the same
> implementation as the make that invoked the sub-make, and the −j
> option is passed to the sub-make via the MAKEFLAGS environment
> variable with the same maxjobs value and is not overridden by a
> maxjobs value from another source (even if it has the same value), the
> sub-make shall use the same token pool as its invoking make rather
> than create a new token pool.
[0]: https://nodejs.org/api/esm.html#no-node_path
[1]: https://www.opengroup.org/austin/restricted/202x-d3/202x_d3.pdf
|
| | |
|
| |
|