The Server API provides a C ABI interface to facilitate communication with the application, which is implemented as a shared object library. The native application is a shared object library file (
.so on Linux,
.dll on Windows,
.dylib on MacOS) that can be written in any programming language and toolset. The shared object may have both mandatory and optional exports, which the Game Carrier Server (
gcs) program loads and communicates with.
The first call from
gcs to the shared object library is
adapter_initialize. This call requires passing a pointer to the
core_api structure with callback functions. These functions can be considered as the API that the Game Carrier Server provides to an application. The documentation lists such functions in the “Functions” subsection.
Furthermore, the Game Carrier Server may call some shared object exported functions when certain events occur. These exported functions are listed in the documentation’s “Events” subsection.
The description of the Server API is grouped into several sections for clarity:
- Initialization & Finalization: This section outlines the basic actions performed by the Game Carrier Server (
gcs) during the start and stop of a service.
- Configuration: This section covers the configuration of the Game Carrier Server (
gcs) program and provides functions to obtain configuration parameters.
- Messaging: Here, the process of sending and receiving messages to and from clients is described.
- Server To Server: This section explains how to send and receive messages to/from other Game Carrier applications.
- Counters: The usage of performance counters is detailed in this section.
- Smart Locks: Developers can learn how to use smart locks for multithreading synchronization in this section.
- Logging: This section guides users on how to set up and utilize logging in their applications.
By organizing the Server API’s description into these sections, developers can easily find the information they need for effective implementation and integration with the Game Carrier platform.