Skip to content
Merged
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
12 changes: 12 additions & 0 deletions src/kdbsolace.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
#ifdef _WIN32
#pragma comment(lib,"ws2_32.lib")
#pragma comment(lib,"q.lib")
#pragma warning(disable: 4710) /* specified function was marked for inline expansion, but the compiler didn't inline the function */
#pragma warning(disable: 4711) /* function selected for inline expansion */
#pragma warning(disable: 4820) /* bytes padding added after construct 'member_name' */
#endif
#include "socketpair.c"
#include "solclient/solClient.h"
Expand Down Expand Up @@ -107,6 +110,7 @@ bool storePartialWrite(char* data, int dataSize, int numWritten)

static void socketWrittableCbFunc(solClient_opaqueContext_pt opaqueContext_p, solClient_fd_t fd, solClient_fdEvent_t events, void *user_p)
{
(void)user_p; /* unused callback param */
if (!BLOCKED_PARTIAL_SEND_DATA.empty())
{
int numWritten = send(SPAIR[1], BLOCKED_PARTIAL_SEND_DATA.c_str(), BLOCKED_PARTIAL_SEND_DATA.size(), 0);
Expand Down Expand Up @@ -448,6 +452,8 @@ K kdbCallback(I d)
/* The message receive callback function is mandatory for session creation. Gets called with msgs from direct subscriptions. */
solClient_rxMsgCallback_returnCode_t defaultSubCallback ( solClient_opaqueSession_pt opaqueSession_p, solClient_opaqueMsg_pt msg_p, void *user_p )
{
(void)user_p; /* unused callback param */
(void)opaqueSession_p; /* unused callback param */
KdbSolaceEvent msgAndSource;
msgAndSource._type = DIRECT_MSG_EVENT;
msgAndSource._event._directMsg=msg_p;
Expand All @@ -458,6 +464,7 @@ solClient_rxMsgCallback_returnCode_t defaultSubCallback ( solClient_opaqueSessio

solClient_rxMsgCallback_returnCode_t guaranteedSubCallback ( solClient_opaqueFlow_pt opaqueFlow_p, solClient_opaqueMsg_pt msg_p, void *user_p )
{
(void)user_p; /* unused callback param */
KdbSolaceEvent msgAndSource;
msgAndSource._type = QUEUE_MSG_EVENT;
msgAndSource._event._queueMsg._msg=msg_p;
Expand All @@ -469,6 +476,7 @@ solClient_rxMsgCallback_returnCode_t guaranteedSubCallback ( solClient_opaqueFlo

void flowEventCallback ( solClient_opaqueFlow_pt opaqueFlow_p, solClient_flow_eventCallbackInfo_pt eventInfo_p, void *user_p )
{
(void)user_p; /* unused callback param */
int destinationType = -1;
const char* destinationName = "";
solClient_destination_t destination;
Expand Down Expand Up @@ -533,6 +541,8 @@ void flowEventCallback ( solClient_opaqueFlow_pt opaqueFlow_p, solClient_flow_ev
*****************************************************************************/
void eventCallback ( solClient_opaqueSession_pt opaqueSession_p, solClient_session_eventCallbackInfo_pt eventInfo_p, void *user_p )
{
(void)user_p; /* unused callback param */
(void)opaqueSession_p; /* unused callback param */
if (!KDB_SESSION_EVENT_CALLBACK_FUNC.empty())
{
// send details to kdb+
Expand Down Expand Up @@ -670,6 +680,7 @@ K init_solace(K options)

K destroy_solace(K a)
{
(void)a; /* unused parameter */
solClient_returnCode_t retCode = SOLCLIENT_OK;
if (session_p != NULL)
{
Expand All @@ -694,6 +705,7 @@ K destroy_solace(K a)

K version_solace(K unused)
{
(void)unused; /* unused parameter */
solClient_version_info_pt version = NULL;
solClient_version_get (&version);
K keys = knk(3,ks((char*)"solVersion"),ks((char*)"solDate"),ks((char*)"solVariant"));
Expand Down