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

prepare v3.0.5 to master #142

Merged
merged 34 commits into from
Feb 14, 2020
Merged
Changes from 1 commit
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
87c3227
Merge pull request #125 from boscore/release/3.0.x
Thaipanda Aug 29, 2019
51a0bcc
Merge pull request #130 from boscore/release/3.0.x
Thaipanda Oct 4, 2019
ec710db
Update fc & chainbase to support boost 1.7
Oct 22, 2019
6073b62
Correct cpu_usage calculation when more than one signature
Aug 27, 2019
6bb2e88
Use calculation that avoids possible negative values
Aug 27, 2019
7370bd8
Use new reflect_init tag to indicate reflector_init() should be called
Feb 20, 2019
bcea2f1
Update for boost-1-70-0
May 6, 2019
f41b34d
remove bnet_plugin
Apr 16, 2019
ab570a0
Move json::to_string to http thread pool
Mar 7, 2019
e03c624
Add get_supported_apis rpc api
Jan 8, 2019
8ce1d34
Remove redundant macro
Jan 12, 2019
27c3ff8
Exclude get_supported_apis itself from result
Jan 12, 2019
89c991c
Revert ability to customize name of http_plugin options
Jan 14, 2019
fe3e957
Remove queued HTTP handler registration
Jan 30, 2019
55f38cb
Move json::to_string processing to http thread pool
Mar 7, 2019
05228d9
update to boost 1.7
Oct 25, 2019
c2e10cc
update build script for ubuntu
Oct 25, 2019
e8f3c31
update more build scripts
Oct 29, 2019
43cf809
update chainbase
Oct 30, 2019
1ab3ebf
Merge pull request #136 from boscore/release/3.0.x
Thaipanda Nov 4, 2019
e563c7e
CMakeModules/package.cmake: Update information.
pnx Nov 11, 2019
3345857
Merge pull request #137 from eosswedenorg/bos-pkg-info
Thaipanda Nov 18, 2019
db4d977
fix http_plugin; emit lib;
Nov 22, 2019
00922a7
emit new lib to a separate channel.
Nov 25, 2019
d4a2d7a
Downgrade chainbase
Frank-AFN Feb 4, 2020
3f74e5c
Downgrade cmake to 4.0 and change Dockerfile
Frank-AFN Feb 5, 2020
061784f
rename eosbuilder in docker file
Frank-AFN Feb 5, 2020
1943333
Merge pull request #139 from boscore/develop
Thaipanda Feb 12, 2020
5ac5f0d
Remove chainbase env check
Frank-AFN Feb 12, 2020
e53180d
Modify dockerfile
Frank-AFN Feb 12, 2020
34bf0b5
Merge pull request #141 from eosiosg/update-boost-downgrade-chainbase
Thaipanda Feb 12, 2020
e075d24
adjust for boscore/builder v2.0.4
Thaipanda Feb 12, 2020
67fbc95
prepare to release v3.0.5
Thaipanda Feb 13, 2020
6ab5c6e
update the document. Using technology to create a trusted business ec…
Thaipanda Feb 13, 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
Prev Previous commit
Next Next commit
Use calculation that avoids possible negative values
(cherry picked from commit 92065bd)
  • Loading branch information
vince authored and VincentOCL committed Oct 25, 2019
commit 6bb2e8832696b6d25bcaf3f78c91a50cc261c5e2
11 changes: 6 additions & 5 deletions libraries/chain/transaction.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -99,18 +99,19 @@ fc::microseconds transaction::get_signature_keys( const vector<signature_type>&

std::unique_lock<std::mutex> lock(cache_mtx, std::defer_lock);
fc::microseconds sig_cpu_usage;
const auto digest_time = fc::time_point::now() - start;
for(const signature_type& sig : signatures) {
auto now = fc::time_point::now();
EOS_ASSERT( now < deadline, tx_cpu_usage_exceeded, "transaction signature verification executed for too long",
("now", now)("deadline", deadline)("start", start) );
auto sig_start = fc::time_point::now();
EOS_ASSERT( sig_start < deadline, tx_cpu_usage_exceeded, "transaction signature verification executed for too long",
("now", sig_start)("deadline", deadline)("start", start) );
public_key_type recov;
const auto& tid = id();
lock.lock();
recovery_cache_type::index<by_sig>::type::iterator it = recovery_cache.get<by_sig>().find( sig );
if( it == recovery_cache.get<by_sig>().end() || it->trx_id != tid ) {
lock.unlock();
recov = public_key_type( sig, digest );
fc::microseconds cpu_usage = fc::time_point::now() - start - sig_cpu_usage;
fc::microseconds cpu_usage = fc::time_point::now() - sig_start;
lock.lock();
recovery_cache.emplace_back( cached_pub_key{tid, recov, sig, cpu_usage} ); //could fail on dup signatures; not a problem
sig_cpu_usage += cpu_usage;
Expand All @@ -131,7 +132,7 @@ fc::microseconds transaction::get_signature_keys( const vector<signature_type>&
recovery_cache.erase( recovery_cache.begin());
lock.unlock();

return sig_cpu_usage;
return sig_cpu_usage + digest_time;
} FC_CAPTURE_AND_RETHROW() }


Expand Down