Qpid Proton
  1. Qpid Proton
  2. PROTON-317

Feature Enhancement - API Exposure of underlying references to internal atoms


    • Type: Improvement Improvement
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.3
    • Fix Version/s: 0.5
    • Component/s: proton-c
    • Labels:
    • Environment:
      Linux / C implementation


      We're currently creating a pn_message_t and iterating over it using the pn_data_t data type and the various convenience methods surrounding it. This is great for iteration but we were also hoping to have a way to mark a point in the payload for future realignment. I looked at get_message_id() but that always seems to return NULL.

      Let's take a pseudo example:

      pn_data_rewind (pn_data);
      while (pn_data_next (pn_data))
      pn_atom_t atom = pn_data_get_atom (pn_data);

      { // Mark this for potential modification later }


      if (changes_are_required_based_on_a_combination_of_circumstances)

      { // Jump to earlier marker(s) // put in relevant update(s) }

      Is there anything we could use for this sort of use case? I want to avoid having to iterate again to find values, and I also want to be able to write functions which don't move (or move, then reset) the internal buffer pointers in proton. If there was something like a get_position() or set_position(), that would be perfect.


        Frank Quinn created issue -
        Rafael H. Schloming made changes -
        Field Original Value New Value
        Fix Version/s 0.5 [ 12324004 ]
        Rafael H. Schloming made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Rafael H. Schloming made changes -
        Assignee Rafael H. Schloming [ rhs ]


          • Assignee:
            Rafael H. Schloming
            Frank Quinn
          • Votes:
            0 Vote for this issue
            2 Start watching this issue


            • Created: