FLUME-3262: Improve Scribe Source With More Options#219
FLUME-3262: Improve Scribe Source With More Options#219JohnZZGithub wants to merge 1 commit intoapache:trunkfrom
Conversation
|
Can one of the admins verify this patch? |
szaboferee
left a comment
There was a problem hiding this comment.
@JohnZZGithub thanks for the contribution!
It is a really good feature to have more options.
To make the new feature more accessible for others, could you add the parameters to the documentation with some examples?
It would also be great if you could include some test cases that make sure that the new code works.
We could extract the creation logic into a factory to maintain readability.
...g-sources/flume-scribe-source/src/main/java/org/apache/flume/source/scribe/ScribeSource.java
Outdated
Show resolved
Hide resolved
|
The failure seems not to be caused by patch https://builds.apache.org/job/flume-github-pull-request/org.apache.flume$flume-ng-tests/82/testReport/junit/org.apache.flume.test.agent/TestConfig/testConfigReplacement/ |
| thriftServerType = ThriftServerType.getServerType( | ||
| context.getString("thriftServer", DEFAULT_THRIFT_SERVER_TYPE.getValue())); | ||
| } catch (IllegalArgumentException ex) { | ||
| LOG.error("Wrong thrift server type config", ex); |
There was a problem hiding this comment.
I would include the bad value in the error message, to help finding the bad config.
Could we throw an exception here instead of the error logging?
There was a problem hiding this comment.
@majorendre Hi, I updated the patch and added an IllegalArgumentException here. However, the caller which is @Override public void configure(Context context) can't throw any exception as it overrides an non-exception method.
There was a problem hiding this comment.
Hi @JohnZZGithub
Thanks for the quick reply.
I took a deeper look and I suggest not handling that IllegalArgumentException at all. You can just let it propagate, Flume will handle it properly. I did test this, to be sure.
See my attached diff. I also added the Apache licence to avoid 'rat' errors.
As @szaboferee mentioned before, please add some test cases.
Regards,
Endre
|
Hi @JohnZZGithub, thanks for the contribution. I tried to set up Scribe source with different Thrift server types and feed the source with the CLI tool from #218. |
|
@majorendre Thanks for the patch, will add more tests. |
|
@JohnZZGithub could you please rebase your change to the latest trunk? It cannot be applied at the moment. |
|
@szaboferee Sure, will probably update the patch today with more tests |
9d56568 to
811509e
Compare
|
@turcsanyip The failure of TThreadPoolServer is called by wrong socket type (should be blocking server socket), fixed now. Thanks |
811509e to
fb1e799
Compare
|
Hi, I had updated the patch, please review it when you get a chance, thank you! |
|
Hi @JohnZZGithub the checks failed. I thought You did not have the time to fix it. I personally start the review after the build is green to save the extra rounds. Feel free to run a mvn clean verify locally to check if the build is successful before you commit. |
|
@szaboferee Ah, sorry, my bad. I had only clicked into the first link and it shows 500 erros. So I thought it was not my patch's problem by mistake. Now I fix it. It's a licences issue. |
c8be2c0 to
fb16224
Compare
|
@szaboferee @majorendre I updated the diff. Please review it again when you get a chance, thanks. |
[PILIVDN-8740]ymfetcher support audio
|
@mpercy Could you please help to review the change? Thanks |
We added following options:
1. ThriftServerType, user choose one of {THshaServer, TThreadedSelectorServer, TThreadPoolServer} baed on their own traffic pattern. More details on thrift server could be found on Apache Thrift project.
2. MaxThriftFrameSizeBytes: thrift frame size limit.
3. MaxReadBufferSize. The buffer size thrift used to handle requests, increase the buffer will benefit throughput under heavy load.
c71bc0b to
5a412e5
Compare
We added following options: