forked from NOAA-OWP/NextGen-Water-Prediction-Capability
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
26 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1 @@ | ||
from functools import lru_cache | ||
|
||
from src.rnr.app.consumer_manager import ConsumerManager | ||
|
||
|
||
@lru_cache | ||
def get_consumer_manager(): | ||
return ConsumerManager() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
"""Functions that require lru_cache""" | ||
from functools import lru_cache | ||
|
||
from src.rnr.app.consumer_manager import ConsumerManager | ||
|
||
|
||
@lru_cache | ||
def get_consumer_manager(): | ||
return ConsumerManager() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +0,0 @@ | ||
from functools import lru_cache | ||
|
||
from src.rnr.app.core.settings import Settings | ||
|
||
|
||
@lru_cache | ||
def get_settings() -> Settings: | ||
"""Instantiating the Settings object using LRU caching | ||
Returns | ||
------- | ||
Settings | ||
The Settings config object | ||
""" | ||
return Settings() | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
from functools import lru_cache | ||
|
||
from src.rnr.app.core.settings import Settings | ||
|
||
|
||
@lru_cache | ||
def get_settings() -> Settings: | ||
"""Instantiating the Settings object using LRU caching | ||
Returns | ||
------- | ||
Settings | ||
The Settings config object | ||
""" | ||
return Settings() |