Skip to content

Feature/plugin interface fixes - #154

Open
stephen-dixon wants to merge 9 commits into
developfrom
feature/plugin-interface-fixes
Open

stephen-dixon wants to merge 9 commits into
developfrom
feature/plugin-interface-fixes

Conversation

@stephen-dixon

Copy link
Copy Markdown
Collaborator

There are a number of issues with the server->plugins interface and how the linking currently works at build time.

currently plugins link both a copy of the static server library and the client library to make some basic functionality available.

One frustration this causes is there are multiple instances of any global state, such as the error stack, and hard-to-trace bugs appear where reading from global state (such as errors) in one part of the codebase references a different instance from where data was actually written. e.g. errors written to one "global" error stack instance but nothing is communicated to client because the server is reading from a different, empty, "global" error stack.

This change aims to break the requirement for plugins to link the entire client and server code for basic common utilities like data subsetting, and diagnostic reporting like logging and errors.

the proposal is:

  1. a new uda-common compilation object in the build system which is included in both the uda_server and uda_plugin libs.

  2. errors are communicated back to the server from plugins through the slots on the interface structure and do not write directly to the global stack, with some additional handling over nested plugin cases.

  3. a new callback block in the plugin interface structure so plugin logging calls have an interface to the server-owned logging routines, respecting current LOG_LEVEL etc.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant