From d6ffabc37f95aa4beda2f815e9fad6aed71e1802 Mon Sep 17 00:00:00 2001 From: Gabriel Schulhof Date: Mon, 21 Jan 2019 23:34:46 -0800 Subject: [PATCH] n-api: mark thread-safe function as stable Fixes: https://github.com/nodejs/node/issues/24249 PR-URL: https://github.com/nodejs/node/pull/25556 Backport-PR-URL: https://github.com/nodejs/node/pull/25648 Reviewed-By: James M Snell Reviewed-By: Colin Ihrig Reviewed-By: Michael Dawson --- doc/api/n-api.md | 22 +++++++++---------- src/node_api.h | 13 ++++++----- src/node_api_types.h | 16 +++++++------- src/node_version.h | 2 +- test/addons-napi/test_general/test.js | 4 ++-- .../test_threadsafe_function/binding.c | 1 - 6 files changed, 29 insertions(+), 29 deletions(-) diff --git a/doc/api/n-api.md b/doc/api/n-api.md index f5b07532d1d631..4e15e17603e30a 100644 --- a/doc/api/n-api.md +++ b/doc/api/n-api.md @@ -171,7 +171,7 @@ This is an opaque pointer that is used to represent a JavaScript value. ### napi_threadsafe_function -> Stability: 1 - Experimental +> Stability: 2 - Stable This is an opaque pointer that represents a JavaScript function which can be called asynchronously from multiple threads via @@ -179,7 +179,7 @@ called asynchronously from multiple threads via ### napi_threadsafe_function_release_mode -> Stability: 1 - Experimental +> Stability: 2 - Stable A value to be given to `napi_release_threadsafe_function()` to indicate whether the thread-safe function is to be closed immediately (`napi_tsfn_abort`) or @@ -194,7 +194,7 @@ typedef enum { ### napi_threadsafe_function_call_mode -> Stability: 1 - Experimental +> Stability: 2 - Stable A value to be given to `napi_call_threadsafe_function()` to indicate whether the call should block whenever the queue associated with the thread-safe @@ -285,7 +285,7 @@ typedef void (*napi_async_complete_callback)(napi_env env, #### napi_threadsafe_function_call_js -> Stability: 1 - Experimental +> Stability: 2 - Stable Function pointer used with asynchronous thread-safe function calls. The callback will be called on the main thread. Its purpose is to use a data item arriving @@ -4184,7 +4184,7 @@ prevent the event loop from exiting. The APIs `napi_ref_threadsafe_function` and ### napi_create_threadsafe_function -> Stability: 1 - Experimental +> Stability: 2 - Stable