Skip to content

Add methods toPrettyJsonString() and toSingleLineJsonString() to Schema#3783

Merged
Jackie-Jiang merged 1 commit intomasterfrom
zk_schema
Feb 2, 2019
Merged

Add methods toPrettyJsonString() and toSingleLineJsonString() to Schema#3783
Jackie-Jiang merged 1 commit intomasterfrom
zk_schema

Conversation

@Jackie-Jiang
Copy link
Contributor

  • For human-read API, use pretty string
  • For other purpose, use compact single-line string

Fix the issue of storing pretty string in ZK (consume more space and less readable)

- For human-read API, use pretty string
- For other purpose, use compact single-line string

Fix the issue of storing pretty string in ZK (consume more space and less readable)
@codecov-io
Copy link

Codecov Report

Merging #3783 into master will increase coverage by 0.05%.
The diff coverage is 66.66%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master    #3783      +/-   ##
============================================
+ Coverage     67.22%   67.28%   +0.05%     
  Complexity        4        4              
============================================
  Files          1027     1027              
  Lines         50812    50816       +4     
  Branches       7091     7091              
============================================
+ Hits          34159    34192      +33     
+ Misses        14312    14286      -26     
+ Partials       2341     2338       -3
Impacted Files Coverage Δ Complexity Δ
...org/apache/pinot/common/config/CombinedConfig.java 34.48% <0%> (-2.56%) 0 <0> (ø)
...not/controller/api/resources/PinotTableSchema.java 0% <0%> (ø) 0 <0> (ø) ⬇️
...main/java/org/apache/pinot/common/data/Schema.java 80.51% <100%> (+0.17%) 0 <0> (ø) ⬇️
...ava/org/apache/pinot/common/utils/SchemaUtils.java 9.85% <50%> (ø) 0 <0> (ø) ⬇️
...ller/api/resources/PinotSchemaRestletResource.java 40.57% <50%> (ø) 0 <0> (ø) ⬇️
...er/validation/BrokerResourceValidationManager.java 31.57% <0%> (-42.11%) 0% <0%> (ø)
...a/manager/realtime/RealtimeSegmentDataManager.java 75% <0%> (-25%) 0% <0%> (ø)
...egation/function/customobject/MinMaxRangePair.java 75.86% <0%> (-24.14%) 0% <0%> (ø)
...lix/EmptyBrokerOnlineOfflineStateModelFactory.java 86.66% <0%> (-13.34%) 0% <0%> (ø)
...impl/dictionary/DoubleOnHeapMutableDictionary.java 68.88% <0%> (-13.34%) 0% <0%> (ø)
... and 33 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update cc658e4...71b04e6. Read the comment docs.

Copy link
Contributor

@snleee snleee left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we plan to do this for table config as well? Otherwise, LGTM

@sunithabeeram
Copy link
Contributor

The impact of this change is unclear to me. Will any API responses be affected by this change? If so we should check backward compatibility implications.

@Jackie-Jiang
Copy link
Contributor Author

@sunithabeeram We support both format, and it's mainly for saving space & readability.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants