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

Better control over System.properties #23593

Open
dmatej opened this issue Sep 7, 2021 · 5 comments
Open

Better control over System.properties #23593

dmatej opened this issue Sep 7, 2021 · 5 comments

Comments

@dmatej
Copy link
Contributor

dmatej commented Sep 7, 2021

General issue

  • System.properties are accessed on many places in GlassFish code
  • The state is global, but we don't have consistent well defined management for it.
  • Server should set anything global immediately after startup and never touch it again.

Example: ServerEnvironmentImpl

  • it's postConstruct method is called when it is used for the first time - then it calls System.setProperty, so services using them before it are not affected.
  • it affects some automatic tests, see FIXME in UpgradeTest (will be pushed soon TODO add reference)

Example: SystemPropertyConstants and Constants and ...

  • I mean com.sun.enterprise.glassfish.bootstrap.Constants, because there is around 30 classes of same name on classpath
  • partially duplicated, can be simplified?
  • use fulltext search to find other
dmatej added a commit to dmatej/glassfish that referenced this issue Sep 9, 2021
- added FIXME for ServerEnvironment, see issue eclipse-ee4j#23593 on GitHub
@github-actions
Copy link

github-actions bot commented Sep 8, 2022

This issue has been marked as inactive and old and will be closed in 7 days if there is no further activity. If you want the issue to remain open please add a comment

@github-actions github-actions bot added the Stale label Sep 8, 2022
@dmatej dmatej removed the Stale label Sep 8, 2022
@github-actions
Copy link

github-actions bot commented Sep 9, 2023

This issue has been marked as inactive and old and will be closed in 7 days if there is no further activity. If you want the issue to remain open please add a comment

@github-actions github-actions bot added the Stale label Sep 9, 2023
@dmatej dmatej removed the Stale label Sep 11, 2023
Copy link

This issue has been marked as inactive and old and will be closed in 7 days if there is no further activity. If you want the issue to remain open please add a comment

@github-actions github-actions bot added the Stale label Sep 11, 2024
@avpinchuk avpinchuk removed the Stale label Sep 11, 2024
@OndroMih
Copy link
Contributor

OndroMih commented Sep 11, 2024

@dmatej, @avpinchuk , do you think that the issue with ServerEnvironmentImpl could be simply solved by adding the @RunLevel(value = InitRunLevel.VAL, mode=RunLevel.RUNLEVEL_MODE_NON_VALIDATING) annotation on the class to start it at the init run level?

@OndroMih
Copy link
Contributor

Or maybe even @RunLevel(RUNLEVEL_VAL_IMMEDIATE), which should start the service immediately?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants