dataflow-core 2.1.11__py3-none-any.whl → 2.1.12__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.

Potentially problematic release.


This version of dataflow-core might be problematic. Click here for more details.

@@ -20,4 +20,6 @@ from .role_server import RoleServer
20
20
  from .variables import Variable
21
21
  from .recent_project_studio import RecentProjectStudio
22
22
  from .connection import Connection
23
- from .git_ssh import GitSSH
23
+ from .git_ssh import GitSSH
24
+ from .pod_activity import PodActivity
25
+ from .pod_session_history import PodSessionHistory
@@ -0,0 +1,16 @@
1
+ from sqlalchemy import Column, Integer, String, DateTime, ForeignKey
2
+ from dataflow.db import Base
3
+
4
+ class PodActivity(Base):
5
+ """Model for tracking active JupyterHub pod sessions"""
6
+ __tablename__ = 'POD_ACTIVITY'
7
+
8
+ id = Column(Integer, primary_key=True, autoincrement=True)
9
+ username = Column(String, ForeignKey('USER.user_name', ondelete="SET NULL"), nullable=True, index=True)
10
+ pod_name = Column(String, nullable=False, unique=True, index=True)
11
+ namespace = Column(String, nullable=False, index=True)
12
+ start_time = Column(DateTime(timezone=True))
13
+ stop_time = Column(DateTime(timezone=True))
14
+ status = Column(String, nullable=False, index=True)
15
+ instance_type = Column(String, index=True)
16
+ node_name = Column(String)
@@ -0,0 +1,16 @@
1
+ from sqlalchemy import Column, Integer, String, DateTime, Numeric, ForeignKey
2
+ from dataflow.db import Base
3
+
4
+ class PodSessionHistory(Base):
5
+ """Model for tracking completed JupyterHub user sessions"""
6
+ __tablename__ = 'POD_SESSION_HISTORY'
7
+
8
+ id = Column(Integer, primary_key=True, autoincrement=True)
9
+ username = Column(String, ForeignKey('USER.user_name', ondelete="SET NULL"), nullable=True, index=True)
10
+ pod_name = Column(String, nullable=False, index=True)
11
+ namespace = Column(String, nullable=False, index=True)
12
+ start_time = Column(DateTime(timezone=True))
13
+ stop_time = Column(DateTime(timezone=True), nullable=False)
14
+ session_duration_minutes = Column(Numeric(10, 2))
15
+ instance_type = Column(String, index=True)
16
+ node_name = Column(String)
dataflow/models/user.py CHANGED
@@ -24,6 +24,7 @@ class User(Base):
24
24
  active_env_type = Column(String, nullable=True)
25
25
  current_server = Column(String)
26
26
  show_server_page = Column(Boolean, default = True)
27
+ monthly_allocation = Column(Integer, nullable=True, default=0)
27
28
 
28
29
  role_details = relationship("Role")
29
30
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: dataflow-core
3
- Version: 2.1.11
3
+ Version: 2.1.12
4
4
  Summary: Dataflow core package
5
5
  Author: Dataflow
6
6
  Author-email:
@@ -8,7 +8,7 @@ dataflow/database_manager.py,sha256=tJHMuOZ9Muskrh9t4uLRlTuFU0VkHAzoHlGP5DORIC4,
8
8
  dataflow/dataflow.py,sha256=A66OFXgJCxW18Dk_BnasvR82LrPXQ2iB-QMTyYJJ1cc,13100
9
9
  dataflow/db.py,sha256=73ojGqpCTRVTlPszD73Ozhjih_BI2KTHmazqxxL6iWk,3780
10
10
  dataflow/environment.py,sha256=qiyuRRPpVLVWiYccRHXnGyWMr_ZBPWzixAyDtAzxQYE,28277
11
- dataflow/models/__init__.py,sha256=WnlLd-0T3HYtJloDms1a58lN66WzBIbBSTReDXD6HaQ,892
11
+ dataflow/models/__init__.py,sha256=5Ai-sUHtT1dtc0l4nL1fuwVbx0GcwaGQg_LXqOzWb4c,981
12
12
  dataflow/models/app_types.py,sha256=yE_ZB13lhpK7AZ7PyBwnQlf0RlIHYs_-vdMKx7_RMlY,379
13
13
  dataflow/models/blacklist_library.py,sha256=B2oi3Z8GcR_glhLAyinFk0W8c9txXvm3uOER6dY-q7I,991
14
14
  dataflow/models/connection.py,sha256=_VJL3KuIrm8t4lJmtunIL3-AXF9Yvi5wUolzdR3tE0E,1017
@@ -17,6 +17,8 @@ dataflow/models/environment.py,sha256=3W-Pvkuiufjw0MWy9F6uWSd0HDPjRNNJe3TnhpHxcG
17
17
  dataflow/models/environment_status.py,sha256=lvPDNUsUoTW9D97B07aKqJQHRKp4LvPM28pQDMPH1ac,536
18
18
  dataflow/models/git_ssh.py,sha256=W15SDypxzGOz_aZkHEnVZ6DIMVsjAsbSIXVIEt2mPYU,694
19
19
  dataflow/models/pinned_projects.py,sha256=I-XMQq7__XJJi2lyOdEvQEfhPRz8D6KHA6Cbavbf05o,606
20
+ dataflow/models/pod_activity.py,sha256=4NQplUtckS4d2Uc-Iyi8PfgciblHiExbXo_VTMaukB8,751
21
+ dataflow/models/pod_session_history.py,sha256=-O8DHtH1AtGLntJ1shI6eiciTJGL_vYvG3gfupvr0zY,778
20
22
  dataflow/models/project_details.py,sha256=iNb95L3UGjcC_Ws6FiUTDANCUFhYWpnsKraS6rmCyRU,1098
21
23
  dataflow/models/recent_project_studio.py,sha256=m12KGCsv453C1ijHjfVD8E7cJ7Og_0N8uc7_9VlfkYw,812
22
24
  dataflow/models/recent_projects.py,sha256=OFd5MSRXVRHs9UbvUNoJBBnh9rgsJ0lwE23wm5_Hc5w,321
@@ -26,7 +28,7 @@ dataflow/models/role_zone.py,sha256=uH8JheWyzUWcRECRzYuzdphUAUXeU5zRVA1Bhuz3h9w,
26
28
  dataflow/models/server_config.py,sha256=8ocKT8tPen9tedO8BLPEfkWxUEIHaqvA2L-qEhrFND0,1385
27
29
  dataflow/models/session.py,sha256=c8TI6qXsM8utzp5vSQtAOXJSbgasnyu-a0qSAvA-rWs,459
28
30
  dataflow/models/team.py,sha256=fjkqF0N4PSwSYTgHjEQl9wuC7yumd0iOb5nNFePI6q4,488
29
- dataflow/models/user.py,sha256=qFvkU6hZQzv-QWCC8nDKonnpl2Z2YEqMni5iUVQpMB0,1041
31
+ dataflow/models/user.py,sha256=-XEpulg7UAL-WDMyigPasDS61btna2mKtJPsanWA4lw,1108
30
32
  dataflow/models/user_environment.py,sha256=yI9NutULcLiwlycuEin6ROe6o1Sjdv_sgw2MEkJFeYg,568
31
33
  dataflow/models/user_team.py,sha256=r_fmKvf6JuGgiiI9TXWjVG2QZ3WOvDrOwYWVQ3r8oWo,659
32
34
  dataflow/models/variables.py,sha256=Sinvv3zFYni5i_GrL69cVfhCh4tOOaIHiEzWYRJ-i10,1132
@@ -48,8 +50,8 @@ dataflow/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
48
50
  dataflow/utils/exceptions.py,sha256=8GRFoYZ5dPGQckVm2znaHpPi0ZAs69fK-RGKukEsapk,4432
49
51
  dataflow/utils/get_current_user.py,sha256=4nSO3SPVMZhW-MsIgxR3f9ZzrFaIZIuyrM6hvfyE7PQ,1202
50
52
  dataflow/utils/logger.py,sha256=7BFrOq5Oiqn8P4XZbgJzMP5O07d2fpdECbbfsjrUuHw,1213
51
- dataflow_core-2.1.11.dist-info/METADATA,sha256=5ascZ5HFZFObYNT9mPFD1jrOrxoeFhUbyZX3kkjydzI,370
52
- dataflow_core-2.1.11.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
53
- dataflow_core-2.1.11.dist-info/entry_points.txt,sha256=ppj_EIbYrJJwCPg1kfdsZk5q1N-Ejfis1neYrnjhO8o,117
54
- dataflow_core-2.1.11.dist-info/top_level.txt,sha256=SZsUOpSCK9ntUy-3Tusxzf5A2e8ebwD8vouPb1dPt_8,23
55
- dataflow_core-2.1.11.dist-info/RECORD,,
53
+ dataflow_core-2.1.12.dist-info/METADATA,sha256=v2BbzlLVWO3_3VcaE6tkzGS1u0rN9dCI0FzPTf0qKXg,370
54
+ dataflow_core-2.1.12.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
55
+ dataflow_core-2.1.12.dist-info/entry_points.txt,sha256=ppj_EIbYrJJwCPg1kfdsZk5q1N-Ejfis1neYrnjhO8o,117
56
+ dataflow_core-2.1.12.dist-info/top_level.txt,sha256=SZsUOpSCK9ntUy-3Tusxzf5A2e8ebwD8vouPb1dPt_8,23
57
+ dataflow_core-2.1.12.dist-info/RECORD,,