Davide Simoncelli created S4-58:
-----------------------------------

             Summary: Keyed events sent by clients are injected without keys in 
S4 cluster
                 Key: S4-58
                 URL: https://issues.apache.org/jira/browse/S4-58
             Project: Apache S4
          Issue Type: Bug
    Affects Versions: 0.3
         Environment: Ubuntu Linux
java version "1.6.0_24"
OpenJDK Runtime Environment (IcedTea6 1.11.1) (6b24-1.11.1-4ubuntu3)
OpenJDK 64-Bit Server VM (build 20.0-b12, mixed mode)

            Reporter: Davide Simoncelli


The method toJson in Message class converts the message into JSON but it uses a 
wrong field name for keys' event 
(https://github.com/s4/s4/blob/v0.3.0/s4-driver/java/src/main/java/io/s4/client/Message.java#L87)

The documentation at 
http://docs.s4.io/manual/client_adapter.html#sending-events-into-s4-cluster 
says that 'keys' field should be used to send keys to adapters but the 
implementation uses 'keysName'. 

Here is the fix:

        if (this.keyNames != null) {
            json.put("keys", this.keyNames);
        }


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to