iroha GitHub

PR #996 Network timeout fix
iroha2 Signed-off-by: i1i1 <vanyarybin1@live.ru> ### Description of the Change Add compilation feature for opting test timeout for tests. ### Benefits No timeouts for tests. ### Possible Drawbacks ### Usage Examples or Tests *[optional]* ### Alternate Designs *[optional]*
Created At 2021-04-27 08:20:02 +0000 UTC
PR #995 Refactor/remove rxcpp
- SE field in Irohad class - Remove rxcpp from TransactionProcessorImpl - Use any_range in BlockLoader interface
Created At 2021-04-26 19:27:32 +0000 UTC
PR #994 #826 Fix grpc msg size
# The problem iroha freezes inside GRPC when waiting response to a big (more than 4MB) message. # Steps to reproduce Send long transactions batch (more than 250) ``` from iroha import * def public_key_from_private(private_key: str): return IrohaCrypto.derive_public_key(private_key).decode('utf-8') def send_signed_batch_transaction(txs, net): net.send_txs(txs) for tx in txs: print(f'Transaction hash = {calculate_hash_of_transaction(tx)}') for status_name, status_code, error_code in net.tx_status_stream(tx, timeout=20): print(f'\tstatus_name:{status_name}, status_code:{status_code}, error_code:{error_code}') def calculate_hash_of_transaction(transaction_with_payload): h = IrohaCrypto.hash(transaction_with_payload) return binascii.hexlify(h).decode("utf-8") if __name__ == '__main__': IROHA_HOST_ADDR = os.getenv('IROHA_HOST_ADDR', 'localhost') IROHA_PORT = os.getenv('IROHA_PORT', '50051') ADMIN_ACCOUNT_ID = os.getenv('ADMIN_ACCOUNT_ID', 'admin@test') ADMIN_PRIVATE_KEY = os.getenv('ADMIN_PRIVATE_KEY', 'f101537e319568c765b2cc89698325604991dca57b9716b58016b253506cab70') iroha = Iroha(ADMIN_ACCOUNT_ID) net = IrohaGrpc(f'{IROHA_HOST_ADDR}:{IROHA_PORT}',max_message_length=400*1024*1024) new_user_private_key = '1234567890123456789012345678901234567890123456789012345678901234' new_user_public_key = public_key_from_private(new_user_private_key) accounts_to_create = 250 txs = [] for i in range(accounts_to_create): txs.append( iroha.transaction([ iroha.command('CreateAccount', account_name=f'1p_account_{i}', domain_id='test', public_key=new_user_public_key) ])) iroha.batch(txs, atomic=False) for tx in txs: IrohaCrypto.sign_transaction(tx, ADMIN_PRIVATE_KEY) send_signed_batch_transaction(txs, net) ``` After this iroha freezes and python script results with ``` status = StatusCode.DEADLINE_EXCEEDED details = "Deadline Exceeded" debug_error_string = "{"created":"@1619454477.951686000","description":"Error received from peer ipv6:[::1]:50051","file":"src/core/lib/surface/call.cc","file_line":1068,"grpc_message":"Deadline Exceeded","grpc_status":4}" ``` # Result after fix > Received message larger than max (4207140 vs. 4194304) ``` > python3 batch_test.py Traceback (most recent call last): File "/batch_test.py", line 47, in send_signed_batch_transaction(txs, net) File "/batch_test.py", line 9, in send_signed_batch_transaction net.send_txs(txs) File "/usr/local/lib/python3.9/site-packages/iroha/iroha.py", line 396, in send_txs self._command_service_stub.ListTorii(tx_list, timeout=timeout) File "/usr/local/lib/python3.9/site-packages/grpc/_channel.py", line 923, in __call__ return _end_unary_response_blocking(state, call, False, None) File "/usr/local/lib/python3.9/site-packages/grpc/_channel.py", line 826, in _end_unary_response_blocking raise _InactiveRpcError(state) grpc._channel._InactiveRpcError: <_InactiveRpcError of RPC that terminated with: status = StatusCode.RESOURCE_EXHAUSTED details = "Received message larger than max (4207140 vs. 4194304)" debug_error_string = "{"created":"@1619454844.395104000","description":"Error received from peer ipv6:[::1]:50051","file":"src/core/lib/surface/call.cc","file_line":1068,"grpc_message":"Received message larger than max (4207140 vs. 4194304)","grpc_status":8}" > ``` </td> </tr> </table>
Created At 2021-04-26 16:37:04 +0000 UTC
</div>
PR #993 Bump version of async-std to 1.9.0
iroha2 Bump version of async-std to 1.9.0 Signed-off-by: i1i1 <vanyarybin1@live.ru> ### Description of the Change ### Benefits ### Possible Drawbacks ### Usage Examples or Tests *[optional]* ### Alternate Designs *[optional]*
Created At 2021-04-26 14:55:10 +0000 UTC
PR #992 Feature/[SE] scheduler
### Description of the Change Added scheduler with execution thread loop. Can be used to manage your own process loop in a current thread. ### Benefits ### Possible Drawbacks ### Usage Examples or Tests *[optional]* ### Alternate Designs *[optional]*
Created At 2021-04-26 12:32:59 +0000 UTC
PR #991 Update dockerfile for caching and faster ci builds
iroha2 https://jira.hyperledger.org/browse/IR-1075 Signed-off-by: i1i1 <vanyarybin1@live.ru> ### Description of the Change Rewrite of Dockerfile and removal of the various dockerfiles. ### Benefits Easier to maintain 1 dockerfile. Faster ci builds via caching of dependencies. ### Possible Drawbacks ### Usage Examples or Tests *[optional]* ### Alternate Designs *[optional]*
Created At 2021-04-24 15:42:08 +0000 UTC
PR #990 Fixup health endpoint
iroha2 https://jira.hyperledger.org/browse/IR-1076 Signed-off-by: i1i1 <vanyarybin1@live.ru> ### Description of the Change Fixup health endpoint. Now it responds with nice text output with current status of peer. Updated some of the libraries like heim. Heim is now of version 0.1.0-rc.1 unfortunately 0.0 version doesn't support aarch64 which is in tier 1 support list for rust toolchain. ### Benefits ### Possible Drawbacks ### Usage Examples or Tests *[optional]* ### Alternate Designs *[optional]*
Created At 2021-04-23 08:06:09 +0000 UTC
PR #989 Update libssl version
iroha2 ### Description of the Change Updating package name because of ubuntu naming. ### Benefits ### Possible Drawbacks ### Usage Examples or Tests *[optional]* ### Alternate Designs *[optional]*
Created At 2021-04-22 09:52:32 +0000 UTC
PR #988 Add push docker images from dev branch
iroha2 Signed-off-by: i1i1 <vanyarybin1@live.ru> ### Description of the Change Add push docker images from dev branch ### Benefits Faster iterations on test stand. ### Possible Drawbacks ### Usage Examples or Tests *[optional]* ### Alternate Designs *[optional]*
Created At 2021-04-22 09:19:17 +0000 UTC