Uploaded image for project: 'Camel'
  1. Camel
  2. CAMEL-8528

rest-dsl - Allow producers to control what content-type header to return

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 2.15.0
    • 2.16.0
    • camel-core, rest
    • None
    • Unknown

    Description

      For example having

                      rest("book").produces("application/json")
                          .get("/order/{id}")
                              .to("bean:bookService?method=getOrder");
      

      You may want this rest service to return application/json as the content-type header.

      We should have an option that control what behavior to use

      • always use
      • use if no existing header
      • off

      Attachments

        Activity

          People

            davsclaus Claus Ibsen
            davsclaus Claus Ibsen
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: