code: public void marshall(Connection connection, ProtocolMarshaller protocolMarshaller) {
  
          if (connection == null) {
              throw new SdkClientException("Invalid argument passed to marshall(...)");
          }
  
          try {
              protocolMarshaller.marshall(connection.getReplicationInstanceArn(), REPLICATIONINSTANCEARN_BINDING);
              protocolMarshaller.marshall(connection.getEndpointArn(), ENDPOINTARN_BINDING);
              protocolMarshaller.marshall(connection.getStatus(), STATUS_BINDING);
              protocolMarshaller.marshall(connection.getLastFailureMessage(), LASTFAILUREMESSAGE_BINDING);
              protocolMarshaller.marshall(connection.getEndpointIdentifier(), ENDPOINTIDENTIFIER_BINDING);
              protocolMarshaller.marshall(connection.getReplicationInstanceIdentifier(), REPLICATIONINSTANCEIDENTIFIER_BINDING);
          } catch (Exception e) {
              throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e);
          }
      }
docs: Marshall the given parameter object.