Optimizing logging calls to reduce requests#
Experiencing connection interruptions. Will try to reestablish communication with Neptune. Internal exception was: HTTPTooManyRequests
To avoid sending too many requests to the Neptune server too frequently, there may be things you can do to optimize your logging calls.
The below involves ten logging calls:
The following results in the same metadata structure, but involves a single logging call:
The tradeoff is that in the first case, values are logged almost as soon as they are generated. This is not the case with the latter.
- Upload the files in batch with
upload_files()(results in a
- Create a series of files with
extend()(results in a