summaryrefslogtreecommitdiff
path: root/js/timers.ts
AgeCommit message (Collapse)Author
2019-10-04Merge deno_cli_snapshots into deno_cli (#3064)Ryan Dahl
2019-09-20js: reschedule global timer if it fires earlier than expected (#2989)Bert Belder
When the global timer fires earlier than expected, which apparently happens sometimes on server editions of Windows, we didn't call any setTimeout callbacks, but we *also* didn't reschedule the global timer to fire again later. When this situation occurred it would make deno exit abruptly if there were no other asynchronous ops running on the event loop. It could also lead to application hangs if the upcoming setTimeout callback was critical for the application to make progress.
2019-09-07Update @typescript-eslint/* to v2.1.0 (#2878)Yoshiya Hinosawa
2019-09-02Refactor snapshot build (#2825)Ryan Dahl
Instead of using core/snapshot_creator.rs, instead two crates are introduced which allow building the snapshot during build.rs. Rollup is removed and replaced with our own bundler. This removes the Node build dependency. Modules in //js now use Deno-style imports with file extensions, rather than Node style extensionless imports. This improves incremental build time when changes are made to //js files by about 40 seconds.
2019-08-30clearTimeout's params should not be bigint (#2838)迷渡
2019-08-29setTimeout's params should not be bigint (#2834)迷渡
2019-08-26bring back json ops (#2815)Bartek Iwańczuk
2019-08-24Revert json ops (#2814)Ryan Dahl
* Revert "port more ops to JSON (#2809)" This reverts commit 137f33733d365026903d40e7cde6e34ac6c36dcf. * Revert "port ops to JSON: compiler, errors, fetch, files (#2804)" This reverts commit 79f82cf10ed1dbf91346994250d7311a4d74377a. * Revert "Port rest of os ops to JSON (#2802)" This reverts commit 5b2baa5c990fbeae747e952c5dcd7a5369e950b1.
2019-08-24port more ops to JSON (#2809)Bartek Iwańczuk
2019-08-21Organize dispatch a bit (#2796)Ryan Dahl
Just some clean up reorganization around flatbuffer/minimal dispatch code. This is prep for adding a JSON dispatcher.
2019-07-18fix timer's params length (#2655)迷渡
2019-06-18fix clearTimeout.name / clearInterval.name (#2540)迷渡
2019-06-17clearTimeout should convert to number (#2539)迷渡
2019-06-13forbidden to set `this` for setTimeout (#2511)迷渡
2019-06-11set setTimeout callback's this to window objectjustjavac
2019-04-07use flatbuffer create functions to add fields (#2046)Jonathon Orsi
2019-03-30Move //libdeno to //core/libdeno (#2015)Ryan Dahl
Fixes some sed errors introduced in c43cfe. Unfortunately moving libdeno required splitting build.rs into two parts, one for cli and one for core. I've also removed the arm64 build - it's complicating things at this re-org and we're not even testing it. I need to swing back to it and get tools/test.py running for it.
2019-03-12Make timers act like normal opsRyan Dahl
This is in preperation for core integration.
2019-03-09Migrate from tslint to eslint for linting (#1905)Kitson Kelly
2019-01-26timers: use int instead of double for timeout type (#1469)bokuweb
2019-01-21chore: update license lines (#1557)Yoshiya Hinosawa
2018-11-29Upgrade to TypeScript 3.2Kitson Kelly
2018-10-24fix typos (#1083)Joseph
2018-10-17Optimization: Reuse ArrayBuffer during serialization.Ryan Dahl
2018-10-14Align JSDoc to style guide.Kitson Kelly
2018-10-08timers: fix clearTimer bugLi Hao
2018-10-04Rename fbs to msg.Ryan Dahl
2018-10-04Rename flatbuffer base.msg to base.innerRyan Dahl
This better disambiguates with the msg_generated.ts module, which in JS we call "fbs", but would be better called "msg".
2018-10-03timers: implement timers in javascriptBert Belder
2018-09-25Add SetGlobalTimeout().Ryan Dahl
To be used for a timers implementation soon.
2018-09-10fbs_util.ts -> dispatch.tsRyan Dahl
And send() -> sendSync()
2018-09-09Remove namespace from src/msg.fbsRyan Dahl
2018-09-09Map promises onto futures.Ryan Dahl
Refactors handlers.rs The idea is that all Deno "ops" (aka bindings) should map onto a Rust Future. By setting the "sync" flag in the Base message users can determine if the future is executed immediately or put on the event loop. In the case of async futures, a promise is automatically created. Errors are automatically forwarded and raised. TODO: - The file system ops in src/handler.rs are not using the thread pool yet. This will be done in the future using tokio_threadpool::blocking. That is, if you try to call them asynchronously, you will get a promise and it will act asynchronous, but currently it will be blocking. - Handlers in src/handler.rs returned boxed futures. This was to make it easy while developing. We should try to remove this allocation.
2018-08-31Refactor libdeno.send() code to reduce boilerplate.Ryan Dahl
Also removes assignCmdId as it's currently unused.
2018-08-25Prevent circular imports in ts code (#576)Francesco Borzì
2018-08-13Use `@internal` with js/timers.tsKitson Kelly
2018-08-09First pass at setTimeout with Tokio (#434)Ryan Dahl
2018-07-24Change copyrights to be 'Deno authors'.Ryan Dahl
2018-07-06Import ts file from prototype without changeRyan Dahl
From commit 559453cf6cc88283bcf8fdeccd387458f5c63165 Excluding v8worker.d.ts, main.ts, and deno.d.ts. Updates tslint.json to be original settings.