amqp-client-python 0.2.0__tar.gz → 0.2.1.dev1__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.
Files changed (129) hide show
  1. amqp_client_python-0.2.1.dev1/.env.example +22 -0
  2. amqp_client_python-0.2.1.dev1/.flake8 +6 -0
  3. amqp_client_python-0.2.1.dev1/.github/workflows/lint.yml +33 -0
  4. amqp_client_python-0.2.1.dev1/.github/workflows/publish.yml +24 -0
  5. amqp_client_python-0.2.1.dev1/.github/workflows/test.yml +64 -0
  6. amqp_client_python-0.2.1.dev1/.github/workflows/type.yml +19 -0
  7. amqp_client_python-0.2.1.dev1/.gitignore +7 -0
  8. amqp_client_python-0.2.1.dev1/.pre-commit-config.yaml +20 -0
  9. amqp_client_python-0.2.1.dev1/.readthedocs.yaml +33 -0
  10. amqp_client_python-0.2.1.dev1/.vscode/settings.json +6 -0
  11. amqp_client_python-0.2.1.dev1/CODE_OF_CONDUCT.md +22 -0
  12. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/PKG-INFO +40 -14
  13. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/README.md +25 -1
  14. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/__init__.py +11 -0
  15. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/domain/models/__init__.py +6 -0
  16. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/domain/models/config.py +5 -12
  17. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/domain/models/options.py +1 -5
  18. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/domain/models/ssl_options.py +1 -6
  19. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/domain/utils/__init__.py +5 -0
  20. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/event/__init__.py +9 -0
  21. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/exceptions/__init__.py +12 -0
  22. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/rabbitmq/__init__.py +15 -1
  23. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/rabbitmq/async_channel.py +58 -27
  24. amqp_client_python-0.2.1.dev1/amqp_client_python/rabbitmq/async_connection.py +506 -0
  25. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/rabbitmq/async_eventbus_rabbitmq.py +67 -43
  26. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/rabbitmq/channel_rabbitmq.py +26 -14
  27. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/rabbitmq/connection_rabbitmq.py +5 -5
  28. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/rabbitmq/eventbus_rabbitmq.py +4 -4
  29. amqp_client_python-0.2.1.dev1/create-self-signed-certs.sh +173 -0
  30. amqp_client_python-0.2.1.dev1/dev_requirements.txt +63 -0
  31. amqp_client_python-0.2.1.dev1/docker-compose.yml +24 -0
  32. amqp_client_python-0.2.1.dev1/docs/API/domain/config.md +1 -0
  33. amqp_client_python-0.2.1.dev1/docs/API/domain/options.md +1 -0
  34. amqp_client_python-0.2.1.dev1/docs/API/domain/ssl_options.md +1 -0
  35. amqp_client_python-0.2.1.dev1/docs/API/rabbitmq/async_eventbus.md +1 -0
  36. amqp_client_python-0.2.1.dev1/docs/contribute.md +40 -0
  37. amqp_client_python-0.2.1.dev1/docs/index.md +26 -0
  38. amqp_client_python-0.2.1.dev1/docs/stylesheets/extra.css +35 -0
  39. amqp_client_python-0.2.1.dev1/docs/templates/cards.html +20 -0
  40. amqp_client_python-0.2.1.dev1/docs/templates/installation.md +9 -0
  41. amqp_client_python-0.2.1.dev1/docs/templates/sponsors.md +5 -0
  42. amqp_client_python-0.2.1.dev1/docs/templates/user_guide.md +8 -0
  43. amqp_client_python-0.2.1.dev1/docs/tutorial.md +72 -0
  44. amqp_client_python-0.2.1.dev1/examples/__init__.py +0 -0
  45. amqp_client_python-0.2.1.dev1/examples/async_case.py +67 -0
  46. amqp_client_python-0.2.1.dev1/examples/default.py +8 -0
  47. amqp_client_python-0.2.1.dev1/examples/multprocess.py +73 -0
  48. amqp_client_python-0.2.1.dev1/examples/publish.py +10 -0
  49. amqp_client_python-0.2.1.dev1/examples/rpc_publish.py +15 -0
  50. amqp_client_python-0.2.1.dev1/examples/rpc_subscribe.py +17 -0
  51. amqp_client_python-0.2.1.dev1/examples/sanic_test.py +36 -0
  52. amqp_client_python-0.2.1.dev1/examples/ssl_connection.py +28 -0
  53. amqp_client_python-0.2.1.dev1/examples/subscribe.py +15 -0
  54. amqp_client_python-0.2.1.dev1/examples/sync_case.py +52 -0
  55. amqp_client_python-0.2.1.dev1/examples/sync_wrapper_case.py +50 -0
  56. amqp_client_python-0.2.1.dev1/examples/thread.py +59 -0
  57. amqp_client_python-0.2.1.dev1/external_config/rabbitmq/rabbitmq.conf +1003 -0
  58. amqp_client_python-0.2.1.dev1/mkdocs.yml +34 -0
  59. amqp_client_python-0.2.1.dev1/mypy.ini +2 -0
  60. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/pyproject.toml +42 -39
  61. amqp_client_python-0.2.1.dev1/tests/__init__.py +0 -0
  62. amqp_client_python-0.2.1.dev1/tests/integration/__init__.py +0 -0
  63. amqp_client_python-0.2.1.dev1/tests/integration/async_eventbus/__init__.py +0 -0
  64. amqp_client_python-0.2.1.dev1/tests/integration/async_eventbus/auto_recovery_test.py +167 -0
  65. amqp_client_python-0.2.1.dev1/tests/integration/async_eventbus/conftest.py +31 -0
  66. amqp_client_python-0.2.1.dev1/tests/integration/async_eventbus/rpc_provider_test.py +54 -0
  67. amqp_client_python-0.2.1.dev1/tests/integration/async_eventbus/signals_test.py +62 -0
  68. amqp_client_python-0.2.1.dev1/tests/integration/async_eventbus/ssl_test.py +23 -0
  69. amqp_client_python-0.2.1.dev1/tests/integration/async_eventbus/subscribe_test.py +26 -0
  70. amqp_client_python-0.2.1.dev1/tests/integration/async_eventbus_wrapper/__init__.py +0 -0
  71. amqp_client_python-0.2.1.dev1/tests/integration/async_eventbus_wrapper/conftest.py +32 -0
  72. amqp_client_python-0.2.1.dev1/tests/integration/async_eventbus_wrapper/rpc_provider_test.py +21 -0
  73. amqp_client_python-0.2.1.dev1/tests/integration/async_eventbus_wrapper/signals_test.py +65 -0
  74. amqp_client_python-0.2.1.dev1/tests/integration/async_eventbus_wrapper/ssl_test.py +23 -0
  75. amqp_client_python-0.2.1.dev1/tests/integration/async_eventbus_wrapper/subscribe_test.py +22 -0
  76. amqp_client_python-0.2.1.dev1/tests/integration/eventbus/__init__.py +0 -0
  77. amqp_client_python-0.2.1.dev1/tests/integration/eventbus/conftest.py +12 -0
  78. amqp_client_python-0.2.1.dev1/tests/integration/eventbus/publish_test.py +0 -0
  79. amqp_client_python-0.2.1.dev1/tests/integration/eventbus/rpc_publish_test.py +0 -0
  80. amqp_client_python-0.2.1.dev1/tests/integration/eventbus/rpc_subscribe_test.py +0 -0
  81. amqp_client_python-0.2.1.dev1/tests/integration/eventbus/subscribe_test.py +0 -0
  82. amqp_client_python-0.2.1.dev1/tests/unit/__init__.py +0 -0
  83. amqp_client_python-0.2.1.dev1/tests/unit/channels/test_async_channel.py +122 -0
  84. amqp_client_python-0.2.1.dev1/tests/unit/channels/test_async_rpc_client.py +134 -0
  85. amqp_client_python-0.2.1.dev1/tests/unit/channels/test_channel_factory.py +21 -0
  86. amqp_client_python-0.2.1.dev1/tests/unit/channels/test_publish.py +73 -0
  87. amqp_client_python-0.2.1.dev1/tests/unit/channels/test_rpc_subscribe.py +76 -0
  88. amqp_client_python-0.2.1.dev1/tests/unit/channels/test_subscribe.py +30 -0
  89. amqp_client_python-0.2.1.dev1/tests/unit/config/test_uri.py +37 -0
  90. amqp_client_python-0.2.1.dev1/tests/unit/conftest.py +39 -0
  91. amqp_client_python-0.2.1.dev1/tests/unit/eventbus/default.py +2 -0
  92. amqp_client_python-0.2.1.dev1/tests/unit/eventbus/test_async_eventbus.py +31 -0
  93. amqp_client_python-0.2.1.dev1/tests/unit/eventbus/test_async_eventbus_provide_resource.py +57 -0
  94. amqp_client_python-0.2.1.dev1/tests/unit/eventbus/test_async_eventbus_publish.py +78 -0
  95. amqp_client_python-0.2.1.dev1/tests/unit/eventbus/test_async_eventbus_rpc_client.py +62 -0
  96. amqp_client_python-0.2.1.dev1/tests/unit/eventbus/test_async_eventbus_subscribe.py +38 -0
  97. amqp_client_python-0.2.1.dev1/tests/unit/eventbus/test_auto_recovery.py +64 -0
  98. amqp_client_python-0.2.1.dev1/tests/unit/utils/ca.pem +20 -0
  99. amqp_client_python-0.2.1.dev1/tests/unit/utils/rabbitmq_cert.pem +19 -0
  100. amqp_client_python-0.2.1.dev1/tests/unit/utils/rabbitmq_key.pem +27 -0
  101. amqp_client_python-0.2.1.dev1/uv.lock +1624 -0
  102. amqp_client_python-0.2.0/amqp_client_python/rabbitmq/async_connection.py +0 -260
  103. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/LICENSE +0 -0
  104. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/domain/utils/connection_type.py +0 -0
  105. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/domain/utils/types.py +0 -0
  106. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/event/async_provider_handler.py +0 -0
  107. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/event/async_subscriber_handler.py +0 -0
  108. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/event/event.py +0 -0
  109. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/event/integration_event.py +0 -0
  110. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/event/integration_event_handler.py +0 -0
  111. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/event/provider_handler.py +0 -0
  112. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/event/subscriber_handler.py +0 -0
  113. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/exceptions/auto_reconnect_exception.py +0 -0
  114. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/exceptions/blocking_exception.py +0 -0
  115. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/exceptions/eventbus_exception.py +0 -0
  116. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/exceptions/nack_exception.py +0 -0
  117. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/exceptions/publish_timeout_exception.py +0 -0
  118. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/exceptions/response_timeout_exception.py +0 -0
  119. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/exceptions/rpc_provider_exception.py +0 -0
  120. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/exceptions/thread_unsafe_exception.py +0 -0
  121. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/exceptions/timeout_exception.py +0 -0
  122. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/py.typed +0 -0
  123. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/rabbitmq/async_channel_factory.py +0 -0
  124. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/rabbitmq/async_connection_factory.py +0 -0
  125. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/rabbitmq/channel_factory_rabbitmq.py +0 -0
  126. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/rabbitmq/connection_factory_rabbitmq.py +0 -0
  127. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/rabbitmq/eventbus_wrapper_rabbitmq.py +0 -0
  128. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/rabbitmq/ioloop_factory.py +0 -0
  129. {amqp_client_python-0.2.0 → amqp_client_python-0.2.1.dev1}/amqp_client_python/signals.py +0 -0
@@ -0,0 +1,22 @@
1
+ RABBITMQ_SSL=FALSE
2
+
3
+ # RABBITMQ_CERT_PATH: RabbitMQ Certificate
4
+ # default value: .certs/analytics/cert.pem
5
+ #
6
+ # To generate self-signed certificates,
7
+ # use the ./create-self-signed-certs.sh script.
8
+ RABBITMQ_CERT_PATH=.certs/analytics/rabbitmq_cert.pem
9
+
10
+ # RABBITMQ_KEY_PATH: RabbitMQ Key
11
+ # default value: .certs/analytics/key.pem
12
+ #
13
+ # To generate self-signed certificates,
14
+ # use the ./create-self-signed-certs.sh script.
15
+ RABBITMQ_KEY_PATH=.certs/analytics/rabbitmq_key.pem
16
+
17
+ # RABBITMQ_CA_PATH: RabbitMQ Certificate of the Authentication entity (CA)
18
+ # default value: .certs/analytics/ca.pem
19
+ #
20
+ # To generate self-signed certificates,
21
+ # use the ./create-self-signed-certs.sh script.
22
+ RABBITMQ_CA_PATH=.certs/analytics/ca.pem
@@ -0,0 +1,6 @@
1
+ [flake8]
2
+ ignore = E722, W503, E402
3
+ max-line-length = 120
4
+ per-file-ignores =
5
+ conftest.py
6
+ __init__.py: F401
@@ -0,0 +1,33 @@
1
+ # This workflow will install Python dependencies, run tests and lint with a single version of Python
2
+ # For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
3
+
4
+ name: Lint
5
+
6
+ on:
7
+ push:
8
+ branches: [ "master", "develop" ]
9
+ pull_request:
10
+ branches: [ "master", "develop" ]
11
+
12
+ permissions:
13
+ contents: read
14
+
15
+ jobs:
16
+ build:
17
+
18
+ runs-on: ubuntu-latest
19
+
20
+ steps:
21
+ - uses: actions/checkout@v3
22
+ - name: Set up Python 3.8
23
+ uses: actions/setup-python@v3
24
+ with:
25
+ python-version: "3.8"
26
+ - name: Install dependencies
27
+ run: |
28
+ python -m pip install --upgrade pip
29
+ pip install flake8
30
+ - name: Lint with flake8
31
+ run: |
32
+ # stop the build if there are Python syntax errors or undefined names
33
+ flake8 amqp_client_python/ --ignore=E722,W503,E402 --count --max-line-length=127 --statistics
@@ -0,0 +1,24 @@
1
+ name: Publish to PyPI
2
+
3
+ on:
4
+ release:
5
+ types: [created]
6
+
7
+ jobs:
8
+ deploy:
9
+ runs-on: ubuntu-latest
10
+ steps:
11
+ - uses: actions/checkout@v3
12
+ - name: Set up Python
13
+ uses: actions/setup-python@v4
14
+ with:
15
+ python-version: '3.x'
16
+ - name: Install Poetry
17
+ uses: snok/install-poetry@v1
18
+ - name: Build and publish
19
+ env:
20
+ PYPI_TOKEN: ${{ secrets.PYPI_TOKEN }}
21
+ run: |
22
+ poetry config pypi-token.pypi $PYPI_TOKEN
23
+ poetry build
24
+ poetry publish
@@ -0,0 +1,64 @@
1
+ # This workflow will install Python dependencies, run tests and lint with a single version of Python
2
+ # For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
3
+
4
+ name: Tests
5
+
6
+ on:
7
+ push:
8
+ branches: [ "master", "develop" ]
9
+ pull_request:
10
+ branches: [ "master", "develop" ]
11
+
12
+ permissions:
13
+ contents: read
14
+
15
+ jobs:
16
+ build:
17
+ runs-on: ubuntu-latest
18
+
19
+ steps:
20
+ - name: Checkout repository
21
+ uses: actions/checkout@v3
22
+ - name: Generate self-signed certificates
23
+ run: |
24
+ # Make the script executable and run it
25
+ chmod +x ./create-self-signed-certs.sh
26
+ ./create-self-signed-certs.sh
27
+
28
+ - name: Start RabbitMQ container manually
29
+ run: |
30
+ # We start the container manually as a step to ensure that the certificate
31
+ # and config files exist on the host before we try to mount them.
32
+ docker run -d --name rabbitmq \
33
+ -p 5672:5672 \
34
+ -p 5671:5671 \
35
+ -v ${{ github.workspace }}/.certs/rabbitmq:/etc/ssl:ro \
36
+ -v ${{ github.workspace }}/external_config/rabbitmq/rabbitmq.conf:/etc/rabbitmq/rabbitmq.conf:ro \
37
+ -e RABBITMQ_DEFAULT_USER=guest \
38
+ -e RABBITMQ_DEFAULT_PASS=guest \
39
+ rabbitmq:3-management-alpine
40
+ - name: Wait for RabbitMQ to start
41
+ run: |
42
+ echo "Waiting for RabbitMQ to initialize..."
43
+ # Give the container time to start up and apply the configuration.
44
+ sleep 8
45
+ - name: Set up Python 3.8
46
+ uses: actions/setup-python@v3
47
+ with:
48
+ python-version: "3.8"
49
+ - name: Install dependencies
50
+ run: |
51
+ python -m pip install --upgrade pip
52
+ pip install pytest pika coverage
53
+ if [ -f dev_requirements.txt ]; then pip install -r dev_requirements.txt; fi
54
+ - name: Run unit tests with coverage
55
+ run: |
56
+ coverage run --source=amqp_client_python -m pytest -v tests/unit/
57
+ - name: Run integration tests with coverage
58
+ run: |
59
+ coverage run --append --source=amqp_client_python -m pytest -v tests/integration/
60
+ env:
61
+ AMQP_DOMAIN: localhost
62
+ - name: Generate and show combined coverage report
63
+ run: |
64
+ coverage report --show-missing
@@ -0,0 +1,19 @@
1
+ name: Python Type Checking
2
+
3
+ on: [push, pull_request]
4
+
5
+ jobs:
6
+ mypy:
7
+ runs-on: ubuntu-latest
8
+ steps:
9
+ - uses: actions/checkout@v2
10
+ - name: Set up Python
11
+ uses: actions/setup-python@v2
12
+ with:
13
+ python-version: '3.x'
14
+ - name: Install dependencies
15
+ run: |
16
+ python -m pip install --upgrade pip
17
+ pip install mypy
18
+ - name: Run mypy
19
+ run: mypy amqp_client_python/
@@ -0,0 +1,7 @@
1
+ __pycache__/
2
+ node_modules/
3
+ dist/*
4
+ .certs/
5
+ .config/
6
+ *_env/
7
+ site/
@@ -0,0 +1,20 @@
1
+ repos:
2
+ - repo: https://github.com/ambv/black
3
+ rev: 23.1.0
4
+ hooks:
5
+ - id: black
6
+ language_version: python3.8
7
+ stages: [commit]
8
+ - repo: https://github.com/PyCQA/flake8
9
+ rev: 6.0.0
10
+ hooks:
11
+ - id: flake8
12
+ stages: [commit]
13
+ - repo: local
14
+ hooks:
15
+ - id: requirements
16
+ name: requirements
17
+ entry: bash -c 'dev_env/bin/pip3 freeze > dev_requirements.txt; git add dev_requirements.txt'
18
+ language: system
19
+ pass_filenames: false
20
+ stages: [commit]
@@ -0,0 +1,33 @@
1
+ version: 2
2
+
3
+ # Set the OS, Python version and other tools you might need
4
+ build:
5
+ os: ubuntu-22.04
6
+ tools:
7
+ python: "3.8"
8
+ jobs:
9
+ post_create_environment:
10
+ - pip install poetry
11
+ - poetry config virtualenvs.create false
12
+ post_install:
13
+ - pip install --only doc
14
+ # You can also specify other tool versions:
15
+ # nodejs: "19"
16
+ # rust: "1.64"
17
+ # golang: "1.19"
18
+
19
+ # Build documentation in the "docs/" directory with Sphinx
20
+ mkdocs:
21
+ configuration: mkdocs.yml
22
+
23
+ # Optionally build your docs in additional formats such as PDF and ePub
24
+ # formats:
25
+ # - pdf
26
+ # - epub
27
+
28
+ # Optional but recommended, declare the Python requirements required
29
+ # to build your documentation
30
+ # See https://docs.readthedocs.io/en/stable/guides/reproducible-builds.html
31
+ # python:
32
+ # install:
33
+ # - requirements: docs/requirements.txt
@@ -0,0 +1,6 @@
1
+ {
2
+ "[python]": {
3
+ "editor.defaultFormatter": "ms-python.autopep8"
4
+ },
5
+ "python.formatting.provider": "none"
6
+ }
@@ -0,0 +1,22 @@
1
+ # Contributor Code of Conduct
2
+
3
+ As contributors and maintainers of this project, and in the interest of fostering an open and welcoming community, we pledge to respect all people who contribute through reporting issues, posting feature requests, updating documentation, submitting pull requests or patches, and other activities.
4
+
5
+ We are committed to making participation in this project a harassment-free experience for everyone, regardless of level of experience, gender identity, sexual orientation, disability, personal appearance, race, ethnicity, age, religion, or nationality.
6
+
7
+ Examples of unacceptable behavior include:
8
+
9
+ * The use of sexualized language or imagery
10
+ * Personal attacks
11
+ * Trolling or insulting/derogatory comments
12
+ * Public or private harassment
13
+ * Publishing others' private information, such as physical or electronic addresses, without explicit permission
14
+ * Other unethical or unprofessional conduct
15
+
16
+ ## Enforcement
17
+
18
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team at our [discord channel](https://discord.gg/RkXNeZpNZk). All complaints will be reviewed and investigated and will result in a response that is deemed necessary and appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident.
19
+
20
+ ## Attribution
21
+
22
+ This Code of Conduct is adapted from the Contributor Covenant, version 2.1, available at https://www.contributor-covenant.org/version/2/1/code_of_conduct.html
@@ -1,38 +1,40 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.4
2
2
  Name: amqp-client-python
3
- Version: 0.2.0
3
+ Version: 0.2.1.dev1
4
4
  Summary: Python AMQP Client Library
5
- Home-page: https://github.com/nutes-uepb/amqp-client-python
5
+ Project-URL: Homepage, https://github.com/nutes-uepb/amqp-client-python
6
+ Project-URL: Repository, https://github.com/nutes-uepb/amqp-client-python
7
+ Project-URL: Bug Tracker, https://github.com/nutes-uepb/amqp-client-python/issues
8
+ Project-URL: Source, https://github.com/nutes-uepb/amqp-client-python
9
+ Author-email: NUTES UEPB <dev.seniorsaudemovel@gmail.com>
10
+ Maintainer-email: "João Pedro Miranda C. Hluchan" <berrytern@gmail.com>
6
11
  License: Apache-2.0
7
- Keywords: packaging,dependency,amqp-client-python
8
- Author: NUTES UEPB
9
- Author-email: dev.seniorsaudemovel@gmail.com
10
- Requires-Python: >=3.7,<4.0
12
+ License-File: LICENSE
13
+ Keywords: amqp-client-python,dependency,packaging
11
14
  Classifier: Development Status :: 5 - Production/Stable
12
15
  Classifier: Intended Audience :: Developers
13
16
  Classifier: License :: OSI Approved :: Apache Software License
14
17
  Classifier: Natural Language :: English
15
18
  Classifier: Operating System :: OS Independent
16
19
  Classifier: Programming Language :: Python :: 3
17
- Classifier: Programming Language :: Python :: 3.7
18
- Classifier: Programming Language :: Python :: 3.8
19
20
  Classifier: Programming Language :: Python :: 3.9
20
21
  Classifier: Programming Language :: Python :: 3.10
21
22
  Classifier: Programming Language :: Python :: 3.11
22
23
  Classifier: Programming Language :: Python :: 3.12
24
+ Classifier: Programming Language :: Python :: 3.13
25
+ Classifier: Programming Language :: Python :: 3.14
23
26
  Classifier: Topic :: Communications
24
27
  Classifier: Topic :: Internet
25
28
  Classifier: Topic :: Software Development :: Libraries
26
29
  Classifier: Topic :: Software Development :: Libraries :: Python Modules
27
30
  Classifier: Topic :: System :: Networking
28
- Requires-Dist: pika (>=1.3.0,<2.0.0)
29
- Project-URL: Bug Tracker, https://github.com/nutes-uepb/amqp-client-python/issues
30
- Project-URL: Repository, https://github.com/nutes-uepb/amqp-client-python
31
+ Requires-Python: <4.0,>=3.9
32
+ Requires-Dist: pika<2.0.0,>=1.3.0
31
33
  Description-Content-Type: text/markdown
32
34
 
33
35
  # AMQP Client Python
34
36
 
35
- Client with high level of abstraction for manipulation of messages in the event bus RabbitMQ.
37
+ A Python client providing a high-level abstraction for interacting with RabbitMQ, simplifying message publishing, subscribing, and RPC patterns.
36
38
 
37
39
  --------
38
40
 
@@ -53,6 +55,18 @@ Client with high level of abstraction for manipulation of messages in the event
53
55
 
54
56
  **Source Code**: <a href="https://github.com/nutes-uepb/amqp-client-python" target="_blank">https://github.com/nutes-uepb/amqp-client-python</a>
55
57
 
58
+ **Discord Server**: <a href="https://discord.gg/RkXNeZpNZk" target="_blank">https://discord.gg/RkXNeZpNZk</a>
59
+
60
+ ### 🦀 Looking for higher performance? Try `amqp-rs`!
61
+ If you need higher throughput, thread safety, and built-in compression, check out [**amqp-rs**](https://pypi.org/project/amqp-rs/).
62
+
63
+ It is a high-performance Python extension developed in Rust using PyO3 and `tokio`. It shares a similar API and design philosophy with this library, but adds native thread safety, `zstd`/`zlib`/`lz4` compression, robust TLS/SSL support, and graceful shutdowns.
64
+
65
+ You can install it via `pip` or `uv`:
66
+ ```bash
67
+ pip install amqp-rs
68
+ ```
69
+
56
70
  ---
57
71
  ### Features:
58
72
  - Automatic creation and management of queues, exchanges and channels;
@@ -69,6 +83,18 @@ Client with high level of abstraction for manipulation of messages in the event
69
83
  | 0.2.0 | 0.2.0 |
70
84
  | 0.1.14 | ~0.1.12 |
71
85
 
86
+ ### Installation
87
+
88
+ You can install `amqp-client-python` using pip:
89
+ ```bash
90
+ pip install amqp-client-python
91
+ ```
92
+
93
+ ### Prerequisites
94
+
95
+ * Python 3.7+
96
+ * A running RabbitMQ instance.
97
+
72
98
  ### Examples:
73
99
  #### you can use [sync](https://github.com/nutes-uepb/amqp-client-python/blob/develop/amqp_client_python/rabbitmq/eventbus_rabbitmq.py) , [async eventbus](https://github.com/nutes-uepb/amqp-client-python/blob/develop/amqp_client_python/rabbitmq/async_eventbus_rabbitmq.py) and [sync wrapper](https://github.com/nutes-uepb/amqp-client-python/blob/develop/amqp_client_python/rabbitmq/eventbus_wrapper_rabbitmq.py) of async eventbus
74
100
  <details><summary>async usage </summary>
@@ -229,4 +255,4 @@ When using [**EventbusRabbitMQ**](https://github.com/nutes-uepb/amqp-client-pyth
229
255
  [known-vulnerabilities-image]: https://snyk.io/test/github/nutes-uepb/amqp-client-python/badge.svg?targetFile=requirements.txt
230
256
  [known-vulnerabilities-url]: https://snyk.io/test/github/nutes-uepb/amqp-client-python?targetFile=requirements.txt
231
257
  [releases-image]: https://img.shields.io/github/release-date/nutes-uepb/amqp-client-python.svg
232
- [releases-url]: https://github.com/nutes-uepb/amqp-client-python/releases
258
+ [releases-url]: https://github.com/nutes-uepb/amqp-client-python/releases
@@ -1,6 +1,6 @@
1
1
  # AMQP Client Python
2
2
 
3
- Client with high level of abstraction for manipulation of messages in the event bus RabbitMQ.
3
+ A Python client providing a high-level abstraction for interacting with RabbitMQ, simplifying message publishing, subscribing, and RPC patterns.
4
4
 
5
5
  --------
6
6
 
@@ -21,6 +21,18 @@ Client with high level of abstraction for manipulation of messages in the event
21
21
 
22
22
  **Source Code**: <a href="https://github.com/nutes-uepb/amqp-client-python" target="_blank">https://github.com/nutes-uepb/amqp-client-python</a>
23
23
 
24
+ **Discord Server**: <a href="https://discord.gg/RkXNeZpNZk" target="_blank">https://discord.gg/RkXNeZpNZk</a>
25
+
26
+ ### 🦀 Looking for higher performance? Try `amqp-rs`!
27
+ If you need higher throughput, thread safety, and built-in compression, check out [**amqp-rs**](https://pypi.org/project/amqp-rs/).
28
+
29
+ It is a high-performance Python extension developed in Rust using PyO3 and `tokio`. It shares a similar API and design philosophy with this library, but adds native thread safety, `zstd`/`zlib`/`lz4` compression, robust TLS/SSL support, and graceful shutdowns.
30
+
31
+ You can install it via `pip` or `uv`:
32
+ ```bash
33
+ pip install amqp-rs
34
+ ```
35
+
24
36
  ---
25
37
  ### Features:
26
38
  - Automatic creation and management of queues, exchanges and channels;
@@ -37,6 +49,18 @@ Client with high level of abstraction for manipulation of messages in the event
37
49
  | 0.2.0 | 0.2.0 |
38
50
  | 0.1.14 | ~0.1.12 |
39
51
 
52
+ ### Installation
53
+
54
+ You can install `amqp-client-python` using pip:
55
+ ```bash
56
+ pip install amqp-client-python
57
+ ```
58
+
59
+ ### Prerequisites
60
+
61
+ * Python 3.7+
62
+ * A running RabbitMQ instance.
63
+
40
64
  ### Examples:
41
65
  #### you can use [sync](https://github.com/nutes-uepb/amqp-client-python/blob/develop/amqp_client_python/rabbitmq/eventbus_rabbitmq.py) , [async eventbus](https://github.com/nutes-uepb/amqp-client-python/blob/develop/amqp_client_python/rabbitmq/async_eventbus_rabbitmq.py) and [sync wrapper](https://github.com/nutes-uepb/amqp-client-python/blob/develop/amqp_client_python/rabbitmq/eventbus_wrapper_rabbitmq.py) of async eventbus
42
66
  <details><summary>async usage </summary>
@@ -2,3 +2,14 @@ from .rabbitmq import EventbusRabbitMQ, AsyncEventbusRabbitMQ, EventbusWrapperRa
2
2
  from .domain.models import Config, Options, SSLOptions
3
3
  from .domain.utils import ConnectionType
4
4
  from pika import DeliveryMode
5
+
6
+ __all__ = [
7
+ "EventbusRabbitMQ",
8
+ "AsyncEventbusRabbitMQ",
9
+ "EventbusWrapperRabbitMQ",
10
+ "Config",
11
+ "Options",
12
+ "SSLOptions",
13
+ "ConnectionType",
14
+ "DeliveryMode",
15
+ ]
@@ -1,3 +1,9 @@
1
1
  from .config import Config
2
2
  from .options import Options
3
3
  from .ssl_options import SSLOptions
4
+
5
+ __all__ = [
6
+ "Config",
7
+ "Options",
8
+ "SSLOptions",
9
+ ]
@@ -10,15 +10,11 @@ class Config:
10
10
  self, options: Options, ssl_options: Optional[SSLOptions] = None
11
11
  ) -> None:
12
12
  """
13
- Create an Config object thats hold and mount the connection information.
13
+ Create a Config object that holds and manages the connection information.
14
14
 
15
15
  Args:
16
- options: hold information for estabilish connection
17
- ssl_options: hold information for estabilish SSL connections
18
-
19
- Returns:
20
-
21
- Raises:
16
+ options: holds information for establishing connection
17
+ ssl_options: holds information for establishing SSL connections
22
18
 
23
19
  Examples:
24
20
  >>> Config(
@@ -32,16 +28,13 @@ class Config:
32
28
 
33
29
  def build(self) -> "Config":
34
30
  """
35
- Create an Config object thats hold and mount the connection information.
36
-
37
- Args:
31
+ Create a Config object that holds and manages the connection information.
38
32
 
39
33
  Returns:
40
34
  Config object
41
35
 
42
- Raises:
43
-
44
36
  Examples:
37
+ >>> # config = Config(...)
45
38
  >>> config.build()
46
39
  """
47
40
  opt = {
@@ -18,7 +18,7 @@ class Options:
18
18
  **kwargs: Dict[str, Any]
19
19
  ) -> None:
20
20
  """
21
- Create an Options object that hold the credentials and configs options.
21
+ Create an Options object that holds the credentials and configuration options.
22
22
 
23
23
  Args:
24
24
  queue_name: name of queue that will be used for subscriptions
@@ -34,10 +34,6 @@ class Options:
34
34
  publisher_confirms: wait for publisher confirmations
35
35
  **kwargs: pika options
36
36
 
37
- Returns:
38
-
39
- Raises:
40
-
41
37
  Examples:
42
38
  >>> Options("example", "example.rpc", "example.rpc", "amqp://admin:admin@localhost:5672/")
43
39
 
@@ -3,18 +3,13 @@ class SSLOptions:
3
3
  self, certfile_path: str, keyfile_path: str, ca_certs_path: str
4
4
  ) -> None:
5
5
  """
6
- Create an SslOptions object that hold the certs paths.
6
+ Create an SslOptions object that holds the cert paths.
7
7
 
8
8
  Args:
9
9
  certfile_path: cert file path string
10
10
  keyfile_path: private key file path string
11
11
  ca_certs_path: ca file path string
12
12
 
13
- Returns:
14
- Um dicionário com as notas da escala e os graus.
15
-
16
- Raises:
17
-
18
13
  Examples:
19
14
  >>> SSLOptions("./.certs/cert.pem", "./.certs/privkey.pem", "./.certs/ca.pem")
20
15
  """
@@ -1,2 +1,7 @@
1
1
  from .connection_type import ConnectionType
2
2
  from .types import HandlerType
3
+
4
+ __all__ = [
5
+ "ConnectionType",
6
+ "HandlerType",
7
+ ]
@@ -4,3 +4,12 @@ from .async_provider_handler import AsyncProviderHandler
4
4
  from .async_subscriber_handler import AsyncSubscriberHandler
5
5
  from .provider_handler import ProviderHandler
6
6
  from .subscriber_handler import SubscriberHandler
7
+
8
+ __all__ = [
9
+ "IntegrationEvent",
10
+ "IntegrationEventHandler",
11
+ "AsyncProviderHandler",
12
+ "AsyncSubscriberHandler",
13
+ "ProviderHandler",
14
+ "SubscriberHandler",
15
+ ]
@@ -7,3 +7,15 @@ from .publish_timeout_exception import PublishTimeoutException
7
7
  from .auto_reconnect_exception import AutoReconnectException
8
8
  from .blocking_exception import BlockingException
9
9
  from .thread_unsafe_exception import ThreadUnsafeException
10
+
11
+ __all__ = [
12
+ "EventBusException",
13
+ "NackException",
14
+ "RpcProviderException",
15
+ "TimeoutException",
16
+ "ResponseTimeoutException",
17
+ "PublishTimeoutException",
18
+ "AutoReconnectException",
19
+ "BlockingException",
20
+ "ThreadUnsafeException",
21
+ ]
@@ -1,6 +1,6 @@
1
1
  from .async_eventbus_rabbitmq import AsyncEventbusRabbitMQ
2
2
  from .async_connection_factory import AsyncConnectionFactoryRabbitMQ
3
- from .async_connection import AsyncConnection, ConnectionType
3
+ from .async_connection import AsyncConnection
4
4
  from .async_channel_factory import AsyncChannelFactoryRabbitMQ
5
5
  from .async_channel import AsyncChannel
6
6
  from .eventbus_rabbitmq import EventbusRabbitMQ
@@ -9,3 +9,17 @@ from .connection_rabbitmq import ConnectionRabbitMQ
9
9
  from .channel_factory_rabbitmq import ChannelFactoryRabbitMQ
10
10
  from .channel_rabbitmq import ChannelRabbitMQ
11
11
  from .eventbus_wrapper_rabbitmq import EventbusWrapperRabbitMQ
12
+
13
+ __all__ = [
14
+ "AsyncEventbusRabbitMQ",
15
+ "AsyncConnectionFactoryRabbitMQ",
16
+ "AsyncConnection",
17
+ "AsyncChannelFactoryRabbitMQ",
18
+ "AsyncChannel",
19
+ "EventbusRabbitMQ",
20
+ "ConnectionFactoryRabbitMQ",
21
+ "ConnectionRabbitMQ",
22
+ "ChannelFactoryRabbitMQ",
23
+ "ChannelRabbitMQ",
24
+ "EventbusWrapperRabbitMQ",
25
+ ]