Skip to main content

z4j-apscheduler

PyPI version Python License

The APScheduler adapter for z4j.

Surfaces APScheduler jobs on the dashboard's Schedules page, read, enable, disable, trigger, delete. Engine-agnostic: works alongside any z4j engine adapter, or as a standalone scheduler in projects without a queue engine.

Compatibility

  • APScheduler 3.10.2+ (no upper bound is declared; APScheduler 4 is a different API and the adapter refuses its scheduler by name, so install apscheduler<4 alongside it)
  • Python 3.11+

Full per-adapter matrix at https://docs.z4j.com/reference/compatibility/.

What it ships

Capability Notes
List schedules every job APScheduler currently tracks
Enable / disable via APScheduler's pause / resume
Trigger now sets the existing job's next_run_time to now; subsequent timing follows APScheduler's normal trigger semantics
Delete clean removal from the jobstore
Boot inventory full snapshot at agent connect; existing jobs show up without editing

Create and update are not yet supported: the adapter surfaces and controls the jobs you define in your own APScheduler setup, and the brain greys out create / update for this scheduler.

Supports every APScheduler jobstore: in-memory, SQLAlchemy (Postgres / SQLite / MySQL), MongoDB, Redis.

Install

pip install z4j-bare z4j-apscheduler
import os

from apscheduler.schedulers.background import BackgroundScheduler
from apscheduler.triggers.cron import CronTrigger
from z4j_bare import install_agent
from z4j_apscheduler import APSchedulerAdapter

scheduler = BackgroundScheduler()
scheduler.add_job(my_func, CronTrigger(minute="*/5"), id="cleanup")
scheduler.start()

install_agent(
    engines=[],  # APScheduler runs jobs in-process; no separate engine
    schedulers=[APSchedulerAdapter(scheduler=scheduler)],
    brain_url="https://brain.example.com",
    token="z4j_agent_...",
    project_id="my-project",
    hmac_secret=os.environ["Z4J_HMAC_SECRET"],
)

Reliability

  • Inventory and listener failures are isolated from APScheduler job code.
  • Operator controls call APScheduler's normal pause, resume, remove, and modify_job APIs and therefore mutate the configured jobstore. A control that exceeds its 10-second timeout is reported as indeterminate because its worker thread may still complete the mutation.

Documentation

Full docs at docs.z4j.com/schedulers/apscheduler/.

License

Apache-2.0, see LICENSE.

Metadata

Release files for z4j-apscheduler 1.12.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for z4j-apscheduler 1.12.1
File Size Uploaded
z4j_apscheduler-1.12.1.tar.gz 25.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for z4j-apscheduler 1.12.1
File Interpreter ABI Platform
z4j_apscheduler-1.12.1-py3-none-any.whl Python 3 none any Details

Total release size: 44.8 kB

Release files / z4j_apscheduler-1.12.1.tar.gz

Download URL z4j_apscheduler-1.12.1.tar.gz
Size 25.2 kB
Tags Source
SHA-256 checksum
How to use checksums
046f6d7f7b2ab57a1ef1c66d8b0213b8f7fb2684e16781f69e98af2174302847
BLAKE2b-256 checksum
How to use checksums
3b8f07a093b74f1998942e2dc56bbc6e02b9a9b3bac2dd30fe9b48c91a52cec0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release files / z4j_apscheduler-1.12.1-py3-none-any.whl

Download URL z4j_apscheduler-1.12.1-py3-none-any.whl
Size 19.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b0cfc8c75f5390bdf25f0310cd15e879ab6729ead5af9350fee41443971f4f99
BLAKE2b-256 checksum
How to use checksums
8f2964628147ef9f8928ff1a8cc37b67ab455af87e61af5916d64506b17c2088
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release history Release notifications | RSS feed

This release

1.12.1 This release

2 release files

1.11.0

2 release files

1.10.0

2 release files

1.9.1

2 release files

1.9.0

2 release files

1.8.0

2 release files

1.7.0

2 release files

1.6.7

2 release files

1.6.0

2 release files

1.5.0

2 release files

1.4.0

2 release files

1.3.0

2 release files

1.0.1

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page