Mesos
  1. Mesos
  2. MESOS-34

Rendering JSON needs to escape strings properly.

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.9.0
    • Fix Version/s: 0.10.0
    • Component/s: webui
    • Labels:
      None

      Description

      The JSON rendering code needs to get updated to properly escape strings.

        Activity

        Hide
        Rohit Turumella added a comment -

        I'm one of the undergrad researchers. I'll be working on the JIRA. Currently looking through the codebase to see how the webUI component works.

        -Rohit

        Show
        Rohit Turumella added a comment - I'm one of the undergrad researchers. I'll be working on the JIRA. Currently looking through the codebase to see how the webUI component works. -Rohit
        Hide
        Rohit Turumella added a comment -

        Hi,

        It looks like the json is being created in the json.h header file in src/common. Does anyone know what files invoke this by any chance? I'll continue poking/searching around.

        -Rohit

        Show
        Rohit Turumella added a comment - Hi, It looks like the json is being created in the json.h header file in src/common. Does anyone know what files invoke this by any chance? I'll continue poking/searching around. -Rohit
        Hide
        Andy Konwinski added a comment -

        [~/Development/mesos]$ cd src/master
        [~/Development/mesos/src/master]$ grep json.hpp ./*
        ./http.cpp:#include "common/json.hpp"

        Show
        Andy Konwinski added a comment - [~/Development/mesos] $ cd src/master [~/Development/mesos/src/master] $ grep json.hpp ./* ./http.cpp:#include "common/json.hpp"
        Hide
        Rohit Turumella added a comment -

        I'm thinking of using the following JSON library (JSONCpp, http://jsoncpp.sourceforge.net/).

        It's under the MIT license, is that alright to include? Also, if anyone has any other suggestions for other libraries, that would be great.

        Show
        Rohit Turumella added a comment - I'm thinking of using the following JSON library (JSONCpp, http://jsoncpp.sourceforge.net/ ). It's under the MIT license, is that alright to include? Also, if anyone has any other suggestions for other libraries, that would be great.
        Hide
        jiraposter@reviews.apache.org added a comment -

        -----------------------------------------------------------
        This is an automatically generated e-mail. To reply, visit:
        https://reviews.apache.org/r/5104/
        -----------------------------------------------------------

        (Updated 2012-05-14 03:31:53.426774)

        Review request for mesos and Benjamin Hindman.

        Changes
        -------

        added the bug

        Summary
        -------

        see summary

        This addresses bug MESOS-34.
        https://issues.apache.org/jira/browse/MESOS-34

        Diffs


        src/common/json.hpp 44e4392

        Diff: https://reviews.apache.org/r/5104/diff

        Testing
        -------

        make check

        Thanks,

        Jonathan

        Show
        jiraposter@reviews.apache.org added a comment - ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/5104/ ----------------------------------------------------------- (Updated 2012-05-14 03:31:53.426774) Review request for mesos and Benjamin Hindman. Changes ------- added the bug Summary ------- see summary This addresses bug MESOS-34 . https://issues.apache.org/jira/browse/MESOS-34 Diffs src/common/json.hpp 44e4392 Diff: https://reviews.apache.org/r/5104/diff Testing ------- make check Thanks, Jonathan
        Hide
        jiraposter@reviews.apache.org added a comment -

        -----------------------------------------------------------
        This is an automatically generated e-mail. To reply, visit:
        https://reviews.apache.org/r/5104/#review7863
        -----------------------------------------------------------

        Ship it!

        • Benjamin

        On 2012-05-14 03:31:53, Jonathan Fuchs wrote:

        -----------------------------------------------------------

        This is an automatically generated e-mail. To reply, visit:

        https://reviews.apache.org/r/5104/

        -----------------------------------------------------------

        (Updated 2012-05-14 03:31:53)

        Review request for mesos and Benjamin Hindman.

        Summary

        -------

        see summary

        This addresses bug MESOS-34.

        https://issues.apache.org/jira/browse/MESOS-34

        Diffs

        -----

        src/common/json.hpp 44e4392

        Diff: https://reviews.apache.org/r/5104/diff

        Testing

        -------

        make check

        Thanks,

        Jonathan

        Show
        jiraposter@reviews.apache.org added a comment - ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/5104/#review7863 ----------------------------------------------------------- Ship it! Benjamin On 2012-05-14 03:31:53, Jonathan Fuchs wrote: ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/5104/ ----------------------------------------------------------- (Updated 2012-05-14 03:31:53) Review request for mesos and Benjamin Hindman. Summary ------- see summary This addresses bug MESOS-34 . https://issues.apache.org/jira/browse/MESOS-34 Diffs ----- src/common/json.hpp 44e4392 Diff: https://reviews.apache.org/r/5104/diff Testing ------- make check Thanks, Jonathan
        Hide
        Benjamin Hindman added a comment -

        This is all but for unicode, but even existing C++ JSON libraries that I know of are not doing unicode, so this is good enough for now. We can create another JIRA if/when we run across the unicode issue.

        Show
        Benjamin Hindman added a comment - This is all but for unicode, but even existing C++ JSON libraries that I know of are not doing unicode, so this is good enough for now. We can create another JIRA if/when we run across the unicode issue.

          People

          • Assignee:
            Rohit Turumella
            Reporter:
            Benjamin Hindman
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Due:
              Created:
              Updated:
              Resolved:

              Development