question

Upvotes
Accepted
2 0 0 2

Error Encoding Batch Market Item Request

I an using the batch feature when seding a market price item request message using the UPA api. I am getting the following error when calling rsslEncodeElementEntryComplete, which follows the encoding of the array of item names in the batch:

rsslEncodeElementEntryComplete() failed with return code: RSSL_RET_INVALID_DATA (-29) Error Text: Failure: Invalid data provided to function.­

I get this error when I have a large number of iterms in the batch (>8500). My batch request will works with an iterm count less than this number. It's not clear to me from the error what data is invalid. There are only two parameters passed to rsslEncodeElementEntryComplete, the encodeIterator and a boolean value. So it appears that something is wrong with the encode iterator but I don't have a way to tell what the issue is. Is there a way to determine the source of the error here?

Thanks.

elektronelektron-sdkrrteta-apielektron-transport-api
icon clock
10 |1500

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

1 Answer

Upvote
Accepted
4.4k 10 6 9

Hi @Bill Steinberg

The content of element entry has a maximum encoded length of 65,535 bytes. This is a limitation in UPA and ETA as mentioned in developer guide.

I believe your 8500+ items array exceeds the maximum length.

icon clock
10 |1500

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

Thanks Warat B. Didn't realize there is a 64K limitation. Looks like I will need to parttition my batch request around this limit.

Click below to post an Idea Post Idea