architectonics 0.0.47__py3-none-any.whl → 0.0.48__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -13,6 +13,7 @@ class BaseApplicationFactory:
13
13
  debug=application_settings.DEBUG,
14
14
  title=title,
15
15
  docs_url="/docs/",
16
+ lifespan=BaseApplicationFactory.lifespan,
16
17
  )
17
18
 
18
19
  app.add_middleware(
@@ -30,3 +31,12 @@ class BaseApplicationFactory:
30
31
  @classmethod
31
32
  def _register_app_routes(cls, app: FastAPI):
32
33
  raise NotImplementedError()
34
+
35
+ @staticmethod
36
+ @asynccontextmanager
37
+ async def lifespan(app: FastAPI):
38
+ # Load the ML model
39
+ print("Loading ML models...")
40
+ yield
41
+ # Clean up the ML models and release the resources
42
+ print("Shutting down ML models...")
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: architectonics
3
- Version: 0.0.47
3
+ Version: 0.0.48
4
4
  Summary:
5
5
  Author: Your Name
6
6
  Author-email: you@example.com
@@ -15,7 +15,7 @@ architectonics/core/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSu
15
15
  architectonics/core/config/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
16
16
  architectonics/core/config/application_settings.py,sha256=DmCjQCbm4BsxMoZuQ212Pjjl_3spQ2vK5TUyZdDcklM,239
17
17
  architectonics/core/factory/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
18
- architectonics/core/factory/factory.py,sha256=GPv3AKWfsmeu5Qo1sX0gZ9lyu6A0_pZfqD_AZg73xV8,792
18
+ architectonics/core/factory/factory.py,sha256=QjCbDJSIiooWJCVX0g3RZxnFu9wR7sBsqqOc3xZsRU8,1111
19
19
  architectonics/core/models/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
20
20
  architectonics/core/models/base_model.py,sha256=-dT4UqQCSW41Ip6Cb41Bkudh45Co71EsReYOdwF4BMs,663
21
21
  architectonics/core/models/deleted_models.py,sha256=9hqdZgCC2JhAriA_GA7P2uA32rk5UAEXvGA3u8HVIME,151
@@ -39,6 +39,6 @@ architectonics/rabbit_mq/config/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm
39
39
  architectonics/rabbit_mq/config/rabbit_mq_settings.py,sha256=fLPeHeqC6dEQ-eTj1GZ4_ulIATdMxqZXdxdbszCgNZA,404
40
40
  architectonics/rabbit_mq/consumer/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
41
41
  architectonics/rabbit_mq/consumer/base_consumer.py,sha256=A61l6g6B6y_dXLiqGNaA87Nx9Xve_edCZ5WP88ivy9A,1699
42
- architectonics-0.0.47.dist-info/WHEEL,sha256=y3eDiaFVSNTPbgzfNn0nYn5tEn1cX6WrdetDlQM4xWw,83
43
- architectonics-0.0.47.dist-info/METADATA,sha256=a5fyU7uYsp5WQCOOYLuq7u69Q7ah7LHOD0vkj9ZzQWg,469
44
- architectonics-0.0.47.dist-info/RECORD,,
42
+ architectonics-0.0.48.dist-info/WHEEL,sha256=y3eDiaFVSNTPbgzfNn0nYn5tEn1cX6WrdetDlQM4xWw,83
43
+ architectonics-0.0.48.dist-info/METADATA,sha256=IjHD_yvnbvxsNaiWaOBQjf3hkkqGNAZwUznNVkWIEbs,469
44
+ architectonics-0.0.48.dist-info/RECORD,,