This repository has been archived by the owner on Oct 15, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 14
[R4R]add option to enable range query for tx indexer;add option to disable websocket #115
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
653e6f5
to
6c8f565
Compare
… websocket server
6c8f565
to
fb17dd0
Compare
rickyyangz
reviewed
Sep 9, 2019
@@ -169,6 +177,18 @@ func (txi *TxIndex) Search(q *query.Query) ([]*types.TxResult, error) { | |||
// if both upper and lower bounds exist, it's better to get them in order not | |||
// no iterate over kvs that are not within range. | |||
ranges, rangeIndexes := lookForRanges(conditions) | |||
if !txi.enableRangeQuery && len(rangeIndexes) > 0 { |
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.
no need to find the operator, just print the query
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.
updated
rickyyangz
approved these changes
Sep 9, 2019
ackratos
approved these changes
Sep 9, 2019
rickyyangz
reviewed
Sep 9, 2019
@@ -169,6 +177,10 @@ func (txi *TxIndex) Search(q *query.Query) ([]*types.TxResult, error) { | |||
// if both upper and lower bounds exist, it's better to get them in order not |
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.
on second thought, we may check strings.ContainsAny(s, "><")
before we parse the query conditions.
HaoyangLiu
approved these changes
Sep 10, 2019
yutianwu
approved these changes
Sep 10, 2019
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
resolve issue #114
Description
more connection error between node and kafka should be taken into consideration
sarama didn't wrap tcp connection error. We need categorize them into retryable error so that downstream service cannot miss message.
Rationale
Example
\u003e
means>
.if disable websocket server:
![image](https://user-images.githubusercontent.com/7310198/64529798-43c61980-d33e-11e9-9d58-c2f640cfe2aa.png)
Changes
Code tidy up
Preflight checks
make build
)make test
)Already reviewed by
...
Related issues
#114