Skip to content

feat: allow to use DateTimeKind.Local and DateTimeKind.Local as a timestamp for data point #442

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

Merged
merged 4 commits into from
Dec 16, 2022

Conversation

bednar
Copy link
Contributor

@bednar bednar commented Dec 16, 2022

Closes #441

Proposed Changes

This PR allows to use new DateTime(2015, 10, 15, 8, 20, 15, DateTimeKind.Local); or new DateTime(2015, 10, 15, 8, 20, 15, DateTimeKind.Unspecified) as a timestamp for PointData:

var dateTime = new DateTime(2015, 10, 15, 8, 20, 15, DateTimeKind.Unspecified);

var point = PointData.Measurement("h2o")
    .Tag("location", "europe")
    .Field("level", 2)
    .Timestamp(new DateTime(2015, 10, 15, 8, 20, 15, DateTimeKind.Unspecified), WritePrecision.Ms);

Checklist

  • CHANGELOG.md updated
  • Rebased/mergeable
  • A test has been added if appropriate
  • dotnet test completes successfully
  • Commit messages are conventional
  • Sign CLA (if not already signed)

@bednar bednar marked this pull request as ready for review December 16, 2022 09:20
@bednar bednar requested a review from powersj December 16, 2022 09:20
@bednar bednar merged commit fdc9ddc into master Dec 16, 2022
@bednar bednar deleted the datetime-local branch December 16, 2022 14:46
@bednar bednar added this to the 4.10.0 milestone Dec 16, 2022
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.

Allow "DateTimeKind.Local" as TimeStamp
2 participants
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy