You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by GitBox <gi...@apache.org> on 2020/03/14 07:31:01 UTC

[GitHub] [skywalking] mrproliu commented on issue #4509: SkyWalking Cross Process Correlation Headers Protocol

mrproliu commented on issue #4509: SkyWalking Cross Process Correlation Headers Protocol
URL: https://github.com/apache/skywalking/pull/4509#issuecomment-599022885
 
 
   > > > > I'm wondering whether it's worthwhile to make it JSON, I remember @mrproliu your first suggestion is to encode the key and value respectively, and concatenate them with :, which IMO is good enough and efficient, JSON is more human readable but cost more bandwidth
   > > > 
   > > > 
   > > > @kezhenxu94 , the JSON format is not written by me. I think @mrproliu changed this because your question about the `:` in the key or value.
   > > 
   > > 
   > > My first thought was to use internal encode as data encoding, but I later thought that there might be a problem. I just reread the base64 specification, but there is no risk of ':'. In fact, it can be used.
   > > Can we use 'Base64 (userkey1): Base64 (uservalue2), Base64 (userkey2): Base64 (uservalue2) `. But if we are thinking about coding constantly, will it affect the efficiency? @kezhenxu94 @wu-sheng Any Suggestion?
   > 
   > Why make it so complicated, I did say `:` could appear in the key or value, but `:` could never appear in **ENCODED** string, my thought is just encode the `key` and `value` respectively, and concatenate them with `:`, to put it simple, the final data would be something like: `<encoded_key>:<encoded_val>`, where `<encoded_key>` and `<encoded_val>` is Base64 encoded, and doesn't contain `:` at all, so the only `:` is our delimiter, did I miss anything @mrproliu ?
   
   I think we're talking in the same way. I agree with this pattern:
   `base64(key):base64(value),base64(key):base64(value)`

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services