By default, access to external resources (files on hard disk, HTTP requests, ...) is not controlled by the transaction monitor of BaseX. You can use custom XQuery locks to do so:
===Option DeclarationsOptions, Pragmas, Function Annotations===
{{Mark|Introduced with Version 9.1}}: locks via pragmas and function annotations.
* You can declare custom read and write locks via options, pragmas or function annotations.
* The value of the lock may contain one or multiple lock keys (separated with commas). The default value is an empty string.
* Similar to the internal database locks, write locks block all other operations while read locks allow parallel access.
* The internal locks and XQuery locks can co-exist (there will be no conflicts, even if your lock string equals the name of a database that will be locked by the transaction manager).