Skip to content

Commit ff94da3

Browse files
Code review feedback
1 parent 2efae24 commit ff94da3

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

README.md

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -476,7 +476,7 @@ db = XRayFlaskSqlAlchemy(app)
476476

477477
### Ignoring httplib requests
478478

479-
If you want to ignore certain httplib requests you can do so based on the hostname or URL that is being requsted.
479+
If you want to ignore certain httplib requests you can do so based on the hostname or URL that is being requsted. The hostname is matched using the Python [fnmatch library](https://docs.python.org/3/library/fnmatch.html) which does Unix glob style matching.
480480

481481
```python
482482
from aws_xray_sdk.ext.httplib import add_ignored as xray_add_ignored
@@ -494,6 +494,15 @@ xray_add_ignored(urls=['/test-path', '/other-test-path'])
494494
xray_add_ignored(hostname='myapp.com', urls=['/test-url'])
495495
```
496496

497+
If you use a subclass of httplib to make your requests, you can also filter on the class name that initiates the request. This must use the complete package name to do the match.
498+
499+
```python
500+
from aws_xray_sdk.ext.httplib import add_ignored as xray_add_ignored
501+
502+
# ignore all requests made by botocore
503+
xray_add_ignored(subclass='botocore.awsrequest.AWSHTTPConnection')
504+
```
505+
497506
## License
498507

499508
The AWS X-Ray SDK for Python is licensed under the Apache 2.0 License. See LICENSE and NOTICE.txt for more information.

0 commit comments

Comments
 (0)