Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deprecate get_js_plugins() #6711

Merged
merged 3 commits into from
Dec 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,15 @@
All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
and this project adheres Fto [Semantic Versioning](http://semver.org/spec/v2.0.0.html).

## [6.0.0-dev11]

[6.0.0-dev11]: https://github.com/microsoft/CCF/releases/tag/6.0.0-dev11

### Deprecated

- The function `ccf::get_js_plugins()` and associated FFI plugin system for JS is deprecated. Similar functionality should now be implemented through a `js::Extension` returned from `DynamicJSEndpointRegistry::get_extensions()`.

## [6.0.0-dev10]

Expand Down
6 changes: 0 additions & 6 deletions doc/build_apps/api.rst
Original file line number Diff line number Diff line change
Expand Up @@ -153,12 +153,6 @@ Indexing
:project: CCF
:members:

JavaScript FFI Plugins
----------------------

.. doxygenfunction:: ccf::get_js_plugins
:project: CCF

HTTP Entity Tags Matching
-------------------------

Expand Down
3 changes: 2 additions & 1 deletion include/ccf/app_interface.h
Original file line number Diff line number Diff line change
Expand Up @@ -53,11 +53,12 @@ namespace ccf
*/
std::unique_ptr<ccf::endpoints::EndpointRegistry> make_user_endpoints(
ccf::AbstractNodeContext& context);
// SNIPPET_END: app_interface

/** To be implemented by the application.
*
* @return Vector of JavaScript FFI plugins
*/
CCF_DEPRECATED("Deprecated from 6.0.0")
std::vector<ccf::js::FFIPlugin> get_js_plugins();
// SNIPPET_END: app_interface
}
2 changes: 1 addition & 1 deletion python/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"

[project]
name = "ccf"
version = "6.0.0-dev10"
version = "6.0.0-dev11"
authors = [
{ name="CCF Team", email="CCF-Sec@microsoft.com" },
]
Expand Down
5 changes: 5 additions & 0 deletions src/enclave/enclave.h
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,12 @@ namespace ccf
rpc_map->register_frontend<ccf::ActorsType::acme_challenge>(
std::make_unique<ccf::ACMERpcFrontend>(network, *context));

// Suppress error about use of deprecated get_js_plugins(). This call, and all
// references to FFIPlugins, should be removed after 6.0.0
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
ccf::js::register_ffi_plugins(ccf::get_js_plugins());
#pragma clang diagnostic pop

LOG_TRACE_FMT("Initialize node");
node->initialize(
Expand Down
Loading