Metadata-Version: 2.1
Name: bitsmiths-monitor
Version: 2.1.1
Summary: The Bitsmiths Monitor Package
Home-page: https://bitbucket.org/bitsmiths_za/bitsmiths
Author: Nicolas Milicevic, Steven van Niekerk, Darrly Daniels
Author-email: nicolas@bitsmiths.co.za, steven@bitsmiths.co.za, darryl@bitsmiths.co.za
License: MIT
Project-URL: Source, https://bitbucket.org/bitsmiths_za/bitsmiths
Keywords: libraries
Platform: unix
Platform: linux
Platform: osx
Platform: cygwin
Platform: win32
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: MacOS :: MacOS X
Classifier: Operating System :: POSIX
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Topic :: Software Development :: Libraries
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.7
Description-Content-Type: text/markdown
License-File: LICENCE
Requires-Dist: bitsmiths-mettle (>=2.1.4)
Requires-Dist: bitsmiths-lib (>=2.1.1)
Requires-Dist: sqlparse

# BITSMITHS MONITOR #

The monitor is a light weight orchestration package where a system requires batch jobs to be run on a recurring basis.  The monitor
uses a relational database to track which jobs are to be scheduled, running, and have completed.


The main features are:
- Create batch schedules on a minute, hour, day, week, month, or yearly cycle.
- Batch schedules can have dependencies on one another.
- Limit the amount of concurrent running jobs.
- Overload the main classes to customize the package for your needs.
- Supports ad-hoc running of batch jobs.
- Stores a full run history of all your batch jobs.


This product has a dependency on:

- Mettle (`bitsmiths-mettle`)
- Bitsmiths Library (`bitsmiths-lib`)


**Note** that we package the generated Mettle code in this package, which means that the Mettle version required in this module is important.

## Tables & Setup ##

*Monitor* is designed to use a relational database with a schema/namespace of `monitor` in your database. You will need to create this schema manually.
It requires several other relational database tables.

The package provides the SQL code to create these tables. There are two ways to access the table creation SQL.

1. You can run `bs-monitor -g postgresql` at the command line, this will print all the SQL to `stdout`.
2. You can import the bs_monitor module and get the SQL as shown below:

```python

import bs_monitor

print(bs_monitor.get_table_sql('postgresql'))

```

**Note!** Currently only *postgresql* SQL is added to the package. If you want us to support another database let
us know and we will put it into the development pipeline.


## Change History ##


### 2.1.1 ###

| Type | Description |
| ---- | ----------- |
| Bug  | Fixed a typo bug in the job-runner, where any job that had a parent would cause it to raise an exception. |
| Bug  | Fixed a bug where the monitor-cli spawn job command would add its arguments to the spawned job. |


### 2.1.0 ###

| Type | Description |
| ---- | ----------- |
| New  | The python equivalent of the monitor is finally released. |


