When publishing data via the writer API should it be assumed that there is a 1:1 relationship between the timestamps and the numeric, string and binary values?
So if there were 2 timestamps there should be either 0 string values or 2 string values, never 1?
E.g. This JSON is somewhat invalid.
If it is valid I assume that the single string value belongs to the first timestamp and the second has no string value.
Lets use the following table as a different way to represent your payload
Timestamp
myNum
route_access
userId
authorized
1682524713287000
0
publish
L7TxOtH5pFJypHGz
true
1684207238000287
1
You will see that the second row now has several empty values. The problem here is ambiguity of expected outcome. Would it be 1 or 2 ?
Timestamp
myNum
route_access
userId
authorized
1682524713287000
0
publish
L7TxOtH5pFJypHGz
true
1684207238000287
1
null
null
null
Timestamp
myNum
route_access
userId
authorized
1682524713287000
0
publish
L7TxOtH5pFJypHGz
true
1684207238000287
1
publish
L7TxOtH5pFJypHGz
true
The answer is that it depends on what you want to achieve. It also gets more complicated when you have more timestamps and miss-matching array length, maybe gaps between data. The only realistic solution here would be to fill the column while you have data (see 1. above) in my opinion.
While the above is not impossible, to avoid confusion and to set clear expectations, we always expect null. Maybe in the future we’ll allow omitting the trailing nulls to reduce the payload package if someone wants to spend the extra logic to do it.
TLDR: The backend currently expects these arrays to match in length, so your request should be equivalent to