Skip to content
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

Merge Plugins and graphene update changes from beatrice TESTNET to master #317

Merged
merged 296 commits into from
Apr 15, 2020
Merged
Show file tree
Hide file tree
Changes from 250 commits
Commits
Show all changes
296 commits
Select commit Hold shift + click to select a range
3b36d46
Merge pull request #96 from peerplays-network/feature/GRPH-77
bobinson Aug 30, 2019
c5623fd
increase delay for node connection
Aug 29, 2019
3362d60
remove cache from cli get_account
oxarbitrage Aug 30, 2019
fcfe65a
add cli tests framework
oxarbitrage Aug 30, 2019
1b4b5d7
Merge branch 'develop' into GRPH-50-network_broadcast_api-fix-v2
Noughmad Sep 2, 2019
43bfc3e
Adjust newly merged code to new API
Noughmad Sep 2, 2019
a797787
Merge branch 'develop' into GRPH-59-Proposal-failure-handling
Noughmad Sep 2, 2019
b751508
Merged changes from Bitshares PR 1036
Sep 2, 2019
77dd8a9
GRPH-76 - Short-cut long sequences of missed blocks
obucina Sep 2, 2019
07249e9
Merge pull request #92 from peerplays-network/GRPH-70
bobinson Sep 2, 2019
e44b04d
Merge pull request #93 from peerplays-network/GRPH-71
bobinson Sep 2, 2019
cdc89c1
Merge pull request #97 from peerplays-network/feature/GRPH-61
bobinson Sep 2, 2019
4268045
Improved resilience of block database against corruption
pmconrad Jul 12, 2017
1741703
Moved reindex logic into database / chain_database, make use of addit…
pmconrad Jul 12, 2017
a0052d4
Enable undo + fork database for final blocks in a replay
pmconrad Jul 13, 2017
3bee3f2
Log starting block number of replay
pmconrad Jul 31, 2017
b45a6ca
Prevent unsigned integer underflow
pmconrad Jul 31, 2017
c8f8f1a
Fixed lock detection
pmconrad Aug 3, 2017
b71f20e
Dont leave _data_dir empty if db is locked
pmconrad Aug 4, 2017
95a5b57
Writing the object_database is now almost atomic
pmconrad Aug 4, 2017
0d108fb
Improved consistency check for block_log
pmconrad Aug 4, 2017
ab38218
Cut back block_log index file if inconsistent
pmconrad Aug 4, 2017
7d0d61a
Fixed undo_database
pmconrad Aug 6, 2017
731338f
Added test case for broken merge on empty undo_db
pmconrad Aug 6, 2017
7b259ba
exclude second undo_db.enable() call in some cases
Sep 3, 2019
a081a8e
Add missing change
obucina Sep 3, 2019
1d1193e
change bitshares to core in message
oxarbitrage Sep 3, 2019
f732048
Merge pull request #938 from bitshares/fix-block-storing
abitmore May 24, 2018
22eb42e
Fixed integer overflow issue
Sep 4, 2019
2c28d0d
Merge pull request #87 from peerplays-network/feature/GRPH-54
bobinson Sep 5, 2019
ef7fe58
Merge pull request #98 from peerplays-network/cli_wallet_tests
bobinson Sep 6, 2019
c1d70bf
Merge pull request #89 from peerplays-network/GRPH-4
bobinson Sep 6, 2019
6563644
Merge pull request #91 from peerplays-network/GRPH-51
bobinson Sep 6, 2019
db8efaf
Merge pull request #104 from peerplays-network/feature/GRPH-76
bobinson Sep 6, 2019
64c05f9
Merge pull request #70 from peerplays-network/GRPH-59-Proposal-failur…
bobinson Sep 6, 2019
f9a3d08
Merge pull request #60 from peerplays-network/GRPH-48-Object-Database…
bobinson Sep 6, 2019
b11edaa
Merge pull request #69 from peerplays-network/WASM-49
bobinson Sep 6, 2019
3510704
Fix for for history ID mismatch ( Bitshares PR #875 )
Sep 6, 2019
9224af5
Merge pull request #117 from peerplays-network/feature/GRPH-90
bobinson Sep 9, 2019
00a38c5
Update the FC submodule with the changes for GRPH-4
Noughmad Sep 10, 2019
646dc2e
Merged Bitshares PR #1462 and compilation fixes
Sep 10, 2019
edec01f
Support/gitlab (#123)
Sep 10, 2019
8cd22ee
Fix undefined references in cli test
Noughmad Sep 11, 2019
be60e41
Updated GitLab CI
Sep 11, 2019
0bdbd64
Merge pull request #121 from peerplays-network/GRPH-4-update-submodule
bobinson Sep 11, 2019
0bcf6d4
Fix #436 object_database created outside of witness data directory
Feb 25, 2018
f1ffd52
supplement more comments on database::_opened variable
Feb 26, 2018
b3c64c8
prevent segfault when destructing application obj
jmjatlanta Jan 14, 2019
9fc07f1
Fixed test failures and compilation issue
Sep 12, 2019
755383c
Merge branch 'develop' into feature/GRPH-88
oxarbitrage Sep 12, 2019
ddc41d6
Merge pull request #120 from peerplays-network/GRPH-89
bobinson Sep 12, 2019
67362be
Merge branch 'develop' into feature/GRPH-93
Noughmad Sep 16, 2019
4b5076b
Merge branch 'develop' into GRPH-73-fix-block-id-forks
Noughmad Sep 16, 2019
cde1834
minor performance improvement
srpatel19590 Sep 5, 2019
5ce9f8c
Added comment
srpatel19590 Sep 9, 2019
1f43c2f
Merge pull request #115 from peerplays-network/feature/GRPH-80
bobinson Sep 17, 2019
2dc79e8
Merge branch 'develop' into feature/GRPH-93
Noughmad Sep 17, 2019
6850be4
Fix compilation in debug mode
Noughmad Sep 17, 2019
1f4de92
Merge branch 'develop' into feature/GRPH-88
oxarbitrage Sep 17, 2019
44137a3
Merge pull request #111 from peerplays-network/feature/GRPH-88
oxarbitrage Sep 17, 2019
d911b3d
Merge branch 'develop' into GRPH-75
oxarbitrage Sep 17, 2019
4914e74
Merge branch 'develop' into feature/GRPH-79
oxarbitrage Sep 17, 2019
5890055
Merge branch 'develop' into GRPH-73-fix-block-id-forks
oxarbitrage Sep 17, 2019
19a9641
Merge pull request #110 from peerplays-network/GRPH-73-fix-block-id-f…
oxarbitrage Sep 17, 2019
88d90c3
Merge branch 'develop' into feature/GRPH-79
oxarbitrage Sep 17, 2019
ca4a02d
Merge pull request #100 from peerplays-network/feature/GRPH-79
oxarbitrage Sep 18, 2019
bada09d
Merge branch 'develop' into GRPH-75
oxarbitrage Sep 18, 2019
96161db
Merge pull request #101 from peerplays-network/GRPH-75
oxarbitrage Sep 18, 2019
dfba085
Fixed duplicate ops returned from get_account_history
srpatel19590 Sep 4, 2019
12ef667
Fixed account_history_pagination test
srpatel19590 Sep 14, 2019
5a00e4f
Removed unrelated comment
srpatel19590 Sep 18, 2019
499a5fc
Merge branch 'develop' into GRPH-50-network_broadcast_api-fix-v2
Noughmad Sep 18, 2019
7bc47a6
Update to fixed version of fc
Noughmad Sep 18, 2019
9415749
Merge branch 'develop' into feature/GRPH-93-v2
Noughmad Sep 18, 2019
2e85219
Merge pull request #109 from peerplays-network/feature/GRPH-86
oxarbitrage Sep 18, 2019
fba1088
Merge pull request #131 from peerplays-network/feature/GRPH-93-v2
bobinson Sep 20, 2019
12105ab
Skip auth check when pushing self-generated blocks
abitmore Aug 13, 2018
56a6f8b
Extract public keys before pushing a transaction
abitmore Aug 22, 2018
c110508
Dereference chain_database shared_ptr
abitmore Aug 23, 2018
2dfb67e
Updated transaction::signees to mutable
abitmore Aug 27, 2018
aa31de5
Added get_asset_count API
srpatel19590 Sep 20, 2019
106824c
No longer extract public keys before pushing a trx
abitmore Aug 27, 2018
2a3d8a4
changes to withdraw_vesting feature(for both cdd and GPOS)
pbattu123 Sep 20, 2019
b358241
Comments update
pbattu123 Sep 20, 2019
8e1c038
update to GPOS hardfork ref
pbattu123 Sep 20, 2019
97f9875
Merge branch 'develop' into GRPH-50-network_broadcast_api-fix-v2
Noughmad Sep 21, 2019
4586cc5
Remove leftover comment from merge
Noughmad Sep 21, 2019
9ec835b
Merge pull request #95 from peerplays-network/issue-154
pbattu123 Sep 21, 2019
79dc2f4
Merge pull request #141 from peerplays-network/BLOCKBACK-153
pbattu123 Sep 21, 2019
4a72f94
fix for get_vesting_balance API call
pbattu123 Sep 21, 2019
a7df686
braces update
pbattu123 Sep 21, 2019
af47ed0
Merge pull request #143 from peerplays-network/issue/154-fix
pbattu123 Sep 22, 2019
857a30d
Merge pull request #67 from peerplays-network/GRPH-50-network_broadca…
bobinson Sep 23, 2019
8544896
Allow sufficient space for new undo_session
pmconrad Aug 10, 2018
819e1d2
Throw for deep nesting
pmconrad Aug 11, 2018
1cb494e
Merge pull request #140 from peerplays-network/feature/GRPH-111
bobinson Sep 23, 2019
282ec70
Merge pull request #147 from peerplays-network/feature/GRPH-95
bobinson Sep 23, 2019
83b19d0
node.cpp: Check the attacker/buggy client before updating items ids
RichardWeiYang May 30, 2018
e377478
Merge pull request #139 from peerplays-network/feature/GRPH-94
bobinson Sep 24, 2019
db01f31
Create .gitlab-ci.yml
Sep 25, 2019
2d6f8c4
Added cli_test to CI
Sep 25, 2019
b8cbdc5
Merge pull request #151 from peerplays-network/support/gitlab-develop
bobinson Sep 26, 2019
7fae375
fixing build errors (#150)
bobinson Sep 26, 2019
caa3d24
use random port numbers in app_test (#154)
gladcow Sep 27, 2019
f1eb625
Changes to compiple with GCC 7(Ubuntu 18.04)
pbattu123 Sep 30, 2019
e995744
proposal fail_reason bug fixed (#157)
srpatel19590 Sep 30, 2019
2dcb96b
Added Sonarcloud code_quality to CI (#159)
Oct 1, 2019
1a41b5c
Added sonarcloud analysis (#158)
Oct 1, 2019
d65f20a
changes to have separate methods and single withdrawl fee for multipl…
pbattu123 Oct 3, 2019
c73d0a3
163-fix, Return only non-zero vesting balances
pbattu123 Oct 4, 2019
d2c82cf
Support/gitlab develop (#168)
Oct 4, 2019
e1a6e67
Point to PBSA/peerplays-fc commit f13d063 (#167)
srpatel19590 Oct 4, 2019
3f6b7ab
Merge pull request #164 from peerplays-network/jira-163-fix
pbattu123 Oct 6, 2019
d5dffa6
Merge pull request #163 from peerplays-network/153/fix-add-on
pbattu123 Oct 6, 2019
7b1d31e
Merge pull request #172 from peerplays-network/graphene-release1
pbattu123 Oct 9, 2019
ec33f0c
[GRPH-3] Additional cli tests (#155)
srpatel19590 Oct 10, 2019
4053444
[GRPH-106] Added voting tests (#136)
srpatel19590 Oct 10, 2019
e3b2459
Adjust p2p log level (#180)
srpatel19590 Oct 16, 2019
98cf5d9
Added submodule sync to peerplays compile process
Oct 17, 2019
8c188bd
merge gpos to develop (#186)
oxarbitrage Oct 17, 2019
c025f63
Fixed few error messages
srpatel19590 Oct 19, 2019
0800e2b
error message corrections at other places
srpatel19590 Oct 19, 2019
f7c592d
Updated FC repository to peerplays-network/peerplays-fc (#189)
srpatel19590 Oct 21, 2019
d2a6f6d
Project name update in Doxyfile (#146)
srpatel19590 Oct 22, 2019
0d1c415
changes to allow user to vote in each sub-period
pbattu123 Oct 22, 2019
73829bd
Fixed GPOS vesting factor issue when proxy is set
srpatel19590 Oct 23, 2019
ccdea03
Added unit test for proxy voting
srpatel19590 Oct 23, 2019
8bbab4c
Review changes
srpatel19590 Oct 23, 2019
39e9557
Merge pull request #197 from peerplays-network/feature/BLOCKBACK-165
pbattu123 Oct 23, 2019
d446087
Merge branch 'qa_gpos_18.04' into BLOCKBACK-155
pbattu123 Oct 23, 2019
48d0d88
changes to update last voting time
pbattu123 Oct 23, 2019
3be3fd3
Merge branch 'BLOCKBACK-155' of https://github.com/peerplays-network/…
pbattu123 Oct 23, 2019
d6da296
resolve merge conflict
pbattu123 Oct 24, 2019
cf3b54e
unit test changes and also separated GPOS test suite
pbattu123 Oct 24, 2019
f7d7f04
delete unused variables
pbattu123 Oct 24, 2019
6963018
removed witness check
srpatel19590 Oct 24, 2019
78787c2
eliminate time gap between two consecutive vesting periods
pbattu123 Oct 24, 2019
22e5dfa
deleted GPOS specific test suite and updated gpos tests
pbattu123 Oct 24, 2019
bdd1863
updated GPOS hf
pbattu123 Oct 25, 2019
ed49ab8
Merge pull request #190 from peerplays-network/feature/BLOCKBACK-162
oxarbitrage Oct 25, 2019
e63452c
Merge pull request #199 from peerplays-network/BLOCKBACK_164
oxarbitrage Oct 25, 2019
a8423f1
Fixed dividend distribution issue and added test case
srpatel19590 Oct 25, 2019
8269c94
Merge branch 'qa_gpos_18.04' into BLOCKBACK-155
pbattu123 Oct 25, 2019
46dab25
Merge pull request #193 from peerplays-network/BLOCKBACK-155
pbattu123 Oct 25, 2019
aef57f1
Merge pull request #200 from peerplays-network/feature/BLOCKBACK-166
oxarbitrage Oct 26, 2019
a80d25f
fix flag
oxarbitrage Oct 27, 2019
84f3092
clean newlines gpos_tests
oxarbitrage Oct 27, 2019
7c19662
adapt gpos_tests to changed flag
oxarbitrage Oct 27, 2019
5caaedd
Merge pull request #201 from peerplays-network/fix_flag
pbattu123 Oct 27, 2019
5f1436b
Fix to roll in GPOS rules, carry votes from 6th sub-period
pbattu123 Oct 27, 2019
ac3554e
check was already modified
pbattu123 Oct 27, 2019
9f0b231
comments updated
pbattu123 Oct 28, 2019
3f8ac21
updated comments to the benefit of reviewer
pbattu123 Oct 28, 2019
3a817e1
Merge pull request #202 from peerplays-network/BLOCKBACK-174
pbattu123 Oct 28, 2019
d5d4fdd
Added token symbol name in error messages
srpatel19590 Oct 30, 2019
c8db22d
Added token symbol name in error messages (#204)
srpatel19590 Oct 30, 2019
5d36258
case 1: Fixed last voting time issue
srpatel19590 Oct 31, 2019
e7f65c6
get_account bug fixed
srpatel19590 Sep 2, 2019
fd8659c
Fixed flag issue
srpatel19590 Oct 31, 2019
ab78086
Merge pull request #205 from peerplays-network/BLOCKBACK-155
pbattu123 Oct 31, 2019
61fa391
Fixed spelling issue
srpatel19590 Nov 5, 2019
20a9f9b
Merge pull request #211 from peerplays-network/feature/BLOCKBACK-162
oxarbitrage Nov 5, 2019
f831f95
Merge branch 'qa_gpos_18.04' into develop_gpos
oxarbitrage Nov 5, 2019
a07bcad
remove non needed gcc5 changes to dockerfile
oxarbitrage Nov 6, 2019
3e6b919
GRPH134- High CPU Issue, websocket changes (#213)
sierra19XX Nov 6, 2019
50b80e9
update submodule branch to refer to the latest commit on latest-fc br…
pbattu123 Nov 7, 2019
0bcfaa3
Improve account maintenance performance (#130)
srpatel19590 Nov 7, 2019
25ab039
Merge branch 'develop' into develop_gpos
oxarbitrage Nov 7, 2019
2f4830a
Update CI for syncing gitmodules (#216)
Nov 7, 2019
8a9d3e7
Added logging for the old update_expired_feeds bug
abitmore Jul 1, 2018
01a8155
Minor performance improvement for price::is_null()
abitmore Jul 3, 2018
cabbd7d
Use static refs in db_getter for immutable objects
abitmore Jul 3, 2018
ac7ac9f
Minor performance improvement for db_maint
abitmore Jul 3, 2018
e27b074
Minor code updates for asset_evaluator.cpp
abitmore Jul 3, 2018
36e318a
Improve update_expired_feeds performance #1093
abitmore Jul 3, 2018
04102d5
Change static refs to member pointers of db class
abitmore Jul 3, 2018
dcc6902
Added getter for witness schedule object
abitmore Jul 5, 2018
1939cd1
Added getter for core dynamic data object
abitmore Jul 5, 2018
83736ba
Use getters
abitmore Jul 5, 2018
66f6f26
Removed unused variable
abitmore Jul 5, 2018
2f6de1f
Add comments for update_expired_feeds in db_block
abitmore Jul 25, 2018
02f6019
Minor refactory asset_create_evaluator::do_apply()
abitmore Jul 26, 2018
6a7d670
Added FC_ASSERT for dynamic data id of core asset
abitmore Jul 26, 2018
4f54b13
Added header inclusions in db_management.cpp
abitmore Jul 26, 2018
d99ef0c
fix global objects usage during replay
Sep 5, 2019
943953c
Merge pull request #212 from peerplays-network/develop_gpos
oxarbitrage Nov 8, 2019
fccd856
Merge pull request #149 from peerplays-network/feature/GRPH-114
oxarbitrage Nov 11, 2019
7a1f1a7
Logging config parsing issue
srpatel19590 Nov 14, 2019
ac5d55b
added new files
srpatel19590 Nov 14, 2019
9baf81e
compilation fix
srpatel19590 Nov 14, 2019
d3b2c4c
Simplified code in database::pay_workers()
abitmore Jul 26, 2018
e7e0816
Merge pull request #116 from peerplays-network/GRPH-81
oxarbitrage Nov 20, 2019
9c1e7af
issue with withdrawl
pbattu123 Nov 21, 2019
ae47eb9
Added unit test for empty account history
srpatel19590 Nov 22, 2019
c17d73f
set extensions default values
srpatel19590 Nov 22, 2019
89a63af
Merge pull request #221 from peerplays-network/feature/GRPH-49-test-case
pbattu123 Nov 22, 2019
df4e045
Merge pull request #218 from peerplays-network/feature/GRPH-150
oxarbitrage Nov 22, 2019
e6d3dd0
Update GPOS hardfork date and don't allow GPOS features before hardfo…
pbattu123 Nov 24, 2019
fd2679a
Merge pull request #223 from peerplays-network/BLOCKBACK-181
pbattu123 Nov 24, 2019
0ecf2e8
Merge pull request #222 from peerplays-network/feature/BLOCKBACK-182
pbattu123 Nov 25, 2019
9b7776e
Merge pull request #220 from peerplays-network/BLOCKBACK-177
pbattu123 Nov 25, 2019
fd23d14
refer to latest commit of latest-fc branch (#224)
pbattu123 Nov 25, 2019
7aeaa14
account name or id support in all database api
srpatel19590 Nov 26, 2019
a5d8a15
asset id or name support in all asset APIs
srpatel19590 Nov 26, 2019
41445a8
Fixed compilation issues
srpatel19590 Nov 26, 2019
ad5707e
Fixed alignment issues
srpatel19590 Nov 28, 2019
6f0ce36
Merge pull request #225 from peerplays-network/feature/GRPH-152
oxarbitrage Nov 28, 2019
4df7298
Externalized some API templates
pmconrad May 10, 2019
71d8bfd
Externalize serialization of blocks, tx, ops
pmconrad May 11, 2019
b3d6058
Externalized db objects
pmconrad May 13, 2019
2358149
Externalized genesis serialization
pmconrad May 14, 2019
8541192
Externalized serialization in protocol library
pmconrad May 19, 2019
25458c2
Undo superfluous change
pmconrad Jun 4, 2019
0b2c9dd
remove default value for extension parameter
pbattu123 Nov 29, 2019
c49ce31
Merge pull request #227 from peerplays-network/GRPH-159
pbattu123 Nov 29, 2019
40c2fd8
fix compilation issues
gladcow Dec 2, 2019
9a9c356
GRPH-46-Quit_command_cliwallet
sierra19XX Aug 28, 2019
e989275
removed multiple function definition
srpatel19590 Dec 3, 2019
3a2def7
Merge pull request #137 from peerplays-network/feature/GRPH-92
oxarbitrage Dec 3, 2019
2dfaa86
Fixed chainparameter update proposal issue
srpatel19590 Dec 5, 2019
38bb922
Move GPOS withdraw logic to have single transaction(also single fee) …
pbattu123 Dec 5, 2019
d5662ad
Added log for authorization failure of proposal operations
srpatel19590 Dec 6, 2019
067fcd1
Votes consideration on GPOS activation
pbattu123 Dec 6, 2019
70b5a94
Merge pull request #90 from peerplays-network/GRPH-46
pbattu123 Dec 6, 2019
3b65288
Merge pull request #232 from peerplays-network/feature/GRPH-166
pbattu123 Dec 6, 2019
e0db302
bump fc version
pbattu123 Dec 6, 2019
91c65b9
Merge pull request #234 from peerplays-network/BLOCKBACK-186
pbattu123 Dec 7, 2019
91e8dca
Merge pull request #239 from peerplays-network/BLOCKCBACK-187
pbattu123 Dec 7, 2019
383b8d0
fix gpos tests
pbattu123 Dec 7, 2019
b5249ac
Bump fc version
pbattu123 Dec 8, 2019
c98c7bc
Updated gpos/voting_tests
pbattu123 Dec 8, 2019
f1fef49
Merge pull request #237 from peerplays-network/BLOCKBACK-183
pbattu123 Dec 9, 2019
b57220a
Fixed withdraw vesting bug
srpatel19590 Dec 12, 2019
e7af03a
Added unit test
srpatel19590 Dec 13, 2019
b1f2ba5
Merge pull request #243 from peerplays-network/feature/BLOCKBACK-186-…
pbattu123 Dec 13, 2019
9746e74
Merge pull request #246 from peerplays-network/develop
pbattu123 Dec 16, 2019
a4d399d
Update hardfork date for TESTNET, sync fc module and update logs
pbattu123 Dec 17, 2019
a7937bf
Merge pull request #248 from peerplays-network/GRPH-170
pbattu123 Dec 17, 2019
26886cc
avoid wlog as it filling up space
pbattu123 Dec 17, 2019
054f06a
Beatrice hot fix(sync issue fix)
pbattu123 Dec 21, 2019
b6fc207
gpos tests fix
pbattu123 Dec 21, 2019
b7cd99c
Merge pull request #253 from peerplays-network/GPOS-1
pbattu123 Dec 23, 2019
d52f9fb
Set hardfork date to Jan5th on TESTNET
pbattu123 Dec 24, 2019
51fd7d1
Merge pull request #255 from peerplays-network/hf-update
pbattu123 Dec 24, 2019
2dbad50
Merge pull request #187 from peerplays-network/support/docker
pbattu123 Feb 12, 2020
08318d0
Merge Elasticplugin, snapshot plugin and graphene updates to beatrice…
pbattu123 Mar 9, 2020
2f03442
sync latest fc commit on beatrice
pbattu123 Mar 9, 2020
dc9cbe6
Merge pull request #305 from peerplays-network/sync_fc_beatrice
pbattu123 Mar 9, 2020
d79cdee
update changes to sync config.hpp, fix conflicts and unit test fixes
pbattu123 Mar 23, 2020
6999bb1
sweeps winner_ticket_id changes
pbattu123 Apr 14, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ WORKDIR /peerplays-core
# Compile Peerplays
RUN \
BOOST_ROOT=$HOME/boost_1_67_0 && \
git submodule sync --recursive && \
git submodule update --init --recursive && \
mkdir build && \
mkdir build/release && \
Expand Down
3 changes: 1 addition & 2 deletions libraries/app/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ add_library( graphene_app
api.cpp
application.cpp
database_api.cpp
impacted.cpp
plugin.cpp
config_util.cpp
${HEADERS}
Expand All @@ -14,7 +13,7 @@ add_library( graphene_app

# need to link graphene_debug_witness because plugins aren't sufficiently isolated #246
#target_link_libraries( graphene_app graphene_market_history graphene_account_history graphene_chain fc graphene_db graphene_net graphene_utilities graphene_debug_witness )
target_link_libraries( graphene_app graphene_market_history graphene_account_history graphene_accounts_list graphene_affiliate_stats graphene_chain fc graphene_db graphene_net graphene_time graphene_utilities graphene_debug_witness graphene_bookie )
target_link_libraries( graphene_app graphene_market_history graphene_account_history graphene_accounts_list graphene_affiliate_stats graphene_chain fc graphene_db graphene_net graphene_time graphene_utilities graphene_debug_witness graphene_bookie graphene_elasticsearch )
target_include_directories( graphene_app
PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}/include"
"${CMAKE_CURRENT_SOURCE_DIR}/../egenesis/include" )
Expand Down
13 changes: 12 additions & 1 deletion libraries/app/api.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@
#include <graphene/app/api.hpp>
#include <graphene/app/api_access.hpp>
#include <graphene/app/application.hpp>
#include <graphene/app/impacted.hpp>
#include <graphene/chain/database.hpp>
#include <graphene/chain/get_config.hpp>
#include <graphene/utilities/key_conversion.hpp>
Expand Down Expand Up @@ -581,6 +580,18 @@ namespace graphene { namespace app {
start = node.operation_id;
} catch(...) { return result; }

if(_app.is_plugin_enabled("elasticsearch")) {
auto es = _app.get_plugin<elasticsearch::elasticsearch_plugin>("elasticsearch");
if(es.get()->get_running_mode() != elasticsearch::mode::only_save) {
if(!_app.elasticsearch_thread)
_app.elasticsearch_thread= std::make_shared<fc::thread>("elasticsearch");

return _app.elasticsearch_thread->async([&es, &account, &stop, &limit, &start]() {
return es->get_account_history(account, stop, limit, start);
}, "thread invoke for method " BOOST_PP_STRINGIZE(method_name)).wait();
}
}

const auto& hist_idx = db.get_index_type<account_transaction_history_index>();
const auto& by_op_idx = hist_idx.indices().get<by_op>();
auto index_start = by_op_idx.begin();
Expand Down
58 changes: 51 additions & 7 deletions libraries/app/application.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -922,7 +922,8 @@ namespace detail {
std::shared_ptr<fc::http::websocket_server> _websocket_server;
std::shared_ptr<fc::http::websocket_tls_server> _websocket_tls_server;

std::map<string, std::shared_ptr<abstract_plugin>> _plugins;
std::map<string, std::shared_ptr<abstract_plugin>> _active_plugins;
std::map<string, std::shared_ptr<abstract_plugin>> _available_plugins;

bool _is_finished_syncing = false;
};
Expand Down Expand Up @@ -964,6 +965,7 @@ void application::set_program_options(boost::program_options::options_descriptio
("enable-standby-votes-tracking", bpo::value<bool>()->implicit_value(true),
"Whether to enable tracking of votes of standby witnesses and committee members. "
"Set it to true to provide accurate data to API clients, set to false for slightly better performance.")
("plugins", bpo::value<string>(), "Space-separated list of plugins to activate")
;
command_line_options.add(configuration_file_options);
command_line_options.add_options()
Expand Down Expand Up @@ -1009,6 +1011,36 @@ void application::initialize(const fc::path& data_dir, const boost::program_opti

std::exit(EXIT_SUCCESS);
}

std::set<string> wanted;
if( options.count("plugins") )
{
boost::split(wanted, options.at("plugins").as<std::string>(), [](char c){return c == ' ';});
}
else
{
wanted.insert("account_history");
wanted.insert("market_history");
wanted.insert("accounts_list");
wanted.insert("affiliate_stats");
}
wanted.insert("witness");
wanted.insert("bookie");

int es_ah_conflict_counter = 0;
for (auto& it : wanted)
{
if(it == "account_history")
++es_ah_conflict_counter;
if(it == "elasticsearch")
++es_ah_conflict_counter;

if(es_ah_conflict_counter > 1) {
elog("Can't start program with elasticsearch and account_history plugin at the same time");
std::exit(EXIT_FAILURE);
}
if (!it.empty()) enable_plugin(it);
}
}

void application::startup()
Expand All @@ -1026,7 +1058,12 @@ void application::startup()

std::shared_ptr<abstract_plugin> application::get_plugin(const string& name) const
{
return my->_plugins[name];
return my->_active_plugins[name];
}

bool application::is_plugin_enabled(const string& name) const
{
return !(my->_active_plugins.find(name) == my->_active_plugins.end());
}

net::node_ptr application::p2p_node()
Expand Down Expand Up @@ -1059,14 +1096,21 @@ bool application::is_finished_syncing() const
return my->_is_finished_syncing;
}

void graphene::app::application::add_plugin(const string& name, std::shared_ptr<graphene::app::abstract_plugin> p)
void graphene::app::application::enable_plugin(const string& name)
{
FC_ASSERT(my->_available_plugins[name], "Unknown plugin '" + name + "'");
my->_active_plugins[name] = my->_available_plugins[name];
my->_active_plugins[name]->plugin_set_app(this);
}

void graphene::app::application::add_available_plugin(std::shared_ptr<graphene::app::abstract_plugin> p)
{
my->_plugins[name] = p;
my->_available_plugins[p->plugin_name()] = p;
}

void application::shutdown_plugins()
{
for( auto& entry : my->_plugins )
for( auto& entry : my->_active_plugins )
entry.second->plugin_shutdown();
return;
}
Expand All @@ -1080,14 +1124,14 @@ void application::shutdown()

void application::initialize_plugins( const boost::program_options::variables_map& options )
{
for( auto& entry : my->_plugins )
for( auto& entry : my->_active_plugins )
entry.second->plugin_initialize( options );
return;
}

void application::startup_plugins()
{
for( auto& entry : my->_plugins )
for( auto& entry : my->_active_plugins )
entry.second->plugin_startup();
return;
}
Expand Down
Loading