bitshares / bitshares/bitshares-core
Ideally get_liquidity_pool_history API should return operation history IDs (1.11.x)
- Dominant language
- C++
- Stars
- 1.2k
- Forks
- 660
- Avg merge
- 8h 17m
- Merged PRs (30d)
- 26
Description
**User Story**
As a user I'd like the `get_liquidity_pool_history` API returns operation history IDs (1.11.x) so that it is more convenient to track the data.
A typical operation history record returned in `get_liquidity_pool_history` is like this:
> {"id":"5.4.3683","pool":"1.19.0","sequence":112,"time":"2020-11-11T00:28:30","op_type":63,"op":{"id":"0.0.0","op":[63,{"fee":{"amount":100000,"asset_id":"1.3.0"},"account":"1.2.989566","pool":"1.19.0","amount_to_sell":{"amount":6591000,"asset_id":"1.3.0"},"min_to_receive":{"amount":972000,"asset_id":"1.3.3291"},"extensions":[]}],"result":[4,{"paid":[{"amount":6591000,"asset_id":"1.3.0"}],"received":[{"amount":972197,"asset_id":"1.3.3291"}],"fees":[{"amount":0,"asset_id":"1.3.0"},{"amount":1948,"asset_id":"1.3.3291"},{"amount":4895,"asset_id":"1.3.3291"}]}],"block_num":53104086,"trx_in_block":0,"op_in_trx":0,"virtual_op":0}}
The value of the `"op.id"` field is always `"0.0.0"`.
Note:
The operation history IDs are generated by the `account_history` plugin or the `elasticsearch` plugin. The pool history is stored in the `market_history` plugin. To implement the feature requested in this issue, probably need to exchange data between plugins.
**Impacts**
Describe which portion(s) of BitShares Core may be impacted by your request. Please tick at least one box.
- [x] API (the application programming interface)
- [ ] Build (the build process or something prior to compiled code)
- [ ] CLI (the command line wallet)
- [ ] Deployment (the deployment process after building such as Docker, Travis, etc.)
- [ ] DEX (the Decentralized EXchange, market engine, etc.)
- [ ] P2P (the peer-to-peer network for transaction/block propagation)
- [ ] Performance (system or user efficiency, etc.)
- [ ] Protocol (the blockchain logic, consensus, validation, etc.)
- [ ] Security (the security of system or user data, etc.)
- [ ] UX (the User Experience)
- [ ] Other (please add below)
## CORE TEAM TASK LIST
- [ ] Evaluate / Prioritize Feature Request
- [ ] Refine User Stories / Requirements
- [ ] Define Test Cases
- [ ] Design / Develop Solution
- [ ] Perform QA/Testing
- [ ] Update Documentation
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with the get_liquidity_pool_history API and trace how records are produced by the market_history plugin. Compare that data with the operation history IDs generated by the account_history or elasticsearch plugin. Done means returned records expose the relevant operation history ID instead of an op.id value of 0.0.0, with the required plugin data exchange defined and tested.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- api, blockchain
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100