-
Notifications
You must be signed in to change notification settings - Fork 848
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
putAttribute vs. setAttribute #25
Comments
my understanding was always that Is it |
I think this is very language specific. In Java we went with the "map" terminology of put, and it has the same semantics. |
@SergeyKanzhelev yes, it's SetTag/setTag/set_tag in OT Go/Java/Python @bogdandrutu are you saying the name would change in a different language? That will probably be rather confusing. |
I'm fine either way |
@yurishkuro If we want to have generic names I am fine with that, though some java devs will get confused about terminology. One option is to use standard terminology for all these "map" like operations (we use this in tags in golang):
|
I prefer not over to complicate things. The one caveat from OT is that SetTag() had unspecified behavior if called more than once with the same key. This wasn't related to |
I agree that the implementation can keep everything in an array, but when exported to you dedup? |
You can, but it's still extra CPU cycles and memory allocations that become necessary if the API semantics require key uniqueness. |
Then we should say that attributes is a List<Pair<Key, Value>>, so a better name is "addAttribute" probably. |
I agree on this one - I think we can either go with |
Decision: setAttributes, the behavior is a List of attributes and if the backend dedups then the ordering should be guaranteed. |
* Removed URLEncoder * Fixed typo * Added URLDecoding * Included comment for string replacement * Added unit tests for special characters in span names * Resolved URL decoding issues * Moved url decoding to parseQueryMap and updated the corresponding unit tests * Added a README file for zPage quickstart * Add images for README * Updated README * Add frontend images * Add backend images * Added our design doc * Added details on package * Reworded a few lines * Moved DESIGN.md to a docs folder and changed gradle config to implementation * Changed wording regarding HttpServer requirement * Added zpages folder under docs, resolved broken image links * Resolved comments for the design md file * Made a few wording changes * Wrote a benchmark test for TracezSpanBuckets (#23) * Scaffolded logic for basic benchmark tests * Wrote benchmark tests for TracezSpanBuckets * Updated README with benchmark tests * Changed the wording slightly * Updated README file (#25) * Wrote benchmark tests for TracezDataAggregator (#24) * Scaffolded logic for basic benchmark tests * Wrote benchmark tests for TracezSpanBuckets * Updated README with benchmark tests * Changed the wording slightly * Added a set of benchmark tests for TracezDataAggregator * Modified README formatting * Changed benchmark test to negate dead code elimination * Added Javadocs to the TracezDataAggregator benchmark tests * Removed benchmark results from README and added a param to the TracezDataAggregator benchmark tests * Update sdk_extensions/zpages/src/jmh/java/io/opentelemetry/sdk/extensions/zpages/TracezDataAggregatorBenchmark.java Co-authored-by: Anuraag Agrawal <[email protected]> * Added multiple param values for TracezDataAggregatorBenchmark Co-authored-by: Terry Wang <[email protected]> Co-authored-by: Anuraag Agrawal <[email protected]>
* Removed URLEncoder * Fixed typo * Added URLDecoding * Included comment for string replacement * Added unit tests for special characters in span names * Resolved URL decoding issues * Moved url decoding to parseQueryMap and updated the corresponding unit tests * Added a README file for zPage quickstart * Add images for README * Updated README * Add frontend images * Add backend images * Added our design doc * Added details on package * Reworded a few lines * Moved DESIGN.md to a docs folder and changed gradle config to implementation * Changed wording regarding HttpServer requirement * Added zpages folder under docs, resolved broken image links * Resolved comments for the design md file * Made a few wording changes * Wrote a benchmark test for TracezSpanBuckets (#23) * Scaffolded logic for basic benchmark tests * Wrote benchmark tests for TracezSpanBuckets * Updated README with benchmark tests * Changed the wording slightly * Updated README file (#25) * Wrote benchmark tests for TracezDataAggregator (#24) * Scaffolded logic for basic benchmark tests * Wrote benchmark tests for TracezSpanBuckets * Updated README with benchmark tests * Changed the wording slightly * Added a set of benchmark tests for TracezDataAggregator * Modified README formatting * Changed benchmark test to negate dead code elimination * Added Javadocs to the TracezDataAggregator benchmark tests * Removed benchmark results from README and added a param to the TracezDataAggregator benchmark tests * Update sdk_extensions/zpages/src/jmh/java/io/opentelemetry/sdk/extensions/zpages/TracezDataAggregatorBenchmark.java Co-authored-by: Anuraag Agrawal <[email protected]> * Added multiple param values for TracezDataAggregatorBenchmark * Changed TraceConfigz zPage form submit to use POST request * Added requestMethod parameter to emitHtml, limited TraceConfig change on POST request only * Removed duplicate parse function, added test for update on POST request only * Added separate method for processing request * Removed unnecessary error check in tests, used try resources for inputstream Co-authored-by: williamhu99 <[email protected]> Co-authored-by: William Hu <[email protected]> Co-authored-by: Anuraag Agrawal <[email protected]>
I am just curious if there was some consideration behind the
put
name, and if so to document it here.The text was updated successfully, but these errors were encountered: