question

Upvotes
Accepted
1 0 1 2

Login StatusMsg in ETA MRN tutorial

Hello,

I received the following message from the tutorialMRN provided in C language.

Received Login StatusMsg

State: Closed / Suspect / User unknown to permission system, it could be DACS, AAA or EED - text: "[my server host name], unknown to system"

I already got a DACS ID.

How should I use this?

elektronrefinitiv-realtimeelektron-sdkrrteta-apielektron-transport-apiDACSc
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
Accepted
4.4k 10 6 9

Hi @noblerain72

By default, the example uses your system login credentials as username. Please see the prior tutorial.

You will have to override the default credentials with you DACS ID.

char dacsID[] = "MY_DACS_ID";
...
void init()
{
...
  if (rsslInitDefaultRDMLoginRequest(&loginRequest, 1) != RSSL_RET_SUCCESS)
  {
    printf("rsslInitDefaultRDMLoginRequest() failed\n");
    cleanUpAndExit(-1);
  }
  strcpy(loginRequest.userName.data,dacsID);
  loginRequest.userName.length = strlen(dacsID);
...
}
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

@noblerain72

loginRequest.userName is a RsslBuffer.

typedef struct
{
	rtrUInt32	length;		/*!< The length of the buffer. */
	char		*data;		/*!< The actual data buffer. */
} RwfBuffer;
<br>

It needs to populate both data (char *) and length (int32).

The code should be:

char dacsID[] = "MY_DACS_ID";
...
void init()
{
...
  if
(rsslInitDefaultRDMLoginRequest(&loginRequest, 1) != RSSL_RET_SUCCESS)
  {  
printf("rsslInitDefaultRDMLoginRequest() failed\n"); 
cleanUpAndExit(-1);
  }
loginRequest.userName.data = &dacsID[0];
loginRequest.userName.length = strlen(dacsID);
...
}
Upvote
11.7k 57 39 60

Hi @noblerain72,

Did you try to include your DACS user name here:

Depending on how your DACS system is setup, you may also need to include your .position() and/or .applicationId() in addition to your username. These are additional methods on the OmmConsumer().


ahs.png (15.3 KiB)
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.