[{"data":1,"prerenderedAt":71},["ShallowReactive",2],{"blog:en:post:whats-new-in-bootgly-1-3":3},{"slug":4,"locale":5,"language":6,"title":7,"description":8,"published":9,"updated":10,"modified":9,"tags":11,"release":15,"image":10,"assisted":16,"draft":17,"reviewed":18,"path":19,"url":20,"alternates":21,"date":23,"minutes":25,"html":26,"headings":27},"whats-new-in-bootgly-1-3","en","en-US","What's new in Bootgly 1.3","Bootgly 1.3 gives the event loop its own timers and signals, and adds S3 direct transfers, legacy password verifiers, SQL::transact() and a route list.","2026-11-17T22:23:00-03:00",null,[12,13,14],"release","architecture","performance","v1.3.0",true,false,"2026-11-17","/blog/whats-new-in-bootgly-1-3/","https://bootgly.com/blog/whats-new-in-bootgly-1-3/",{"en-US":20,"pt-BR":22,"x-default":20},"https://bootgly.com/pt/blog/whats-new-in-bootgly-1-3/",{"published":24,"updated":10},"November 17, 2026",8,"\u003Cp>Bootgly 1.3 is about the event loop: recurring timers, signal handlers and the framework's own periodic work now run on the built-in loop. Around it, the release adds S3 direct transfers, verifiers for passwords imported from another stack, a unit of work in one call for SQL, the Router's route list and a storage directory taken from the environment.\u003C/p>\n\u003Cp>Every change and every commit is in the \u003Ca href=\"https://github.com/bootgly/bootgly/releases/tag/v1.3.0\" rel=\"noopener\">release notes\u003C/a>.\u003C/p>\n\u003Ch2 id=\"features\">Features\u003C/h2>\n\u003Ch3 id=\"an-event-loop-that-owns-its-timers-and-signals\">An event loop that owns its timers and signals\u003C/h3>\n\u003Cul>\n\u003Cli>\u003Cstrong>Recurring timers.\u003C/strong> A loop that implements the new optional capability \u003Ccode>ACI\\Events\\Repeating\u003C/code> — the built-in \u003Ccode>Select\u003C/code> does — runs a callback every \u003Ccode>$interval\u003C/code> seconds with \u003Ccode>repeat(float $interval, Closure $Callback, float $slack = 0.0): int\u003C/code>, down to 1 ms, stopped with the same \u003Ccode>cancel()\u003C/code> as \u003Ccode>defer()\u003C/code>. The schedule is a fixed grid, so it does not drift: a late run runs once and missed periods are skipped, and a callback that throws is reported and keeps its schedule. With a \u003Ccode>slack\u003C/code>, timers start on shared instants and wake the loop once for all of them when their interval is a whole multiple of the slack.\u003C/li>\n\u003Cli>\u003Cstrong>Signal handlers on the loop.\u003C/strong> With the optional capability \u003Ccode>ACI\\Events\\Signalling\u003C/code>, also built into \u003Ccode>Select\u003C/code>, \u003Ccode>trap(int $signal, Closure $Handler)\u003C/code> runs a handler on the loop, between callbacks, each time the process receives the signal; \u003Ccode>untrap()\u003C/code> and \u003Ccode>destroy()\u003C/code> put back what the process did before. The TCP, HTTP, WebSocket and UDP workers hand their server's signals to the loop and report a handler that throws instead of dying.\u003C/li>\n\u003Cli>\u003Cstrong>Stream readiness with a deadline.\u003C/strong> \u003Ccode>ABI\\Events\\Selector\u003C/code> waits on the monotonic clock: \u003Ccode>watch()\u003C/code>, \u003Ccode>forget()\u003C/code> and \u003Ccode>wait(null|int $deadline)\u003C/code>. A signal ends the wait with \u003Ccode>$interrupted\u003C/code> set, and waiting again with the same deadline resumes it without extending it. Every refusal is named — a closed or descriptor-less stream, a descriptor at or above \u003Ccode>FD_SETSIZE\u003C/code>, a stream closed while watched, an indefinite wait on nothing.\u003C/li>\n\u003Cli>\u003Cstrong>Sub-second SSE ticks.\u003C/strong> \u003Ccode>open(Tick: …, interval: 0.1)\u003C/code> runs the \u003Ccode>Tick\u003C/code> every 100 ms on a loop timer of its own, whatever the heartbeat.\u003C/li>\n\u003Cli>\u003Cstrong>\u003Ccode>Emitter\u003C/code> lifecycle.\u003C/strong> One-shot listeners (\u003Ccode>listen(…, once: true)\u003C/code>) and \u003Ccode>forget($Event, $Listener)\u003C/code>.\u003C/li>\n\u003Cli>\u003Cstrong>Liveness checks.\u003C/strong> \u003Ccode>Connection::watch(int $interval, null|Closure $Check = null)\u003C/code> gives a protocol its own liveness check on the worker's supervision sweep, on the built-in loop.\u003C/li>\n\u003C/ul>\n\u003Ch3 id=\"s3-direct-transfers\">S3 direct transfers\u003C/h3>\n\u003Cul>\n\u003Cli>\u003Cstrong>Presigned URLs.\u003C/strong> \u003Ccode>S3::presign()\u003C/code> lets its holder \u003Ccode>GET\u003C/code>, \u003Ccode>HEAD\u003C/code> or \u003Ccode>PUT\u003C/code> one object for up to 7 days, with no credentials; a \u003Ccode>PUT\u003C/code> can bind \u003Ccode>Content-Type\u003C/code>, \u003Ccode>Content-Length\u003C/code>, \u003Ccode>Content-MD5\u003C/code> and \u003Ccode>x-amz-meta-*\u003C/code> into the signature.\u003C/li>\n\u003Cli>\u003Cstrong>Multipart uploads from the browser.\u003C/strong> \u003Ccode>$S3-&gt;Uploads\u003C/code> creates an upload, signs its parts, lists them, and completes or aborts it. A listing gives every part or \u003Ccode>false\u003C/code>, never a partial list.\u003C/li>\n\u003Cli>\u003Cstrong>Ranged reads.\u003C/strong> \u003Ccode>S3::read($path, $sink, int $offset = 0, null|int $length = null)\u003C/code>: no byte outside the window reaches the sink.\u003C/li>\n\u003Cli>\u003Cstrong>A public SigV4 signer\u003C/strong>, \u003Ccode>S3\\Signer\u003C/code>.\u003C/li>\n\u003C/ul>\n\u003Cp>These transfers are covered by the framework's own S3 test double and the published SigV4 vectors; this release was not exercised against a live bucket.\u003C/p>\n\u003Ch3 id=\"passwords-imported-from-another-stack\">Passwords imported from another stack\u003C/h3>\n\u003Cp>\u003Ccode>new Password(Verifiers: [...])\u003C/code> reads hashes PHP cannot. Native formats always come first, and a hash that passes a verifier is rehashed with argon2id at that sign-in — \u003Ccode>Users::verify()\u003C/code> persists it. \u003Ccode>Password\\Verifiers\\PBKDF2\u003C/code> reads \u003Ccode>&lt;prefix&gt;&lt;iterations&gt;:&lt;salt&gt;:&lt;key&gt;\u003C/code> rows.\u003C/p>\n\u003Ch3 id=\"a-unit-of-work-in-one-call\">A unit of work in one call\u003C/h3>\n\u003Cp>For commands, jobs and scripts, \u003Ccode>SQL::transact(Closure $Work): mixed\u003C/code> begins, runs the work, commits every level left open and returns the result; a throwable rolls back level by level and is rethrown, and a failed \u003Ccode>COMMIT\u003C/code> throws. On every way out, the connection is back in the pool. Nested units of work are savepoints of the same transaction, so a level that throws is rolled back alone.\u003C/p>\n\u003Ch3 id=\"the-router-s-route-list\">The Router's route list\u003C/h3>\n\u003Cp>\u003Ccode>$Router-&gt;Routes\u003C/code> is a read-only list of the registered routes, complete once the Router is warm: path with its group prefix, methods, handler, the middlewares dispatch runs around it, parameters, cache options and kind. \u003Ccode>Router::warm()\u003C/code> warms the route cache without a request, so a test, a command or a tool can read the list.\u003C/p>\n\u003Ch3 id=\"the-storage-directory-from-the-environment\">The storage directory from the environment\u003C/h3>\n\u003Cp>\u003Ccode>BOOTGLY_STORAGE_DIR\u003C/code> moves logs, PIDs, sessions, locks, queues and cache without a launcher of your own, and \u003Ccode>project &lt;Name&gt; startup\u003C/code> writes it into the systemd units it generates. On the kit image, a storage volume the platform mounts empty and root-owned gets the image's layout on a root start.\u003C/p>\n\u003Ch3 id=\"worker-limits-for-web-apps\">Worker limits for Web apps\u003C/h3>\n\u003Cp>\u003Ccode>Web\\App\\Configs\u003C/code> takes \u003Ccode>headroom\u003C/code>, \u003Ccode>maxWorkerPendingBytes\u003C/code>, \u003Ccode>maxRequests\u003C/code>, \u003Ccode>jitter\u003C/code> and \u003Ccode>maxMemory\u003C/code>, and \u003Ccode>App::configure()\u003C/code> forwards them to the HTTP server; out-of-range recycling options are refused.\u003C/p>\n\u003Ch2 id=\"improvements\">Improvements\u003C/h2>\n\u003Ch3 id=\"performance\">Performance\u003C/h3>\n\u003Cul>\n\u003Cli>\u003Cstrong>Idle connections.\u003C/strong> On the built-in loop, the master watchdog, the recycle gate, the drain poll, every connection's idle expiration and the WebSocket heartbeat now ride one supervision sweep a second per worker — no timer per connection. With 10,000 idle connections on 16 workers, that is 20% less memory per connection, 18% less CPU to hold them and 37% less to expire them.\u003C/li>\n\u003Cli>\u003Cstrong>SSE streams.\u003C/strong> The streams of a worker that share an interval come due on at most 16 instants per interval (\u003Ccode>sse:1\u003C/code>: 2,260 → 2,551 events/s delivered).\u003C/li>\n\u003Cli>\u003Cstrong>\u003Ccode>Emitter\u003C/code>.\u003C/strong> An event with no listener left goes back to its zero-cost path, and an emission with one listener costs about half of what it did.\u003C/li>\n\u003C/ul>\n\u003Ch3 id=\"security\">Security\u003C/h3>\n\u003Cul>\n\u003Cli>\u003Cstrong>S3.\u003C/strong> Credentials and option values that cannot travel in a header are refused before any request, header values are signed as SigV4 specifies, a listing that does not advance stops, the secret and the session token stay out of traces and dumps, and hostile XML answers (document types, non-UTF-8, over 32 MiB) are refused.\u003C/li>\n\u003Cli>\u003Cstrong>Passwords.\u003C/strong> \u003Ccode>Password\\Verifiers\\PBKDF2\u003C/code> uses a constant-time comparison and an iteration ceiling that bounds what a tampered row can cost, and refuses at construction a prefix too long for any row. A verifier that throws fails the verification, is reported once, and never sees the password in a trace.\u003C/li>\n\u003Cli>\u003Cstrong>Storage directory.\u003C/strong> \u003Ccode>BOOTGLY_STORAGE_DIR\u003C/code> must be an absolute, canonical path to a real directory nobody else controls or can replace; an unsafe or empty value stops the boot with one line on stderr and never falls back to the default. On the kit image, nothing changes owner recursively or through a link, and \u003Ccode>Process\\Service\u003C/code> refuses an environment value systemd would drop (NUL, line break, non-UTF-8).\u003C/li>\n\u003C/ul>\n\u003Ch2 id=\"fixes\">Fixes\u003C/h2>\n\u003Cul>\n\u003Cli>\u003Cstrong>A route set registers once on a cold Router.\u003C/strong> A handler that registers with direct \u003Ccode>route()\u003C/code> calls runs again on every request while the Router is cold; each such run piled every dynamic route, group and \u003Ccode>intercept()\u003C/code> middleware on top of the last — memory grew per request and a middleware ran once per earlier run. The server now rewinds a cold Router before each run, and a registration an earlier run made keeps every \u003Ccode>intercept()\u003C/code> middleware it had — the \u003Ca href=\"#release-specific-notes\">Router note under Upgrading\u003C/a> lists the cases that still need care.\u003C/li>\n\u003Cli>\u003Cstrong>Out-of-band data no longer spins a worker.\u003C/strong> The built-in loop refuses \u003Ccode>EVENT_EXCEPT\u003C/code> registrations: nothing consumed them, and out-of-band data made the worker spin at 100% CPU.\u003C/li>\n\u003Cli>\u003Cstrong>Every server logs what it catches.\u003C/strong> A failure handed to \u003Ccode>Throwables::notify()\u003C/code> — a signal handler, a recurring timer, a shutdown listener, a WebSocket message handler — reaches the \u003Ccode>exceptions\u003C/code> log channel on TCP, WebSocket and UDP servers too, not only on HTTP.\u003C/li>\n\u003Cli>\u003Cstrong>Synchronous signal delivery.\u003C/strong> Workers start with synchronous signal delivery; a worker forked in Monitor mode used to inherit asynchronous delivery.\u003C/li>\n\u003Cli>\u003Cstrong>\u003Ccode>IO\\IPC\\Pipe::reading()\u003C/code> keeps reading\u003C/strong> after a timeout or a signal, where it ended with \u003Ccode>false\u003C/code>; it yields \u003Ccode>null\u003C/code> on each timeout.\u003C/li>\n\u003C/ul>\n\u003Ch2 id=\"upgrading\">Upgrading\u003C/h2>\n\u003Cp>Before you upgrade, check the \u003Ca href=\"#release-specific-notes\">release-specific notes\u003C/a> below: they can need an edit in your code or setup.\u003C/p>\n\u003Cp>At the kit root:\u003C/p>\n\u003Cpre class=\"shiki github-dark-default\" style=\"background-color:#0d1117;color:#e6edf3\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan style=\"color:#FFA657\">bootgly\u003C/span>\u003Cspan style=\"color:#A5D6FF\"> kit\u003C/span>\u003Cspan style=\"color:#A5D6FF\"> upgrade\u003C/span>\u003Cspan style=\"color:#A5D6FF\"> v1.3.0\u003C/span>\u003C/span>\u003C/code>\u003C/pre>\n\u003Cp>Running projects keep the code they loaded: stop them first or reload them after. Coming from a release older than \u003Ccode>v1.0.4\u003C/code>, lay down the agent rules once afterwards (\u003Ccode>bootgly kit boot --agents\u003C/code>); a kit older than \u003Ccode>v1.0.0-rc.1\u003C/code> has no \u003Ccode>kit upgrade\u003C/code> yet, and the release notes show how to move it once by hand. With Docker, pull \u003Ccode>bootgly/bootgly.kit:1.3.0\u003C/code> and start it with the same volumes: a container run without one keeps nothing, and \u003Ccode>kit upgrade\u003C/code> refuses inside the image — the image tag is the release.\u003C/p>\n\u003Ch3 id=\"release-specific-notes\">Release-specific notes\u003C/h3>\n\u003Cul>\n\u003Cli>\u003Cstrong>Routes registered on a cold Router.\u003C/strong> If a request handler registers routes with direct \u003Ccode>$Router-&gt;route()\u003C/code> calls, the routes of a run are now whole or nothing while the Router is cold: a handler that guards \u003Cstrong>part\u003C/strong> of its routes to run once (a \u003Ccode>static\u003C/code> flag, a \u003Ccode>require_once\u003C/code>) while the rest runs on every request must drop the guard or guard everything. \u003Ccode>intercept()\u003C/code> is now ignored on a warm Router, like \u003Ccode>route()\u003C/code>. Avoid the two shapes the \u003Ca href=\"https://docs.bootgly.com/manual/WPI/HTTP/HTTP_Server_CLI/Router/overview\" rel=\"noopener\">Router page\u003C/a> lists that still lose a middleware intercepted on the first run only, and build once — outside the handler — a middleware made from the request or the time, or holding what the Router cannot compare (\u003Ccode>stdClass\u003C/code>, \u003Ccode>PDO\u003C/code>, the bundled \u003Ccode>AccessLog\u003C/code>): built on every cold run, it is kept once per run.\u003C/li>\n\u003Cli>\u003Cstrong>Kit image volumes.\u003C/strong> A project whose server Configs demote to an account other than \u003Ccode>bootgly\u003C/code> is refused over a root-owned volume without \u003Ccode>sessions/\u003C/code>, as it already was over the image's own storage: hand \u003Ccode>logs/\u003C/code> and \u003Ccode>sessions/\u003C/code> to that account on the volume once (the Docker guide has the command).\u003C/li>\n\u003Cli>\u003Cstrong>Worker timers and signals.\u003C/strong> On the built-in loop, \u003Ccode>Timer::del()\u003C/code> with no argument no longer stops the framework's own worker timers, and a blocking \u003Ccode>sleep()\u003C/code> in a handler is no longer cut short every second by the alarm. A handler a server subclass installed before the fork for one of the server's own signals no longer runs in the workers.\u003C/li>\n\u003Cli>\u003Cstrong>New signatures for subclasses.\u003C/strong> \u003Ccode>SSE::open()\u003C/code> declares \u003Ccode>int|float $interval\u003C/code>; \u003Ccode>S3::read()\u003C/code> takes \u003Ccode>int $offset = 0, null|int $length = null\u003C/code>; \u003Ccode>Emitter\\Listeners::add()\u003C/code> takes \u003Ccode>bool $once = false\u003C/code> and \u003Ccode>$entries\u003C/code> is readable; \u003Ccode>Password::__construct()\u003C/code> takes \u003Ccode>array $Verifiers = []\u003C/code>; \u003Ccode>Process\\Service\u003C/code> declares \u003Ccode>public private(set) array $environment\u003C/code>; \u003Ccode>SQL\u003C/code> declares \u003Ccode>transact()\u003C/code>; \u003Ccode>Select::$excepts\u003C/code> is gone and \u003Ccode>add()\u003C/code>/\u003Ccode>del()\u003C/code> answer \u003Ccode>false\u003C/code> for \u003Ccode>EVENT_EXCEPT\u003C/code>. An override must match the new signature.\u003C/li>\n\u003Cli>\u003Cstrong>\u003Ccode>IO\\IPC\\Pipe::reading()\u003C/code>\u003C/strong> no longer ends at the first timeout: a consumer that relied on it leaves the loop with \u003Ccode>break\u003C/code> on the first \u003Ccode>null\u003C/code>.\u003C/li>\n\u003Cli>\u003Cstrong>\u003Ccode>Transaction::begin()\u003C/code>\u003C/strong> while its own \u003Ccode>BEGIN\u003C/code> is in flight is refused: await it before the next operation.\u003C/li>\n\u003C/ul>\n",[28,32,36,39,42,45,48,51,54,57,59,62,65,68],{"id":29,"text":30,"level":31},"features","Features",2,{"id":33,"text":34,"level":35},"an-event-loop-that-owns-its-timers-and-signals","An event loop that owns its timers and signals",3,{"id":37,"text":38,"level":35},"s3-direct-transfers","S3 direct transfers",{"id":40,"text":41,"level":35},"passwords-imported-from-another-stack","Passwords imported from another stack",{"id":43,"text":44,"level":35},"a-unit-of-work-in-one-call","A unit of work in one call",{"id":46,"text":47,"level":35},"the-router-s-route-list","The Router's route list",{"id":49,"text":50,"level":35},"the-storage-directory-from-the-environment","The storage directory from the environment",{"id":52,"text":53,"level":35},"worker-limits-for-web-apps","Worker limits for Web apps",{"id":55,"text":56,"level":31},"improvements","Improvements",{"id":14,"text":58,"level":35},"Performance",{"id":60,"text":61,"level":35},"security","Security",{"id":63,"text":64,"level":31},"fixes","Fixes",{"id":66,"text":67,"level":31},"upgrading","Upgrading",{"id":69,"text":70,"level":35},"release-specific-notes","Release-specific notes",1795393255615]