mirror of
https://github.com/nodejs/node.git
synced 2026-11-26 21:58:26 -05:00
src: elevate v8::Task namespace
PR-URL: https://github.com/nodejs/node/pull/26909 Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Signed-off-by: Beth Griggs <Bethany.Griggs@uk.ibm.com>
This commit is contained in:
1 parent
e40bfd899e
commit
a318cbcec0
1 file changed
+5
-5
@@ -158,9 +158,9 @@ class WorkerThreadsTaskRunner::DelayedTaskScheduler {
|
||||
}
|
||||
|
||||
uv_sem_t ready_;
|
||||
TaskQueue<v8::Task>* pending_worker_tasks_;
|
||||
TaskQueue<Task>* pending_worker_tasks_;
|
||||
|
||||
TaskQueue<v8::Task> tasks_;
|
||||
TaskQueue<Task> tasks_;
|
||||
uv_loop_t loop_;
|
||||
uv_async_t flush_tasks_;
|
||||
std::unordered_set<uv_timer_t*> timers_;
|
||||
@@ -201,7 +201,7 @@ void WorkerThreadsTaskRunner::PostTask(std::unique_ptr<Task> task) {
|
||||
pending_worker_tasks_.Push(std::move(task));
|
||||
}
|
||||
|
||||
void WorkerThreadsTaskRunner::PostDelayedTask(std::unique_ptr<v8::Task> task,
|
||||
void WorkerThreadsTaskRunner::PostDelayedTask(std::unique_ptr<Task> task,
|
||||
double delay_in_seconds) {
|
||||
delayed_task_scheduler_->PostDelayedTask(std::move(task), delay_in_seconds);
|
||||
}
|
||||
@@ -408,11 +408,11 @@ bool PerIsolatePlatformData::FlushForegroundTasksInternal() {
|
||||
return did_work;
|
||||
}
|
||||
|
||||
void NodePlatform::CallOnWorkerThread(std::unique_ptr<v8::Task> task) {
|
||||
void NodePlatform::CallOnWorkerThread(std::unique_ptr<Task> task) {
|
||||
worker_thread_task_runner_->PostTask(std::move(task));
|
||||
}
|
||||
|
||||
void NodePlatform::CallDelayedOnWorkerThread(std::unique_ptr<v8::Task> task,
|
||||
void NodePlatform::CallDelayedOnWorkerThread(std::unique_ptr<Task> task,
|
||||
double delay_in_seconds) {
|
||||
worker_thread_task_runner_->PostDelayedTask(std::move(task),
|
||||
delay_in_seconds);
|
||||
|
||||
Reference in new issue
Block a user