Skip to content

Releases: jharmer95/rpc.hpp

Alpha 8-1

19 Jul 17:51
4310532
Compare
Choose a tag to compare
Alpha 8-1 Pre-release
Pre-release

Alpha v8 brings a big change to function dispatching, utilizing a hashmap instead of macro-heavy code. It also changes the namespace from rpc to rpc_hpp for clarity and avoiding conflicts.

  • Function dispatching now uses a dispatch table

    • Functions are now "bound" to the server at runtime via a hashmap
      • Key: function name/alias string
    • Simplifies server setup (and possible performance boost)
    • No more rpc_dispatch_helper.hpp
  • Add support for using string literal arguments

  • Add benchmarks comparing rpc.hpp to other RPC libraries

  • Changed dispatch function signature

    • The dispatch function in the server interface is now sink & return, rather than pass-by-reference.
  • Adapters now use more direct static polymorphism

    • As a result, adapters are nicer to work with and can be more flexible
      • Details for adapters can now be implemented as private members
  • Fix compiler compatibility issues

Alpha 7-1

19 Jan 15:52
7a83063
Compare
Choose a tag to compare
Alpha 7-1 Pre-release
Pre-release

Alpha v7 cleans up the code and adds exception handling:

  • Removed unused internal functions
  • Moved previously unnecessarily public functions to internal namespaces
  • Exceptions can now be throw for error detection, both client- and server-side
    • Exceptions are serializable so they can be "re-thrown" on the client side
    • Tests are in place to ensure the proper exceptions are thrown
  • Bitsery binary serialization adapter now public
  • More efficient use of memory allocation for all adapters

Alpha 6-1

02 Aug 23:06
6d1ea67
Compare
Choose a tag to compare
Alpha 6-1 Pre-release
Pre-release

Alpha v6 brings some big changes:

  • Calling a function that takes parameters by reference is now transparent!
    • This means that is behaves like you were calling the function locally; non-const reference parameters will be updated automatically
  • Server functions are now in a class server_interface much like client_interface
    • Makes it easier to define a server class via inheritance
  • Minor performance enhancements and warning cleanup

Alpha 5-1

30 Jul 21:11
1ace51a
Compare
Choose a tag to compare
Alpha 5-1 Pre-release
Pre-release
  • Components can now be conditionally compiled to save compilation time. This can be done by defining one or more of the following in a .cpp file that includes rpc.hpp (or an adapter):
    • #define RPC_HPP_CLIENT_IMPL for client executables (caller)
    • #define RPC_HPP_MODULE_IMPL for dynamically-loaded .dll or .so projects acting as the "server" (receiver)
    • #define RPC_HPP_SERVER_IMPL for server executables (receiver)
  • Additionally, call_func was moved from a free-standing function, to a member function of client_interface. This allows for a slightly nicer calling convention:
// before
auto pack = rpc::client::call_func<T_SERIAL, T_RETURN>(my_client, "FUNC_NAME", arg1, arg2);

// now
auto pack = my_client.template call_func<T_RETURN>("FUNC_NAME", arg1, arg2);
  • Also added some examples for creating RPC clients, modules, and servers

Alpha 4-1

01 Apr 20:53
7278067
Compare
Choose a tag to compare
Alpha 4-1 Pre-release
Pre-release

This release involves a new redesign featuring a much smaller codebase (2183 total LOC down to 1129) and a way simpler extension system.

It is technically a breaking change though the syntax for the client should be very similar (replace rpc::call with rpc::call_func).

This rewrite also removes pointer support (again). It may be added at a later time, but it was discovered that pointer support was a big reason for the code bloat

Alpha 3-4

24 Mar 13:53
46a14dd
Compare
Choose a tag to compare
Alpha 3-4 Pre-release
Pre-release

Fixes an issue compiling when RPC_HPP_ENABLE_POINTERS is not defined ( #57 )

Alpha 3-3

19 Mar 17:28
8b539ca
Compare
Choose a tag to compare
Alpha 3-3 Pre-release
Pre-release

This release provides some minor performance improvements and also provides built-in capability for reporting exceptions from the server back to the client.

Calls to packed_func::get_result() will now throw if the result is std::nullopt and provide the user with the error message via exception

Alpha 3-2

12 Mar 21:44
8ca8eb5
Compare
Choose a tag to compare
Alpha 3-2 Pre-release
Pre-release

This release fixes some bugs and adds back the ability to define public, static serialize and deserialize methods to your classes

Alpha 3-1

02 Mar 19:01
26624a4
Compare
Choose a tag to compare
Alpha 3-1 Pre-release
Pre-release

This release adds the ability to cache the results of certain functions on the server to potentially improve performance. This feature is per-function and opt-in (i.e. not default behavior).

In order to indicate that a function is to be cached, the RPC_ATTACH_CACHED_FUNC / RPC_ATTACH_CACHED_FUNCS macros should be used instead of the normal RPC_ATTACH_FUNC.

To benefit from server-side caching, a function should be a pure function and have a non-void return type

Alpha 2-4

02 Mar 03:05
97515cb
Compare
Choose a tag to compare
Alpha 2-4 Pre-release
Pre-release

This release includes a new adapter for Boost.JSON (require Boost 1.75.0 or newer).

Also included are some bugfixes and performance improvements.