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

HealthCheckPublisherOptions.Period sets the value of .Delay #1041

Closed
guardrex opened this issue Jan 31, 2019 · 3 comments · Fixed by #1065
Closed

HealthCheckPublisherOptions.Period sets the value of .Delay #1041

guardrex opened this issue Jan 31, 2019 · 3 comments · Fixed by #1065

Comments

@guardrex
Copy link

guardrex commented Jan 31, 2019

HealthCheckPublisherOptions.Period sets the value of HealthCheckPublisherOptions.Delay ...

services.Configure<HealthCheckPublisherOptions>(options =>
{
    options.Period = TimeSpan.FromSeconds(2);
});

services.AddSingleton<IHealthCheckPublisher, TestPublisher>();

PublishAsync is called on default 30-second intervals ... not the 2 seconds specified. When this setting is made HealthCheckPublisherOptions.Delay receives the value assigned to Period.

https://github.com/aspnet/Extensions/blob/release/2.2/src/HealthChecks/HealthChecks/src/HealthCheckPublisherOptions.cs

@pranavkm
Copy link

pranavkm commented Feb 1, 2019

@glennc could you review this? You're probably more familiar with the code here than I am.

glennc added a commit that referenced this issue Feb 4, 2019
This seems wrong.

Presumably fixes: #1041
@guardrex guardrex changed the title HealthCheckPublisherOptions not honored HealthCheckPublisherOptions.Period sets the value of .Delay Feb 5, 2019
rynowak pushed a commit that referenced this issue Feb 13, 2019
This seems wrong.

Presumably fixes: #1041
@fugaku
Copy link

fugaku commented Mar 14, 2019

Is this available in aspnet.core 2.2 ?
If not, is there any workaround for this ?

@rynowak
Copy link
Member

rynowak commented Mar 27, 2019

I opened #1311 to consider patching this for 2.2.X

For now the only workaround is to use reflection and set the field yourself.

rynowak pushed a commit that referenced this issue Mar 27, 2019
This seems wrong.

Presumably fixes: #1041

(cherry picked from commit b3c88d7)
rynowak pushed a commit that referenced this issue Mar 28, 2019
This seems wrong.

Presumably fixes: #1041

(cherry picked from commit b3c88d7)
rynowak pushed a commit that referenced this issue Apr 11, 2019
This seems wrong.

Presumably fixes: #1041

(cherry picked from commit b3c88d7)
dougbu pushed a commit that referenced this issue Apr 11, 2019
* Update HealthCheckPublisherOptions.cs

This seems wrong.

Presumably fixes: #1041

(cherry picked from commit b3c88d7)

* Update patchconfig.props
@ghost ghost locked as resolved and limited conversation to collaborators Dec 2, 2019
JunTaoLuo pushed a commit to dotnet/aspnetcore that referenced this issue Feb 12, 2020
* Update HealthCheckPublisherOptions.cs

This seems wrong.

Presumably fixes: dotnet/extensions#1041

(cherry picked from commit dotnet/extensions@b3c88d7)

* Update patchconfig.props\n\nCommit migrated from dotnet/extensions@1301f31
JunTaoLuo pushed a commit to dotnet/aspnetcore that referenced this issue Feb 13, 2020
…t/extensions#1041 to 2.2 (dotnet/extensionsdotnet/extensionsdotnet/extensionsdotnet/extensions#1312)

* Update HealthCheckPublisherOptions.cs

This seems wrong.

Presumably fixes: dotnet/extensions#1041

(cherry picked from commit dotnet/extensions@dotnet/extensions@dotnet/extensions@dotnet/extensions@b3c88d7)

* Update patchconfig.props\n\nCommit migrated from https://github.com/dotnet/extensions/commit/dotnet/extensions@dotnet/extensions@dotnet/extensions@1301f31b91687ec8e9a34777c1b3095e53ee129f
\n\nCommit migrated from https://github.com/dotnet/extensions/commit/dotnet/extensions@dotnet/extensions@007a8dadf1bdacc1e1906fdad3cc7f16522582b1
\n\nCommit migrated from https://github.com/dotnet/extensions/commit/dotnet/extensions@9230a4120e794c686aabbef993f2334a943b71cd
\n\nCommit migrated from dotnet/extensions@8ed637a
JunTaoLuo pushed a commit to dotnet/aspnetcore that referenced this issue Feb 15, 2020
* Update HealthCheckPublisherOptions.cs

This seems wrong.

Presumably fixes: dotnet/extensions#1041

(cherry picked from commit dotnet/extensions@b3c88d7)

* Update patchconfig.props\n\nCommit migrated from dotnet/extensions@1301f31
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants