Skip to content
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

Default column name to pojo field name, and add allFields mode to Measurement annotation #972

Merged
merged 3 commits into from Dec 2, 2023

Conversation

eranl
Copy link
Contributor

@eranl eranl commented Dec 2, 2023

if @Column is used without a name, the annotated field's name is used as the column name.

In addition, when a pojo is annotated with @Measurement(name = "...", allFields = true), then all its fields are loaded or saved.
Finally, an @Exclude annotation can be used for opting a field out in this mode.

Fixes #971.

@codecov-commenter
Copy link

codecov-commenter commented Dec 2, 2023

Codecov Report

Attention: 3 lines in your changes are missing coverage. Please review.

Comparison is base (d3a7bbc) 61.22% compared to head (32d31ac) 61.28%.

❗ Current head 32d31ac differs from pull request most recent head aeaba32. Consider uploading reports for the commit aeaba32 to get more accurate results

Files Patch % Lines
src/main/java/org/influxdb/dto/Point.java 81.81% 0 Missing and 2 partials ⚠️
...n/java/org/influxdb/impl/InfluxDBResultMapper.java 88.88% 0 Missing and 1 partial ⚠️

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@             Coverage Diff              @@
##             master     #972      +/-   ##
============================================
+ Coverage     61.22%   61.28%   +0.06%     
- Complexity      443      450       +7     
============================================
  Files            70       70              
  Lines          2579     2591      +12     
  Branches        271      277       +6     
============================================
+ Hits           1579     1588       +9     
  Misses          932      932              
- Partials         68       71       +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@majst01
Copy link
Collaborator

majst01 commented Dec 2, 2023

Nice PR, thanks for you contribution, can you please also add a bit of documentation of you new features, best place would be here.

If this is done, i am happy to merge

@eranl
Copy link
Contributor Author

eranl commented Dec 2, 2023

can you please also add a bit of documentation of you new features, best place would be here.

Updated. Please review.

@majst01 majst01 merged commit ba9bfeb into influxdata:master Dec 2, 2023
18 checks passed
@eranl eranl deleted the allFields branch December 2, 2023 17:28
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.

Default column name to pojo field name, and add allFields mode to Measurement annotation
3 participants