You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Tomasz Ptak (JIRA)" <ji...@apache.org> on 2015/04/13 16:36:12 UTC

[jira] [Created] (CAMEL-8625) Form fields overwrite headers in InMessage

Tomasz Ptak created CAMEL-8625:
----------------------------------

             Summary: Form fields overwrite headers in InMessage
                 Key: CAMEL-8625
                 URL: https://issues.apache.org/jira/browse/CAMEL-8625
             Project: Camel
          Issue Type: Bug
          Components: camel-restlet
    Affects Versions: 2.15.1, 2.14.2, 2.13.4
         Environment: Linux
            Reporter: Tomasz Ptak


DefaultRestletBinding adds values from submitted form as headers in the inMessage of the exchange. As a result it is close to impossible to rely on any of the values provided.
Suggested solution:
a) form values should be stored separately, or
b) populating headers from the form should fail if a header with this key already exists

Solution a is a safer solution which will break compatibility with previous versions of Apache Camel (it can also be spread over a number of releases, first introducing new field for form values and logging a warning if form data is being extracted, next making it configurable and disabled by default, then removing this functionality).
Solution b is backwards compatible if this behaviour is not used as a feature  (if it is, it should not). That said someone could still use it to populate RestletRequest-like headers in the Message.

I can provide a patch if any solution is accepted.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)