To get the most out of this book
- The book uses Python language for code examples, and assumes that the reader is comfortable reading it, though an expert level is not needed.
- Previous exposure to complex systems with multiple services will be advantageous to understand the different challenges software architecture presents. This should be simple for developers with a couple of years of experience or more.
- Familiarity with web services and REST interfaces is useful to better understand some elements.
Download the example code files
The code bundle for the book is hosted on GitHub at https://github.com/PacktPublishing/Python-Architecture-Patterns. We also have other code bundles from our rich catalog of books and videos available at https://github.com/PacktPublishing/. Check them out!
Download the color images
We also provide a PDF file that has color images of the screenshots/diagrams used in this book. You can download it here: https://static.packt-cdn.com/downloads/9781801819992_ColorImages.pdf
Conventions used
There are a number of text conventions used throughout this book.
CodeInText
: Indicates code words in text, object names, module names, folder names, filenames, file extensions, pathnames, dummy URLs and user input. Here is an example: "For this recipe, we need to import the requests
module."
A block of code is set as follows:
def leonardo(number):
if number in (0, 1):
return 1
# EXAMPLE COMMENT
return leonardo(number - 1) + leonardo(number - 2) + 1
Note that code may be edited for concision and clarity. Refer to the full code when necessary, which is available on GitHub.
Any command-line input or output is written as follows (notice the $
symbol):
$ python example_script.py parameters
Any input in the Python interpreter is written as follows (notice the >>>
symbol). Expected output will be reflected without the >>>
symbol:
>>> import logging
>>> logging.warning('This is a warning')
WARNING:root:This is a warning
To enter the Python interpreter, call the python3
command with no parameters:
$ python3
Python 3.9.7 (default, Oct 13 2021, 06:45:31)
[Clang 13.0.0 (clang-1300.0.29.3)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>>
Any command-line input or output is written as follows:
$ cp example.txt copy_of_example.txt
Bold: Indicates a new term, an important word, or words that you see on the screen, for example, in menus or dialog boxes, also appear in the text like this. For example: "Select System info from the Administration panel."
Warnings or important notes appear like this.
Tips and tricks appear like this.