CDI SDK
SDK for transporting chunks of data reliably and with low latency using a polled mode network driver.
Loading...
Searching...
No Matches
cdi_core_api.h
Go to the documentation of this file.
1// -------------------------------------------------------------------------------------------
2// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved.
3// This file is part of the AWS CDI-SDK, licensed under the BSD 2-Clause "Simplified" License.
4// License details at: https://github.com/aws/aws-cdi-sdk/blob/mainline/LICENSE
5// -------------------------------------------------------------------------------------------
6
7#ifndef CDI_CORE_API_H__
8#define CDI_CORE_API_H__
9
17// Doxygen for CDI-CORE
32/*
33 * With older distros (Ubuntu 16.04 in particular), "struct timespec" often is undefined prior to references to it.
34 * C source files likely include time.h indirectly and sometimes directly prior to its inclusion below and if
35 * _POSIX_C_SOURCE is undefined or defined to be less than 200112L, it does not get defined through the inclusion here.
36 * The only solution is to ensure that it is defined with the required value early in each compilation unit.
37 *
38 * The block below ensures that _POSIX_C_SOURCE is defined with a value of 200112L or greater, erring out if not.
39 */
40#if !defined(_POSIX_C_SOURCE)
42#define _POSIX_C_SOURCE 200112L
43#else
44#if _POSIX_C_SOURCE < 200112L
45/*
46 * If the compiler hits this #error, define _POSIX_C_SOURCE to the value 200112L or a newer supported value in the
47 * definitions passed in from the command line.
48 */
49#error _POSIX_C_SOURCE must be >= 200112L
50#endif // _POSIX_C_SOURCE < 200112L
51#endif // !defined(_POSIX_C_SOURCE)
52
53#include <stdbool.h>
54#include <stdint.h>
55#include <time.h>
56
57#include "cdi_log_enums.h"
58#include "cdi_utility_api.h"
59
60//*********************************************************************************************************************
61//***************************************** START OF DEFINITIONS AND TYPES ********************************************
62//*********************************************************************************************************************
63
64// NOTE: Do not change the ordering of the three defines below. They are used internally by the CDI SDK makefile or
65// scripts to extract version information.
66
68#define CDI_SDK_VERSION 3
69
71#define CDI_SDK_MAJOR_VERSION 0
72
74#define CDI_SDK_MINOR_VERSION 2
75
77#define CDI_PROTOCOL_VERSION 2
78
80#define CDI_PROTOCOL_MAJOR_VERSION 3
81
94#define CDI_PROBE_VERSION 5
95
97#define CDI_MAX_SIMULTANEOUS_CONNECTIONS (30)
98
101#define CDI_MAX_ENDPOINTS_PER_CONNECTION (5)
102
105#define CDI_MAX_SIMULTANEOUS_TX_PAYLOADS_PER_CONNECTION (8)
106
109#define CDI_MAX_SIMULTANEOUS_TX_PAYLOAD_SGL_ENTRIES_PER_CONNECTION (CDI_MAX_SIMULTANEOUS_TX_PAYLOADS_PER_CONNECTION*3500)
110
118#define CDI_MAX_SIMULTANEOUS_RX_PAYLOADS_PER_CONNECTION (32)
119
122#define CDI_MAX_RX_PAYLOAD_OUT_OF_ORDER_BUFFER (8192)
123
126#define CDI_MAX_RX_PACKET_OUT_OF_ORDER_WINDOW (5000)
127
129#define CDI_MAX_CONNECTION_NAME_STRING_LENGTH (128)
130
132#define CDI_MAX_STREAM_NAME_STRING_LENGTH (CDI_MAX_CONNECTION_NAME_STRING_LENGTH+10)
133
135#define CDI_MAX_LOG_FILENAME_LENGTH (1024)
136
140#define CDI_ENABLED_RX_BUFFER_DELAY_DEFAULT_MS (67)
141
143#define CDI_MAXIMUM_RX_BUFFER_DELAY_MS (100)
144
147#define CDI_RX_BUFFER_DELAY_BUFFER_MS_DIVISOR (10)
148
149// Declare forward references for internal structures that are not directly available through the API.
150struct CdiAdapterState;
151struct CdiConnectionState;
152struct CdiMemoryState;
155
161
167
173
178
182typedef void* CdiUserCbParameter;
183
189typedef enum {
192
195
198
201
204
207
210
215
218
221
224
228
231
234
238
241
244
247
250
253
256
259
262
265
268
271
274
277
281
284
288
291
294
297
300
303
307
310
313
316
319
322
326
330//typedef struct CdiPtpTimestamp CdiPtpTimestamp;
331typedef struct CdiPtpTimestamp {
333 uint32_t seconds;
335 uint32_t nanoseconds;
337
349
363
372
403
412typedef void (*CdiCoreConnectionCallback)(const CdiCoreConnectionCbData* data_ptr);
413
443
476
499
519
525typedef struct {
528
531
534
537
540
543
547
568
584
597
606typedef void (*CdiCoreStatsCallback)(const CdiCoreStatsCbData* data_ptr);
607
620
701
723
743
748typedef enum {
752
756
844
852typedef struct {
855 const char* namespace_str;
856
859 const char* region_str;
860
865
881
885typedef struct {
890
895
896//*********************************************************************************************************************
897//******************************************* START OF PUBLIC FUNCTIONS ***********************************************
898//*********************************************************************************************************************
899
915
938 CdiAdapterHandle* ret_handle_ptr);
939
950
959
977CDI_INTERFACE int CdiCoreGather(const CdiSgList* sgl_ptr, int offset, void* dest_data_ptr, int byte_count);
978
990
999
1006
1017CDI_INTERFACE void CdiCoreGetUtcTime(struct timespec* ret_time_ptr);
1018
1030
1037
1044
1053
1060
1061#endif // CDI_CORE_API_H__
CdiReturnStatus
Values used for API function return codes.
Definition cdi_core_api.h:189
@ kCdiStatusArraySizeExceeded
The size of an internal array that does not dynamically grow was exceeded.
Definition cdi_core_api.h:273
@ kCdiStatusQueueFull
The operation failed due to a queue resource being full.
Definition cdi_core_api.h:217
@ kCdiStatusCloudWatchNotEnabled
Definition cdi_core_api.h:280
@ kCdiStatusProfileNotSupported
An attempt was made to use a profile that is not supported.
Definition cdi_core_api.h:296
@ kCdiStatusFatal
An unspecified, unrecoverable error occurred.
Definition cdi_core_api.h:194
@ kCdiStatusInvalidHandle
The handle passed in to an SDK function is not valid.
Definition cdi_core_api.h:206
@ kCdiStatusOk
The API function succeeded.
Definition cdi_core_api.h:191
@ kCdiStatusRxPayloadMissing
No packets were received for a payload.
Definition cdi_core_api.h:270
@ kCdiStatusRxPayloadBackPressure
Definition cdi_core_api.h:306
@ kCdiStatusRxWrongProtocolType
Definition cdi_core_api.h:227
@ kCdiStatusRxPayloadError
A payload was received, but an error occurred. The payload is being discarded.
Definition cdi_core_api.h:223
@ kCdiStatusProbePacketInvalidSize
Failed to decode a probe packet due to invalid size.
Definition cdi_core_api.h:302
@ kCdiStatusInvalidParameter
A parameter passed in to an SDK function is not valid.
Definition cdi_core_api.h:209
@ kCdiStatusBufferOverflow
Buffer is not large enough to hold data.
Definition cdi_core_api.h:267
@ kCdiStatusOpenFailed
Attempt to open a connection (e.g. socket) failed.
Definition cdi_core_api.h:255
@ kCdiStatusShuttingDown
Definition cdi_core_api.h:237
@ kCdiStatusCloudWatchInvalidCredentials
Definition cdi_core_api.h:287
@ kCdiStatusCreateThreadFailed
Unable to create a thread.
Definition cdi_core_api.h:233
@ kCdiStatusNotConnected
Definition cdi_core_api.h:214
@ kCdiStatusLibraryWrongVersion
Wrong version of dynamically loaded library.
Definition cdi_core_api.h:321
@ kCdiStatusInvalidSgl
Invalid SGL found when processing.
Definition cdi_core_api.h:261
@ kCdiStatusEndpointManagerState
An endpoint state change occurred.
Definition cdi_core_api.h:264
@ kCdiStatusNotReady
Attempt to use a connection that is stopped.
Definition cdi_core_api.h:246
@ kCdiStatusInternalIdle
Internal only status: the function succeeded but did nothing productive.
Definition cdi_core_api.h:290
@ kCdiStatusNotEnoughMemory
An attemt to allocated memory from the heap failed.
Definition cdi_core_api.h:197
@ kCdiStatusGetPortFailed
When performing a port query, the function failed.
Definition cdi_core_api.h:243
@ kCdiStatusSendFailed
Tx data failed to post to endpoint queue.
Definition cdi_core_api.h:249
@ kCdiStatusMaxLatencyExceeded
A chunk of data was not delivered to the receiver before its deadline was reached.
Definition cdi_core_api.h:203
@ kCdiStatusNotInitialized
The appropriate SDK initialization function has not yet been called.
Definition cdi_core_api.h:200
@ kCdiStatusLibraryLoadFailed
Failed to dynamically load a shared library.
Definition cdi_core_api.h:315
@ kCdiStatusDuplicateConnection
Attempt was made to create an identical endpoint that is already in use.
Definition cdi_core_api.h:258
@ kCdiStatusAdapterDuplicateEntry
An attempt was made to create a duplicate adapter entry.
Definition cdi_core_api.h:293
@ kCdiStatusCloudWatchThrottling
A CloudWatch request was throttled. Need to try the request again at a later time.
Definition cdi_core_api.h:283
@ kCdiStatusProbePacketCrcError
Failed to decode a probe packet due to a CRC error.
Definition cdi_core_api.h:299
@ kCdiStatusDuplicateBaselineVersion
An attempt was made to register an already registered baseline profile.
Definition cdi_core_api.h:309
@ kCdiStatusAllocationFailed
Attempt to allocate a non-memory resource failed.
Definition cdi_core_api.h:252
@ kCdiStatusNonFatal
An unspecified, recoverable error occurred.
Definition cdi_core_api.h:276
@ kCdiStatusCreateLogFailed
Unable to create a log file.
Definition cdi_core_api.h:230
@ kCdiStatusInvalidPayload
A received payload cannot be read because of format errors.
Definition cdi_core_api.h:312
@ kCdiStatusLibrarySymbolNotFound
Failed to find symbol in dynamically loaded library.
Definition cdi_core_api.h:318
@ kCdiStatusInvalidConnectionType
The operation failed due to the connection type is not valid for the requested operation.
Definition cdi_core_api.h:220
@ kCdiStatusWrongDirection
An attempt was made to perform an Rx function on a Tx connection, or vice-versa.
Definition cdi_core_api.h:240
@ kCdiStatusRetry
Resource not available. Retry the operation.
Definition cdi_core_api.h:324
CDI_INTERFACE const CdiCoreReadOnlySettings * CdiCoreGetSettings()
Definition cdi_core_api.c:234
CDI_INTERFACE CdiReturnStatus CdiCoreRxFreeBuffer(const CdiSgList *sgl_ptr)
Definition cdi_core_api.c:87
struct CdiEndpointState * CdiEndpointHandle
Type used as the handle (pointer to an opaque structure) for a transmitter or receiver endpoint....
Definition cdi_core_api.h:172
void(* CdiCoreStatsCallback)(const CdiCoreStatsCbData *data_ptr)
Prototype of statistics callback function. The user code must implement a function with this prototyp...
Definition cdi_core_api.h:606
CDI_INTERFACE CdiPtpTimestamp CdiCoreGetPtpTimestamp(CdiPtpTimestamp *ret_ptp_time_ptr)
Get the current TAI time as a PTP timestamp.
Definition cdi_core_api.c:151
struct CdiPtpTimestamp CdiPtpTimestamp
A structure for holding a PTP timestamp defined in seconds and nanoseconds. This PTP time as defined ...
CDI_INTERFACE CdiReturnStatus CdiCoreInitialize(const CdiCoreConfigData *core_config_ptr)
Definition cdi_core_api.c:41
CdiConnectionStatus
This enumeration is used to indicate the current state of a connection. NOTE: Any changes made here M...
Definition cdi_core_api.h:368
@ kCdiConnectionStatusDisconnected
Disconnected. The SDK is trying to establish the connection.
Definition cdi_core_api.h:369
@ kCdiConnectionStatusConnected
Connected and ready for use.
Definition cdi_core_api.h:370
void * CdiUserCbParameter
Type used as user defined data that is passed to the registered user RX/TX callback functions.
Definition cdi_core_api.h:182
CDI_INTERFACE CdiReturnStatus CdiCoreNetworkAdapterDestroy(CdiAdapterHandle handle)
Definition cdi_core_api.c:72
void(* CdiCoreConnectionCallback)(const CdiCoreConnectionCbData *data_ptr)
Prototype of connection callback function. The user code must implement a function with this prototyp...
Definition cdi_core_api.h:412
#define CDI_MAX_STREAM_NAME_STRING_LENGTH
Maximum stream name string length.
Definition cdi_core_api.h:132
CdiAdapterTypeSelection
This selector determines the type of network adapter in the API function. NOTE: Any changes made here...
Definition cdi_core_api.h:448
@ kCdiAdapterTypeEfa
This adapter type is the typical choice for high throughput, reliable delivery of data....
Definition cdi_core_api.h:451
@ kCdiAdapterTypeSocketLibfabric
This adapter type is mainly useful for testing. This is similar to kCdiAdapterTypeSocket except that ...
Definition cdi_core_api.h:474
@ kCdiAdapterTypeSocket
This adapter type has significant performance limitations and is mainly useful for testing since ther...
Definition cdi_core_api.h:470
CdiBufferType
Values used to determine type of receive buffer to configure for a receiver connection....
Definition cdi_core_api.h:748
@ kCdiLinearBuffer
Use a linear buffer to store received payload data. Depending on hardware capabilities,...
Definition cdi_core_api.h:751
@ kCdiSgl
Use scatter-gather buffers to store received payload data.
Definition cdi_core_api.h:754
CDI_INTERFACE CdiReturnStatus CdiCoreConnectionDestroy(CdiConnectionHandle handle)
Definition cdi_core_api.c:131
CDI_INTERFACE CdiReturnStatus CdiCoreStatsReconfigure(CdiConnectionHandle handle, const CdiStatsConfigData *config_ptr)
Definition cdi_core_api.c:121
CDI_INTERFACE uint64_t CdiCoreGetUtcTimeMicroseconds(void)
Definition cdi_core_api.c:168
struct CdiConnectionState * CdiConnectionHandle
Type used as the handle (pointer to an opaque structure) for a transmitter or receiver connection....
Definition cdi_core_api.h:166
struct CdiMemoryState * CdiMemoryHandle
Type used as the handle (pointer to an opaque structure) for holding private SDK data that relates to...
Definition cdi_core_api.h:177
CDI_INTERFACE void CdiCoreGetUtcTime(struct timespec *ret_time_ptr)
Definition cdi_core_api.c:146
CDI_INTERFACE uint64_t CdiCoreGetTaiTimeMicroseconds()
Definition cdi_core_api.c:176
struct CdiAdapterState * CdiAdapterHandle
Type used as the handle (pointer to an opaque structure) for a network adapter. Each handle represent...
Definition cdi_core_api.h:160
CDI_INTERFACE const char * CdiCoreStatusToString(CdiReturnStatus status)
Definition cdi_core_api.c:184
CDI_INTERFACE CdiReturnStatus CdiCoreShutdown(void)
Definition cdi_core_api.c:141
CDI_INTERFACE CdiReturnStatus CdiCoreNetworkAdapterInitialize(CdiAdapterData *adapter_data_ptr, CdiAdapterHandle *ret_handle_ptr)
Definition cdi_core_api.c:55
CDI_INTERFACE int CdiCoreGather(const CdiSgList *sgl_ptr, int offset, void *dest_data_ptr, int byte_count)
Definition cdi_core_api.c:108
This file declares the public enum data types that are part of the CDI log API.
CdiLogLevel
This selector determines the log level of messages generated using the CdiLogMessageCallback()....
Definition cdi_log_enums.h:50
The declarations in this header file correspond to the definitions in cdi_utility_api....
#define CDI_INTERFACE
Specify C linkage when compiling as C++ and define API interface export for Windows.
Definition cdi_utility_api.h:34
Configuration data used by the CdiCoreNetworkAdapterInitialize() API function.
Definition cdi_core_api.h:480
uint64_t tx_buffer_size_bytes
The size in bytes of a memory region for holding payload data to transmit. If no transmit connections...
Definition cdi_core_api.h:490
void * ret_tx_buffer_ptr
Returned pointer to start of the allocated transmit buffer. Size is specified using tx_buffer_size_kb...
Definition cdi_core_api.h:494
const char * adapter_ip_addr_str
The IP address to use for the local network interface dedicated to the SDK's use. NOTE: This must be ...
Definition cdi_core_api.h:483
CdiAdapterTypeSelection adapter_type
The type of adapter to use/initialize.
Definition cdi_core_api.h:497
Transfer statistics data specific to an adapter endpoint. Used in the CdiTransferStats structure as a...
Definition cdi_core_api.h:552
uint32_t probe_command_retry_count
Definition cdi_core_api.h:558
bool connected
true if connected, false if not connected.
Definition cdi_core_api.h:566
uint32_t dropped_connection_count
Number of times the connection has been lost.
Definition cdi_core_api.h:554
int poll_thread_load
Definition cdi_core_api.h:564
Structure definition behind the handles shared with the user's application program....
Definition adapter_api.h:384
A structure that is used to hold statistics gathering configuration data that is specific to CloudWat...
Definition cdi_core_api.h:852
const char * region_str
Pointer to a string that defines the EC2 region where the CloudWatch container is located....
Definition cdi_core_api.h:859
const char * namespace_str
Pointer to a string that defines the CloudWatch namespace used to hold metrics generated by CDI....
Definition cdi_core_api.h:855
const char * dimension_domain_str
Pointer to a string that defines a dimension called "Domain" that is associated with each metric....
Definition cdi_core_api.h:863
Structure definition behind the connection handles shared with the user's application program....
Definition private.h:371
A structure of this type is passed as part of the data to the TX/RX registered user callback function...
Definition cdi_core_api.h:418
CdiCoreExtraData core_extra_data
Extra data that was sent along with the payload.
Definition cdi_core_api.h:435
const char * err_msg_str
If an error or timeout occurred while transmitting the payload, this will point to a NULL terminated ...
Definition cdi_core_api.h:428
CdiConnectionHandle connection_handle
The handle of the instance which was created using a previous call to one of the Cdi....
Definition cdi_core_api.h:432
CdiReturnStatus status_code
If payload was successfully sent and received by the receiver, value will be kCdiStatusOk....
Definition cdi_core_api.h:422
CdiUserCbParameter user_cb_param
User defined callback parameter. For a transmitter, this value is set as part of the CdiCoreTxPayload...
Definition cdi_core_api.h:441
SDK configuration data used by the CdiCoreInitialize() API function.
Definition cdi_core_api.h:869
CdiLogLevel default_log_level
Specifies the default set of log messages to use.
Definition cdi_core_api.h:871
const CdiCloudWatchConfigData * cloudwatch_config_ptr
Pointer to configuration data specific to CloudWatch. The statics gathering period is uniquely define...
Definition cdi_core_api.h:879
const CdiLogMethodData * global_log_method_data_ptr
Pointer to global log method configuration data.
Definition cdi_core_api.h:874
A structure of this type is passed as the parameter to CdiCoreConnectionCallback()....
Definition cdi_core_api.h:377
CdiEndpointHandle tx_stream_endpoint_handle
Used to identify the handle of the stream endpoint associated with the connection....
Definition cdi_core_api.h:388
uint8_t negotiated_major_version_num
Negotiated CDI protocol major version number.
Definition cdi_core_api.h:400
uint8_t negotiated_version_num
Negotiated CDI protocol version number for the endpoint associated with this connection.
Definition cdi_core_api.h:399
CdiUserCbParameter connection_user_cb_param
User defined connection callback parameter. For a transmitter, this value is set as part of the CdiTx...
Definition cdi_core_api.h:396
uint8_t negotiated_probe_version_num
Negotiated CDI protocol probe version number.
Definition cdi_core_api.h:401
CdiConnectionStatus status_code
Current status of the connection.
Definition cdi_core_api.h:379
const char * remote_ip_str
Pointer to remote IP address string.
Definition cdi_core_api.h:390
const char * err_msg_str
If the connection is not connected, this will point to a NULL terminated error message string....
Definition cdi_core_api.h:384
int remote_dest_port
Remote destination port.
Definition cdi_core_api.h:391
Extra data that is sent along with payloads to the receiver. It will be provided to the receiver thro...
Definition cdi_core_api.h:340
CdiPtpTimestamp origination_ptp_timestamp
Origination timestamp to associate with the payload. This timestamp is a PTP timestamp as outlined by...
Definition cdi_core_api.h:344
uint64_t payload_user_data
User-defined data to associate with the payload.
Definition cdi_core_api.h:347
SDK read-only settings used internally by SDK.
Definition cdi_core_api.h:885
uint64_t tx_retry_timeout_ms
How long a Tx endpoint retries in milliseconds to send an out-of-band command to Rx before disconnect...
Definition cdi_core_api.h:889
uint64_t rx_wait_timeout_ms
How long a Rx endpoint waits in milliseconds for an out-of-band ping command from Tx before removing ...
Definition cdi_core_api.h:893
A structure of this type is passed as the parameter to CdiCoreStatsCallback(). It contains data relat...
Definition cdi_core_api.h:589
CdiUserCbParameter stats_user_cb_param
User defined statistics callback parameter. This value is set as part of the CdiStatsConfigData struc...
Definition cdi_core_api.h:595
int stats_count
Number of items in transfer_stats_array.
Definition cdi_core_api.h:590
CdiTransferStats * transfer_stats_array
Array of the accumulated statistics.
Definition cdi_core_api.h:591
A structure used to configure a transmit payload.
Definition cdi_core_api.h:351
CdiCoreExtraData core_extra_data
Extra data that was sent along with the payload.
Definition cdi_core_api.h:353
int unit_size
The size in bits of the units being transferred. This ensures a single unit is not split across sgl e...
Definition cdi_core_api.h:361
CdiUserCbParameter user_cb_param
User defined callback parameter specified when using one of the Cdi...Tx...Payload() API functions....
Definition cdi_core_api.h:357
Structure definition behind the connection handles shared with the user's application program....
Definition private.h:330
A structure of this type is used to configure the type of log method that is being used....
Definition cdi_log_api.h:63
Structure definition behind the Scatter-Gather List internal data handles shared with the user's appl...
Definition private.h:456
Transfer statistics data specific to payloads that contain counters that increment for the duration o...
Definition cdi_core_api.h:504
uint64_t num_payloads_transferred
Current number of payloads successfully transferred since the connection was created.
Definition cdi_core_api.h:506
uint64_t num_bytes_transferred
Number of bytes that were transmitted since the connection was created.
Definition cdi_core_api.h:517
uint64_t num_payloads_dropped
The number of payloads that have been dropped due to timeout conditions since the connection was crea...
Definition cdi_core_api.h:511
uint64_t num_payloads_late
Number of payloads that were transmitted late since the connection was created.
Definition cdi_core_api.h:514
Transfer statistics data specific to payloads that are reset at the start of each time interval as sp...
Definition cdi_core_api.h:525
uint32_t transfer_time_P99
The 99th percentile time to transfer a payload over the time interval.
Definition cdi_core_api.h:545
uint32_t transfer_time_P50
The median time to transfer a payload over the time interval.
Definition cdi_core_api.h:539
uint64_t transfer_time_sum
Accumulating sum of time to transfer payloads over the time interval.
Definition cdi_core_api.h:536
uint32_t transfer_time_min
Minimum time to transfer a payload over the time interval.
Definition cdi_core_api.h:527
int transfer_count
Number of payloads transferred over the time interval.
Definition cdi_core_api.h:533
uint32_t transfer_time_P90
The 90th percentile time to transfer a payload over the time interval.
Definition cdi_core_api.h:542
uint32_t transfer_time_max
Maximum time to transfer a payload over the time interval.
Definition cdi_core_api.h:530
A structure for holding a PTP timestamp defined in seconds and nanoseconds. This PTP time as defined ...
Definition cdi_core_api.h:331
uint32_t seconds
The number of seconds since the SMPTE Epoch which is 1970-01-01T00:00:00.
Definition cdi_core_api.h:333
uint32_t nanoseconds
The number of fractional seconds as measured in nanoseconds. The value in this field is always less t...
Definition cdi_core_api.h:335
Configuration data used by one of the Cdi...RxCreate() API functions.
Definition cdi_core_api.h:760
const char * bind_ip_addr_str
The IP address of the host interface to bind to for internal CDI command communication....
Definition cdi_core_api.h:773
int buffer_delay_ms
Number of milliseconds to delay invoking the user-registered callback function for incoming payloads....
Definition cdi_core_api.h:796
CdiStatsConfigData stats_config
Configuration data for gathering statistics. The data can be changed at runtime using the CdiCoreStat...
Definition cdi_core_api.h:842
int dest_port
Destination port. Value must match the dest_port specified by the transmitter which must be configure...
Definition cdi_core_api.h:768
int shared_thread_id
To reduce CPU core usage, multiple connections can share the same poll thread by specifying a shared ...
Definition cdi_core_api.h:782
CdiCoreStatsCallback stats_cb_ptr
Address of the user function to call whenever a new set of statistics is available.
Definition cdi_core_api.h:833
int max_simultaneous_rx_payloads_per_connection
The max number of allowable payloads that can be simultaneously received on a single connection in th...
Definition cdi_core_api.h:810
uint64_t linear_buffer_size
Size in bytes of the linear receive buffer used by this RX connection. This buffer is reserved from t...
Definition cdi_core_api.h:801
CdiBufferType rx_buffer_type
Type of RX buffer to use for incoming data.
Definition cdi_core_api.h:791
CdiLogMethodData * connection_log_method_data_ptr
Pointer to log configuration data for this connection.
Definition cdi_core_api.h:822
CdiAdapterHandle adapter_handle
Handle of the adapter to use for this connection. The handle is returned by the CdiCoreNetworkAdapter...
Definition cdi_core_api.h:763
CdiUserCbParameter connection_user_cb_param
User defined callback parameter passed to the user registered RX connection callback function (see co...
Definition cdi_core_api.h:830
CdiUserCbParameter user_cb_param
User defined callback parameter passed to a registered user RX callback function. This allows the app...
Definition cdi_core_api.h:814
CdiUserCbParameter stats_user_cb_param
User defined callback parameter passed to the user registered statistics callback function (see stats...
Definition cdi_core_api.h:838
const char * connection_name_str
Pointer to name of the connection. It is used as an identifier when generating log messages that are ...
Definition cdi_core_api.h:819
CdiCoreConnectionCallback connection_cb_ptr
Address of the user function to call whenever the status of a connection changes.
Definition cdi_core_api.h:825
int thread_core_num
The core to dedicate to this connection's packet reception poll thread. A value of -1 disables pinnin...
Definition cdi_core_api.h:788
This structure defines a scatter-gather list (SGL) which is used to represent an array of data compri...
Definition cdi_core_api.h:728
CdiSglEntry * sgl_tail_ptr
Pointer to the last entry in the singly-linked list of SGL entries.
Definition cdi_core_api.h:738
int total_data_size
Total size of data in the list, in units of bytes. This value can be calculated by walking the sgl_ar...
Definition cdi_core_api.h:732
CdiSglEntry * sgl_head_ptr
Pointer to the first entry in the singly-linked list of SGL entries.
Definition cdi_core_api.h:735
void * internal_data_ptr
Handle to internal data used within the SDK that relates to this SGL. Do not use or modify this value...
Definition cdi_core_api.h:741
This structure represents a single, contiguous region of memory as part of a scatter-gather list.
Definition cdi_core_api.h:709
int size_in_bytes
The size of the data in bytes.
Definition cdi_core_api.h:714
void * internal_data_ptr
Handle to private data used within the SDK that relates to this SGL entry. Do not use or modify this ...
Definition cdi_core_api.h:718
void * address_ptr
The starting address of the data.
Definition cdi_core_api.h:711
CdiSglEntry * next_ptr
The next entry in the list or NULL if this is the final entry in the list.
Definition cdi_core_api.h:721
A structure that is used to hold statistics gathering configuration data.
Definition cdi_core_api.h:611
uint32_t stats_period_seconds
How often to gather statistics and make available through the user-registered statistics callback fun...
Definition cdi_core_api.h:615
bool disable_cloudwatch_stats
If CloudWatch has been configured, use this value to disable/enable sending statistics to it.
Definition cdi_core_api.h:618
Transfer statistics data. Used as a parameter of the user-registered CdiCoreStatsCallback() API funct...
Definition cdi_core_api.h:572
CdiPayloadCounterStats payload_counter_stats
Statistics data specific to payloads that don't reset.
Definition cdi_core_api.h:580
uint64_t timestamp_in_ms_since_epoch
Time when last statistic of the set was gathered. Units is in milliseconds since epoch.
Definition cdi_core_api.h:574
CdiAdapterEndpointStats endpoint_stats
Statistics data specific to adapter endpoints.
Definition cdi_core_api.h:582
CdiPayloadTimeIntervalStats payload_time_interval_stats
Statistics data specific to payloads that reset.
Definition cdi_core_api.h:581
Configuration data used by one of the Cdi...TxCreate() API functions.
Definition cdi_core_api.h:624
CdiAdapterHandle adapter_handle
Handle of the adapter to use for this connection. The handle is returned by the CdiCoreNetworkAdapter...
Definition cdi_core_api.h:627
CdiUserCbParameter connection_user_cb_param
User defined callback parameter passed to the user registered connection callback function (see conne...
Definition cdi_core_api.h:687
const char * connection_name_str
Pointer to name of the connection. It is used as an identifier when generating log messages that are ...
Definition cdi_core_api.h:676
int max_simultaneous_tx_payloads
The max number of allowable payloads that can be simultaneously transmitted on a single connection in...
Definition cdi_core_api.h:663
const char * bind_ip_addr_str
The IP address of the host interface to bind to for internal CDI command communication....
Definition cdi_core_api.h:640
CdiLogMethodData * connection_log_method_data_ptr
Pointer to log configuration data for this connection.
Definition cdi_core_api.h:679
int thread_core_num
The core to dedicate to this connection's packet send poll thread. A value of -1 disables pinning the...
Definition cdi_core_api.h:656
int shared_thread_id
To reduce CPU core usage, multiple connections can share the same poll thread by specifying a shared ...
Definition cdi_core_api.h:649
CdiCoreStatsCallback stats_cb_ptr
Address of the user function to call whenever a new set of statistics is available.
Definition cdi_core_api.h:690
int dest_port
The port number to use at the receiving host. The range of valid values is 1 to 65535,...
Definition cdi_core_api.h:635
const char * dest_ip_addr_str
The IP address of the host which is to receive the flow from this transmitter. NOTE: This must be the...
Definition cdi_core_api.h:631
CdiUserCbParameter stats_user_cb_param
User defined callback parameter passed to the user registered statistics callback function (see stats...
Definition cdi_core_api.h:695
CdiStatsConfigData stats_config
Configuration data for gathering statistics. The data can be changed at runtime using the CdiCoreStat...
Definition cdi_core_api.h:699
CdiCoreConnectionCallback connection_cb_ptr
Address of the user function to call whenever the status of a connection changes.
Definition cdi_core_api.h:682
int max_simultaneous_tx_payload_sgl_entries
The max number of sgl entries in use at one time for each transmit connection in the SDK....
Definition cdi_core_api.h:671