-
Notifications
You must be signed in to change notification settings - Fork 51
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature] Adds a transport class for the Http Input Plugin #51
Conversation
5617d7e
to
bb07fb8
Compare
d0522d8
to
3a37570
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for contribution.
I added a few remarks and questions, it would be nice to get them resolved.
Generally, it would be cool to follow the existing code style like defining all instance attributes in __init__()
, use single quotes for string literals.
Also updating the documentation about the new transport is missing.
Thank you very much for your review. I will answer your question and I will add the documentation as quickly as possible. edit: Usually I use now the black code style. But I will convert all the double quotes back into single quotes. |
@eht16 I changed the code. Can you please review it again. |
They released isort 5.0.4 yesterday and removed SortImports. But pylint is still using it. |
I know. There is pylint-dev/pylint#3722 and pylint-dev/pylint#3725. |
That's one of the reasons I don't use |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your changes. Much appreciated.
I got only a few more minor remarks.
Sorry, I closed it accidentally ^^ |
If you want, you can apply the following changes to tox.ini (and commit them) as a temporary workaround to get the checks running again until Pylint is fixed: diff --git a/tox.ini b/tox.ini
index 9f1586c..62995f6 100644
--- a/tox.ini
+++ b/tox.ini
@@ -13,7 +13,7 @@ logstash_async_modules = logstash_async tests
[testenv]
deps =
flake8
- isort
+ isort<5
pylint
commands =
# linting and code analysis
@@ -29,7 +29,7 @@ commands =
# for Python 2.7.
deps =
flake8
- isort
+ isort<5
commands =
# linting and code analysis
{envbindir}/flake8 {[tox]logstash_async_modules} |
@eht16 I added the documentation for the new |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks again for your efforts!
Especially for the great docs and consistently using "TLS" 💯
You are welcome. |
@eht16 Sorry, I was busy last week. I added the the requested changes. I hope I'll find some time to implement the tests this week. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
The code looks great now.
I'd be fine with merging this and adding the tests later on.
I also finally managed to release a last Python2 release and a brand-new Python3-only release, so existing Python2 users can stick to the old version and everyone else will get newest and hottest Python3-only code :).
Hi @jloehel, any news? |
b58372f
to
2b642c1
Compare
Signed-off-by: Jürgen Löhel <[email protected]>
Signed-off-by: Jürgen Löhel <[email protected]>
Signed-off-by: Jürgen Löhel <[email protected]>
Signed-off-by: Jürgen Löhel <[email protected]>
Signed-off-by: Jürgen Löhel <[email protected]>
Signed-off-by: Jürgen Löhel <[email protected]>
Signed-off-by: Jürgen Löhel <[email protected]>
Signed-off-by: Jürgen Löhel <[email protected]>
Signed-off-by: Jürgen Löhel <[email protected]>
Signed-off-by: Jürgen Löhel <[email protected]>
Pylint is not yet compatible with isort 5.x For more information please visit: * pylint-dev/pylint#3722 * pylint-dev/pylint#3725 Signed-off-by: Jürgen Löhel <[email protected]>
Signed-off-by: Jürgen Löhel <[email protected]>
Signed-off-by: Jürgen Löhel <[email protected]>
Signed-off-by: Jürgen Löhel <[email protected]>
Signed-off-by: Jürgen Löhel <[email protected]>
Signed-off-by: Jürgen Löhel <[email protected]>
Signed-off-by: Jürgen Löhel <[email protected]>
Signed-off-by: Jürgen Löhel <[email protected]>
Signed-off-by: Jürgen Löhel <[email protected]>
Signed-off-by: Jürgen Löhel <[email protected]>
This reverts commit f4cd95c.
This reverts commit 4795213.
8cb94ca
to
aaa2293
Compare
Moin moin, sorry I was some kind of busy the last weeks. I rebased the branch and reverted the isort/py27 commits. May I revert also the type hints and the f-strings? |
Yes, fine by me, sorry for the trouble. But at least now we are Python3 only. |
Signed-off-by: Jürgen Löhel <[email protected]>
Signed-off-by: Jürgen Löhel <[email protected]>
Null problemo. ^^ I added the two commits. :-) |
Thanks a lot for this feature and your patience with my remarks :). If you still want to add some tests for the HTTP transport, that'd be fine. |
This commit adds a more generic class called Transport and a additional
class HttpTransport to create a client for the Http Input Plugin of
logstash: https://www.elastic.co/guide/en/logstash/current/plugins-inputs-http.html#plugins-inputs-http
Signed-off-by: Jürgen Löhel [email protected]