Description
Loadgenerator construct Message object and mashall it with json format,and GenericJsonClientStub#eventWrapperFromBytes method unmarshall the json data to EventWrapper object.
There is something wrong with key-field-name,GenericJsonClientStub#eventWrapperFromBytes obtain key-field-name by ‘keys’ field from json,and Message# toJson method marshall it with ‘keyNames’.we can modify org.apache.s4.client.Message#toJson method as follows to fix the bug:
public void toJson(JSONObject json) throws JSONException {
json.put("stream", this.stream);
json.put("class", this.clazz);
if (this.keys != null)
json.put("object", this.object);
}
Attachments
Issue Links
- is duplicated by
-
S4-58 Keyed events sent by clients are injected without keys in S4 cluster
- Resolved