77
88## Installation
99
10- In time, this will be on the [ Python Package Index] ( ) but for now you need to use the
10+ In time, this will be on the [ Python Package Index] ( ) but for now you need to use the
1111repository url to get it:
1212
1313=== "uv"
@@ -41,7 +41,7 @@ In order to work with pygeoapi-prefect, you need to set up:
4141
4242### Prefect server
4343
44- After installation, you need to have a Prefect server running and to set some environment variables
44+ After installation, you need to have a Prefect server running and to set some environment variables
4545so that the Prefect Manager is able to communicate with it.
4646
4747As the most basic setup, just start a local Prefect server
@@ -64,7 +64,7 @@ As the most basic setup, just start a local Prefect server
6464
6565### Pygeoapi
6666
67- Enable the Prefect job/process manager by modifying your pygeoapi configuration file. The
67+ Enable the Prefect job/process manager by modifying your pygeoapi configuration file. The
6868` server.manager.name ` configuration parameter needs to be set to ` pygeopai_prefect.PrefectManager ` .
6969
7070``` yaml
@@ -79,25 +79,25 @@ server:
7979The Prefect Manager accepts the following configuration parameters, all of which are optional.
8080These should be specified as properties of the ` server.manager` object:
8181
82- - `use_vanilla_processor_deployments : bool = True ` - Whether to call native pygeoapi processors via the
83- Prefect deployment interface. If this is enabled (which is the default) :
82+ - `use_deployment_for_sync_requests : bool = False ` - Whether to call native pygeoapi processors via the
83+ Prefect deployment interface or not . If this is enabled :
8484
85- - Jobs are executed via the Prefect worker, which you must start (as mentioned below)
85+ - Jobs are executed via the Prefect worker, which you must have started beforehand (as mentioned below)
8686 - Jobs are coordinated by the Prefect scheduler, which means that they may not start immediately
8787 - Jobs are run in a different process than pygeoapi
88- - This means that job execution is slower, as there is a temporal overhead which is introduced by
88+ - This means that job execution is slower, as there is a temporal overhead that is introduced by
8989 the coordination that happens between the Prefect scheduler service and the Prefect worker
90-
90+
9191 If this is disabled, then jobs are executed immediately and run in the same process as pygeoapi
9292
93- - `sync_job_execution_timeout_seconds : int = 60` - How much time to give a sync job to finish its
93+ - `sync_job_execution_timeout_seconds : int = 60` - How much time to give a sync job to finish its
9494 processing before declaring it as failed
9595
9696
9797# ### Processors
9898
99- In addition to the manager, you must configure pygeoapi with some resources of type `process`.
100- ` PrefectManager` is able to work both with vanilla pygeoapi processors and with a custom Prefect-aware
99+ In addition to the manager, you must configure pygeoapi with some resources of type `process`.
100+ ` PrefectManager` is able to work both with vanilla pygeoapi processors and with a custom Prefect-aware
101101processor type.
102102
103103
122122
123123# ### Launching pygeoapi
124124
125- When starting pygeoapi, ensure the `PREFECT_API_URL` environment variable is set. As the most basic
125+ When starting pygeoapi, ensure the `PREFECT_API_URL` environment variable is set. As the most basic
126126launch of pygeoapi, you can create a `pygeoapi.env` file with these contents :
127127
128128` ` ` shell
@@ -154,14 +154,14 @@ And then launch pygeoapi:
154154 ` ` `
155155
156156This shall start the pygeoapi server, with an instance of `PrefectManager` as its process/job manager, and
157- using the Prefect server that is specified by the `PREFECT_API_URL` environment variable. It
157+ using the Prefect server that is specified by the `PREFECT_API_URL` environment variable. It
158158can now be used with both vanilla pygeoapi processes and a new kind of Prefect-aware processors.
159159
160160
161161# ## Prefect worker(s)
162162
163- The Prefect server dispatches execution to workers, which means you also need to have at least a Prefect
164- worker up and running. There are many ways to set up a Prefect worker, depending on the chosen
163+ The Prefect server dispatches execution to workers, which means you also need to have at least a Prefect
164+ worker up and running. There are many ways to set up a Prefect worker, depending on the chosen
165165execution model.
166166
167167# ### Run pygeoapi vanilla processes locally
@@ -187,20 +187,20 @@ running a process
187187
188188# ### Other execution models
189189
190- Prefect is a very flexible platform and is able to coordinate the execution of processes in different
190+ Prefect is a very flexible platform and is able to coordinate the execution of processes in different
191191environments, such as remote hosts, docker containers, k8s pods, etc. In order to take advantage of these
192192other execution models you will need to both :
193193
194194- Configure your infrastructure
195195- Deploy your processor code using [Prefect deployments](https://docs.prefect.io/v3/concepts/deployments)
196- - Create pygeoapi processes that inherit from the custom pygeoapi-prefect `BasePrefectProcessor` and
196+ - Create pygeoapi processes that inherit from the custom pygeoapi-prefect `BasePrefectProcessor` and
197197 set them up accordingly in the pygeoapi configuration
198198
199199
200200!!! NOTE
201201
202202 The `PrefectManager` only interacts with the Prefect server and with the Prefect result storage. This means
203- that as long as you define a Prefect Flow and are able to deploy it, then it
203+ that as long as you define a Prefect Flow and are able to deploy it, then it
204204
205205
206206
@@ -209,4 +209,4 @@ other execution models you will need to both:
209209
210210# ## Execute process
211211
212- # ## Monitor execution via Prefect UI
212+ # ## Monitor execution via Prefect UI
0 commit comments