0:25, EET
March 26, 2014
Hello,
With SDK version 2.2.0-552 I created an Object with a Method that returns a String.
If the String has 4194183 characters in it, everything is fine and the client can call the method in less than 250 ms.
If I add just one character (4194184) the client will get a TimeOut (after 2 minutes with my settings).
If I call the method with UaExpert it is the same (which makes me believe it must be a problem with the server).
My settings are the one at the end of this blog : https://www.prosysopc.com/blog/subscribing-to-a-very-large-number-of-nodes-in-a-prosys-opc-ua-java-sdk-based-server/
With WARN log level I have only a log for the timeout itself in the server.
I made another test with no settings in the client or server. If I request 4194183 chars I have the logical error : Bad_EncodingLimitsExceeded (code=0x80080000, description=”MaxStringLength 65535 < 4194183")
But If the String has 4194184 chars then it takes 2 minutes and then I have the timeout exception but nothing about the limit being exceeded.
I don’t think it’s relevant but this object was created with UaModeler and the code generated with the tool in the sdk and I did not try another way.
Thanks
13:15, EET
April 3, 2012
I started testing by calling a method with that size of Strings (I noticed later that you talked about returning one). I got the following exception:
Exception in thread “main” com.prosysopc.ua.ServiceException: Bad_EncodingLimitsExceeded (code=0x80080000, description=”MaxMessageSize 4194240 < 4194265") ServiceResult=Bad_EncodingLimitsExceeded (0x80080000) "The message encoding/decoding limits imposed by the stack have been exceeded."
at com.prosysopc.ua.client.UaClient.call(UaClient.java:705)
at com.prosysopc.ua.client.UaClient.call(UaClient.java:747)
at com.prosysopc.ua.tests.SandboxClient.main(SandboxClient.java:74)
Caused by: org.opcfoundation.ua.encoding.EncodingException: Bad_EncodingLimitsExceeded (code=0x80080000, description="MaxMessageSize 4194240 < 4194265")
at org.opcfoundation.ua.transport.tcp.io.TcpConnection.encodeMessage(TcpConnection.java:1260)
at org.opcfoundation.ua.transport.tcp.io.TcpConnection.sendRequest(TcpConnection.java:1076)
at org.opcfoundation.ua.transport.tcp.io.SecureChannelTcp.serviceRequest(SecureChannelTcp.java:348)
at org.opcfoundation.ua.transport.tcp.io.SecureChannelTcp.serviceRequest(SecureChannelTcp.java:322)
at org.opcfoundation.ua.application.SessionChannel.serviceRequest(SessionChannel.java:301)
at org.opcfoundation.ua.transport.ChannelService.Call(ChannelService.java:1714)
at com.prosysopc.ua.client.UaClient.call(UaClient.java:698)
… 2 more
Did you also set the MaxMessageSize to be larger? Also in the server settings? Because the default max size is very close to the number of yours (there is a bit overhead from the communication layer on top of the data so in this case +1 might be enough to go over that limit). I will test returning the value from method next..
– Bjarne
14:55, EET
April 3, 2012
15:29, EET
April 3, 2012
Ok,
You need to set the following for both the client and the server:
EndpointConfiguration ec = UaClient/UaServer.getEndpointConfiguration();
ec.setMaxMessageSize(Integer.MAX_VALUE);
ec.setMaxStringLength(Integer.MAX_VALUE);
(or some other lower value)
I would assume that the limit for the sent message is the lowest of the MaxMessageSizes (client or server). I’m not sure how the logging should work here, need to check that in the next release.
– Bjarne
Most Users Ever Online: 1919
Currently Online:
17 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
Heikki Tahvanainen: 402
hbrackel: 144
rocket science: 88
pramanj: 86
Francesco Zambon: 83
Ibrahim: 78
Sabari: 62
kapsl: 57
gjevremovic: 49
Xavier: 43
Member Stats:
Guest Posters: 0
Members: 738
Moderators: 7
Admins: 1
Forum Stats:
Groups: 3
Forums: 15
Topics: 1524
Posts: 6451
Newest Members:
jonathonmcintyre, fannielima, kristiewinkle8, rust, christamcdowall, redaahern07571, nigelbdhmp, travistimmons, AnnelCib, dalenegettingerModerators: Jouni Aro: 1026, Pyry: 1, Petri: 0, Bjarne Boström: 1026, Jimmy Ni: 26, Matti Siponen: 346, Lusetti: 0
Administrators: admin: 1