queuerPy 0.14.0__tar.gz → 0.15.0__tar.gz
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.
- {queuerpy-0.14.0/queuerPy.egg-info → queuerpy-0.15.0}/PKG-INFO +1 -1
- {queuerpy-0.14.0 → queuerpy-0.15.0}/_version.py +1 -1
- {queuerpy-0.14.0 → queuerpy-0.15.0}/pyproject.toml +2 -2
- {queuerpy-0.14.0 → queuerpy-0.15.0}/queuer.py +10 -3
- {queuerpy-0.14.0 → queuerpy-0.15.0/queuerPy.egg-info}/PKG-INFO +1 -1
- {queuerpy-0.14.0 → queuerpy-0.15.0}/LICENSE +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/MANIFEST.in +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/README.md +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/__init__.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/core/__init__.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/core/broadcaster.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/core/listener.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/core/retryer.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/core/runner.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/core/scheduler.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/core/ticker.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/database/__init__.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/database/db_job.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/database/db_listener.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/database/db_master.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/database/db_worker.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/helper/__init__.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/helper/database.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/helper/error.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/helper/logging.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/helper/sql.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/helper/task.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/model/__init__.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/model/batch_job.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/model/connection.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/model/job.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/model/master.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/model/options.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/model/options_on_error.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/model/task.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/model/worker.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/py.typed +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/queuerPy.egg-info/SOURCES.txt +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/queuerPy.egg-info/dependency_links.txt +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/queuerPy.egg-info/requires.txt +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/queuerPy.egg-info/top_level.txt +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/queuer_global.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/queuer_job.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/queuer_listener.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/queuer_master.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/queuer_next_interval.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/queuer_task.py +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/setup.cfg +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/sql/job.sql +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/sql/master.sql +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/sql/notify.sql +0 -0
- {queuerpy-0.14.0 → queuerpy-0.15.0}/sql/worker.sql +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: queuerPy
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.15.0
|
|
4
4
|
Summary: A Python implementation of the queuer system - a job queuing and processing system with PostgreSQL backend
|
|
5
5
|
Author-email: Simon Herrmann <siherrmann@users.noreply.github.com>
|
|
6
6
|
Maintainer-email: Simon Herrmann <siherrmann@users.noreply.github.com>
|
|
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "queuerPy"
|
|
7
|
-
version = "0.
|
|
7
|
+
version = "0.15.0"
|
|
8
8
|
description = "A Python implementation of the queuer system - a job queuing and processing system with PostgreSQL backend"
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
license = "Apache-2.0"
|
|
@@ -92,7 +92,7 @@ pythonVersion = "3.8"
|
|
|
92
92
|
pythonPlatform = "All"
|
|
93
93
|
|
|
94
94
|
[tool.mypy]
|
|
95
|
-
python_version = "0.
|
|
95
|
+
python_version = "0.15.0"
|
|
96
96
|
warn_return_any = true
|
|
97
97
|
warn_unused_configs = true
|
|
98
98
|
disallow_untyped_defs = true
|
|
@@ -526,15 +526,22 @@ class Queuer(
|
|
|
526
526
|
def _heartbeat_func(self) -> None:
|
|
527
527
|
"""Send periodic heartbeats - only updates database, not queuer state."""
|
|
528
528
|
try:
|
|
529
|
-
# Get current worker
|
|
530
|
-
|
|
529
|
+
# Get current worker with mutex
|
|
530
|
+
with self.worker_mutex:
|
|
531
|
+
current_worker = self.worker
|
|
532
|
+
|
|
533
|
+
updated_worker: Optional[Worker] = None
|
|
531
534
|
if current_worker:
|
|
532
535
|
# Update timestamp and save to database
|
|
533
536
|
current_worker.updated_at = datetime.now()
|
|
534
|
-
self.db_worker.update_worker(current_worker)
|
|
537
|
+
updated_worker = self.db_worker.update_worker(current_worker)
|
|
535
538
|
logger.debug(
|
|
536
539
|
f"Updated worker heartbeat timestamp: {current_worker.updated_at}"
|
|
537
540
|
)
|
|
541
|
+
|
|
542
|
+
if updated_worker:
|
|
543
|
+
with self.worker_mutex:
|
|
544
|
+
self.worker = updated_worker
|
|
538
545
|
except Exception as e:
|
|
539
546
|
logger.error(f"Heartbeat error: {e}")
|
|
540
547
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: queuerPy
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.15.0
|
|
4
4
|
Summary: A Python implementation of the queuer system - a job queuing and processing system with PostgreSQL backend
|
|
5
5
|
Author-email: Simon Herrmann <siherrmann@users.noreply.github.com>
|
|
6
6
|
Maintainer-email: Simon Herrmann <siherrmann@users.noreply.github.com>
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|