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

Remove TimeLogManager and make TimeLogger singleton #3494

Merged
merged 13 commits into from
Nov 29, 2024

Conversation

schnellerhase
Copy link
Contributor

Fixes #3480

@schnellerhase schnellerhase marked this pull request as ready for review November 2, 2024 19:06
@garth-wells
Copy link
Member

What's the advantage of a monostate design over a singleton? Looks to me to all intents and purposes to be the same thing.

@schnellerhase
Copy link
Contributor Author

I think in this case it results in the same. We can decide on the interface we prefer, rather calling some kind of an instance function in the singleton approach or the constructor as here with the monostate.

@schnellerhase
Copy link
Contributor Author

Shall we stick to the monostate or return to the singleton approach, just within TimeLogger now?

@jhale
Copy link
Member

jhale commented Nov 21, 2024

After reading the comments I would recommend singleton - as @garth-wells says there is little clear advantage, and singleton is at least well-known (and people understand the issues).

@schnellerhase schnellerhase changed the title Remove TimeLogManager and make TimeLogger monostate Remove TimeLogManager and make TimeLogger singleton Nov 23, 2024
@jhale jhale added this pull request to the merge queue Nov 29, 2024
Merged via the queue into FEniCS:main with commit 97a802f Nov 29, 2024
20 checks passed
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.

Timer improvements
3 participants