question

Upvotes
Accepted
3 1 2 5

Message "Attempt to get servieId while it is not set" on client registering and no progress after it

Hallo!

I am trying to run the TRCC Contribution example.

It goes until calling of consumer.registerClient, then i see message "Attempt to get servieId while it is not set" and no progress anymore. Debug all doesn't show any helpful information except of handshaking logs.

Channel config:

		<Channel>
			<Name value="Channel_1"/>
			<ChannelType value="ChannelType::RSSL_ENCRYPTED"/>
			<Host value="chp02-emea1.thomsonreuters.com"/>
			<Port value="443"/>
		</Channel>

Code:

OmmConsumerClient appClient = new OmmConsumerClientImpl();

OmmConsumer consumer = EmaFactory.createOmmConsumer(EmaFactory.createOmmConsumerConfig().tunnelingKeyStoreFile(PATH).tunnelingKeyStorePasswd(PASSWORD));

ClassOfService cos = EmaFactory.createClassOfService()
	.authentication(EmaFactory.createCosAuthentication()
		.type(CosAuthentication.CosAuthenticationType.NOT_REQUIRED))
	.dataIntegrity(EmaFactory.createCosDataIntegrity()
		.type(CosDataIntegrity.CosDataIntegrityType.RELIABLE))
	.flowControl(EmaFactory.createCosFlowControl()
		.type(CosFlowControl.CosFlowControlType.BIDIRECTIONAL)
		.recvWindowSize(1200))
	.guarantee(EmaFactory.createCosGuarantee()
		.type(CosGuarantee.CosGuaranteeType.NONE));

System.out.println("Starting tunnel stream...");
TunnelStreamRequest tsr = EmaFactory.createTunnelStreamRequest()
    .classOfService(cos)
	.domainType(EmaRdm.MMT_SYSTEM)
	.name("TUNNEL1")
	.serviceName("TEST_SERVICE");

long tunnelStreamHandle = consumer.registerClient(tsr, appClient);

Output without -Djavax.net.debug=all:

Contributing to TR Contributions Channel
Starting encrypted connection...
Jun 06, 2019 8:09:01 AM com.thomsonreuters.ema.access.ChannelCallbackClient reactorChannelEventCallback
INFORMATION: loggerMsg
    ClientName: ChannelCallbackClient
    Severity: Info
    Text:    Received ChannelUp event on channel Channel_1
	Instance Name Consumer_1_1
	Component Version eta3.1.1.L1.linux.rrg 64-bit Static
loggerMsgEnd

<!-- Outgoing Reactor message -->
<!-- java.nio.channels.SocketChannel[connected local=/192.168.178.24:52225 remote=chp02-emea1.thomsonreuters.com/159.220.25.3:443] -->
<!-- Thu Jun 06 08:09:02 CEST 2019 -->
<!-- rwfMajorVer="14" rwfMinorVer="1" -->
<REQUEST domainType="LOGIN" streamId="1" containerType="NO_DATA" flags="0x04 (STREAMING)" dataSize="0">
    <key flags="0x26 (HAS_NAME|HAS_NAME_TYPE|HAS_ATTRIB)" name="Stephan" nameType="1" attribContainerType="ELEMENT_LIST">
        <attrib>
            <elementList flags="0x08 (HAS_STANDARD_DATA)">
                <elementEntry name="ApplicationId" dataType="ASCII_STRING" data="256"/>
                <elementEntry name="ApplicationName" dataType="ASCII_STRING" data="ema"/>
                <elementEntry name="Position" dataType="ASCII_STRING" data="192.168.178.24/DESKTOP-UKCVPSB"/>
                <elementEntry name="Role" dataType="UINT" data="0"/>
            </elementList>
        </attrib>
    </key>
    <dataBody>
    </dataBody>
</REQUEST>

<!-- Incoming Reactor message -->
<!-- java.nio.channels.SocketChannel[connected local=/192.168.178.24:52225 remote=chp02-emea1.thomsonreuters.com/159.220.25.3:443] -->
<!-- Thu Jun 06 08:09:02 CEST 2019 -->
<!-- rwfMajorVer="14" rwfMinorVer="1" -->
<REFRESH domainType="LOGIN" streamId="1" containerType="NO_DATA" flags="0x168 (HAS_MSG_KEY|SOLICITED|REFRESH_COMPLETE|CLEAR_CACHE)" groupId="0" State: Open/Ok/None - text: "" dataSize="0">
    <key flags="0x26 (HAS_NAME|HAS_NAME_TYPE|HAS_ATTRIB)" name="Stephan" nameType="1" attribContainerType="ELEMENT_LIST">
        <attrib>
            <elementList flags="0x08 (HAS_STANDARD_DATA)">
                <elementEntry name="ApplicationId" dataType="ASCII_STRING" data="256"/>
                <elementEntry name="ApplicationName" dataType="ASCII_STRING" data="ema"/>
                <elementEntry name="Position" dataType="ASCII_STRING" data="192.168.178.24/DESKTOP-UKCVPSB"/>
                <elementEntry name="SingleOpen" dataType="UINT" data="0"/>
                <elementEntry name="SupportOMMPost" dataType="UINT" data="1"/>
                <elementEntry name="SupportBatchRequests" dataType="UINT" data="5"/>
            </elementList>
        </attrib>
    </key>
    <dataBody>
    </dataBody>
</REFRESH>

<!-- Outgoing Reactor message -->
<!-- java.nio.channels.SocketChannel[connected local=/192.168.178.24:52225 remote=chp02-emea1.thomsonreuters.com/159.220.25.3:443] -->
<!-- Thu Jun 06 08:09:02 CEST 2019 -->
<!-- rwfMajorVer="14" rwfMinorVer="1" -->
<REQUEST domainType="SOURCE" streamId="2" containerType="NO_DATA" flags="0x04 (STREAMING)" dataSize="0">
    <key flags="0x08 (HAS_FILTER)" filter="63"/>
    <dataBody>
    </dataBody>
</REQUEST>

<!-- Incoming Reactor message -->
<!-- java.nio.channels.SocketChannel[connected local=/192.168.178.24:52225 remote=chp02-emea1.thomsonreuters.com/159.220.25.3:443] -->
<!-- Thu Jun 06 08:09:02 CEST 2019 -->
<!-- rwfMajorVer="14" rwfMinorVer="1" -->
<REFRESH domainType="SOURCE" streamId="2" containerType="MAP" flags="0x168 (HAS_MSG_KEY|SOLICITED|REFRESH_COMPLETE|CLEAR_CACHE)" groupId="0" State: Open/Ok/None - text: "" dataSize="249">
    <key flags="0x08 (HAS_FILTER)" filter="63"/>
    <dataBody>
        <map flags="0x00" countHint="0" keyPrimitiveType="UINT" containerType="FILTER_LIST" >
            <mapEntry flags="0x00" action="ADD" key="10" >
                <filterList containerType="ELEMENT_LIST" countHint="0" flags="0x00">
                    <filterEntry id="1" action="SET" flags="0x00" containerType="ELEMENT_LIST">
                        <elementList flags="0x08 (HAS_STANDARD_DATA)">
                            <elementEntry name="Name" dataType="ASCII_STRING" data="DDS_TRCE"/>
                            <elementEntry name="Vendor" dataType="ASCII_STRING" data="Thomson Reuters RTTG Core Development"/>
                            <elementEntry name="Capabilities" dataType="ARRAY">
                                <array itemLength="0" primitiveType="UINT">
                                    <arrayEntry data="6"/>
                                    <arrayEntry data="127"/>
                                </array>
                            </elementEntry>
                            <elementEntry name="QoS" dataType="ARRAY">
                                <array itemLength="0" primitiveType="QOS">
                                    <arrayEntry Qos: Realtime/TickByTick/Static - timeInfo: 0 - rateInfo: 0/>
                                </array>
                            </elementEntry>
                        </elementList>
                    </filterEntry>
                    <filterEntry id="2" action="SET" flags="0x00" containerType="ELEMENT_LIST">
                        <elementList flags="0x08 (HAS_STANDARD_DATA)">
                            <elementEntry name="ServiceState" dataType="UINT" data="1"/>
                            <elementEntry name="AcceptingRequests" dataType="UINT" data="1"/>
                            <elementEntry name="Status" dataType="STATE" State: Open/Ok/None - text: ""/>
                        </elementList>
                    </filterEntry>
                    <filterEntry id="4" action="SET" flags="0x00" containerType="ELEMENT_LIST">
                        <elementList flags="0x08 (HAS_STANDARD_DATA)">
                            <elementEntry name="OpenWindow" dataType="UINT" data="6"/>
                        </elementList>
                    </filterEntry>
                    <filterEntry id="6" action="SET" flags="0x02 (HAS_CONTAINER_TYPE)" containerType="MAP">
                        <map flags="0x00" countHint="0" keyPrimitiveType="ASCII_STRING" containerType="ELEMENT_LIST" >
                            <mapEntry flags="0x00" action="ADD" key="DDS_TRCE" >
                                <elementList flags="0x08 (HAS_STANDARD_DATA)">
                                    <elementEntry name="Type" dataType="UINT" data="1"/>
                                    <elementEntry name="LinkState" dataType="UINT" data="1"/>
                                </elementList>
                            </mapEntry>
                        </map>
                    </filterEntry>
                </filterList>
            </mapEntry>
        </map>
    </dataBody>
</REFRESH>


Starting tunnel stream...
Registering client...
Attempt to get servieId while it is not set.
elektronrefinitiv-realtimeelektron-sdkema-apirrtelektron-message-apijavaOMMrcc-apierror-message
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.

Hello @markus.fehn

Thank you for your participation in the forum. Is the reply below satisfactory in resolving your query? If yes, please click the 'Accept' text next to the reply. This will guide all community members who have a similar question. Otherwise please post again offering further insight into your question.

Thanks,

AHS

Upvotes
Accepted
78.8k 250 52 74

@markus.fehn

I think that the service name should be "DDS_TRCE", not "TEST_SERVICE".

TunnelStreamRequest tsr = EmaFactory.createTunnelStreamRequest() .classOfService(cos) .domainType(EmaRdm.MMT_SYSTEM) .name("TUNNEL1") .serviceName("DDS_TRCE");
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.

Thanks for your suggestion, already tried many different service names and this one also :)

Upvotes
24.6k 54 17 14

Hello @markus.fehn

I assume that you are using TRCC example Contributor.java file. Could you please share your modification Contributor.java, EmaConfig.xml files? Please also remove your credentials detail from the code before you share it in this post.

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.

Thanks for support!

<?xml version="1.0" encoding="UTF-8"?>
<EmaConfig>
<ConsumerGroup>
	<DefaultConsumer value="Consumer_1"/>
	<ConsumerList>
		<Consumer>
			<Name value="Consumer_1"/>
			<Channel value="Channel_1"/>			
			<Logger value="Logger_2"/>
			<Dictionary value="Dictionary_2"/>
			<XmlTraceToStdout value="1"/>
		</Consumer>
	</ConsumerList>
</ConsumerGroup>
<ChannelGroup>
	<ChannelList>
		<Channel>
			<Name value="Channel_1"/>
			<ChannelType value="ChannelType::RSSL_ENCRYPTED"/>
			<Host value="chp02-emea1.thomsonreuters.com"/>
			<Port value="443"/>
		</Channel>
	</ChannelList>
</ChannelGroup>
<DictionaryGroup>
	<DictionaryList>
		<Dictionary>
			<Name value="Dictionary_2"/>
			<DictionaryType value="DictionaryType::FileDictionary"/>
			<RdmFieldDictionaryFileName value="win32/etc/RDMFieldDictionary"/>
			<EnumTypeDefFileName value="win32/etc/enumtype.def"/>
		</Dictionary>
	</DictionaryList>
</DictionaryGroup>
</EmaConfig>
public class Contributor {
	public static void main(String[] args) {
		try {
			System.out.println("Contributing to TR Contributions Channel");
			OmmConsumerClientImpl appClient = new OmmConsumerClientImpl();
			System.out.println("Starting encrypted connection...");
			OmmConsumer consumer = EmaFactory.createOmmConsumer(EmaFactory.createOmmConsumerConfig()
					.tunnelingKeyStoreFile(KS).tunnelingKeyStorePasswd(PWD));

			ClassOfService cos = EmaFactory.createClassOfService().authentication(EmaFactory.createCosAuthentication().type(CosAuthentication.CosAuthenticationType.NOT_REQUIRED)).dataIntegrity(EmaFactory.createCosDataIntegrity().type(CosDataIntegrity.CosDataIntegrityType.RELIABLE)).flowControl(EmaFactory.createCosFlowControl().type(CosFlowControl.CosFlowControlType.BIDIRECTIONAL).recvWindowSize(1200)).guarantee(EmaFactory.createCosGuarantee().type(CosGuarantee.CosGuaranteeType.NONE));
			System.out.println("Starting tunnel stream...");
			TunnelStreamRequest tsr = EmaFactory.createTunnelStreamRequest().classOfService(cos)
					.domainType(EmaRdm.MMT_SYSTEM).name("TUNNEL1").serviceName("TEST_SERVICE");
			System.out.println("Registering client...");
			long tunnelStreamHandle = consumer.registerClient(tsr, appClient);
			appClient.setOmmConsumer(consumer);
			appClient.setTunnelHandle(tunnelStreamHandle);
			System.out.println("Application client is configred!");
			Thread.sleep(60000);
		} catch (Exception excp) {
			System.out.println(excp.getMessage());
		}
	}


}

Upvote
24.6k 54 17 14

Hi @markus.fehn

Like @jirapongse.phuriphanvichai suggestion, based on the xml trace log, your TRCC service name is "DDS_TRCE" not "TEST_SERVICE". Did you try to use "DDS_TRCE" service name yet?



I can replicate the issue in my environment using your code, your configuration (the same

chp02-emea1.thomsonreuters.com server) with my TRCC account.

With your "TEST_SERVICE" code, I got the same "Attempt to get servieId while it is not set." error message.

TunnelStreamRequest tsr = EmaFactory.createTunnelStreamRequest().classOfService(cos)
        .domainType(EmaRdm.MMT_SYSTEM).name("TUNNEL1").serviceName("TEST_SERVICE");

Result:

Starting tunnel stream...
Registering client...
Attempt to get servieId while it is not set.

But when I change the code to "DDS_TRCE" that match the actual service name, the post application works fine.

TunnelStreamRequest tsr = EmaFactory.createTunnelStreamRequest().classOfService(cos)
    .domainType(EmaRdm.MMT_SYSTEM).name("TUNNEL1").serviceName("DDS_TRCE");

Result:

----- Ack message ----
AckMsg
    streamId="5"
    domain="MarketPrice Domain"
    ackId="1"
AckMsgEnd

Continue posting...

Please see my detail in my log files. app-logs-issue.txt


config.png (74.0 KiB)
app-logs-issue.txt (6.6 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.

Upvote
24.6k 54 17 14

@markus.fehn

Please see my success log with serviceName("DDS_TRCE") code here app-logs-work.txt


app-logs-work.txt (29.1 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.

Upvotes
3 1 2 5

Thanks a lot! Yes, it is working with DDS_TRCE now!

I remembering that tried it, but may be i am wrong!

Thanks again!

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.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

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