Skip to content

feat(linq) add possibility to specify default value for start and stop parameter of range function #322

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Merged
merged 3 commits into from
May 9, 2022

Conversation

bednar
Copy link
Contributor

@bednar bednar commented May 9, 2022

Closes #320

Proposed Changes

Possibility to specify default value for start and stop parameter of range function:

var settings = new QueryableOptimizerSettings
{
    RangeStartValue = DateTime.UtcNow.AddHours(-24),
    RangeStopValue = DateTime.UtcNow.AddHours(1)
};
var query = from s in InfluxDBQueryable<Sensor>.Queryable("my-bucket", "my-org", queryApi, settings)
    select s;

Checklist

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

@bednar bednar requested a review from rhajek May 9, 2022 11:18
@bednar bednar marked this pull request as ready for review May 9, 2022 11:25
Co-authored-by: Robert Hajek <robert.hajek@gmail.com>
@bednar bednar requested a review from rhajek May 9, 2022 11:52
@bednar bednar merged commit 042c900 into master May 9, 2022
@bednar bednar deleted the linq_default_start_stop branch May 9, 2022 14:24
@bednar bednar added this to the 4.2.0 milestone May 9, 2022
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Linq: add option to include future timestamps when no time range is provided
2 participants