Skip to content

add more debug when http message parsing fails#80709

Merged
CheSema merged 1 commit intomasterfrom
chesema-debug-tttp-responce
May 23, 2025
Merged

add more debug when http message parsing fails#80709
CheSema merged 1 commit intomasterfrom
chesema-debug-tttp-responce

Conversation

@CheSema
Copy link
Copy Markdown
Member

@CheSema CheSema commented May 22, 2025

Changelog category (leave one):

  • Not for changelog (changelog entry is not required)

Changelog entry (a user-readable short description of the changes that goes to CHANGELOG.md):

add more debug info when http message header parsing fails

Documentation entry for user-facing changes

  • Documentation is written (mandatory for new features)

@clickhouse-gh
Copy link
Copy Markdown
Contributor

clickhouse-gh bot commented May 22, 2025

Workflow [PR], commit [0ea067d]

@clickhouse-gh clickhouse-gh bot added the pr-not-for-changelog This PR should not be mentioned in the changelog label May 22, 2025
@CheSema
Copy link
Copy Markdown
Member Author

CheSema commented May 22, 2025

It was noticed that there could be such exception when clickhouse communicate with itself.

2025-05-22 01:47:39 Reason: return code:  232
2025-05-22 01:47:39 [549686e2d6a6] 2025.05.22 11:47:39.070864 [ 34868 ] {374d79b0-d385-4cbb-baff-e2fe3a5d7b62} <Error> executeQuery: Code: 1000. DB::Exception: Syntax error: Not a valid integer: 'is'. (POCO_EXCEPTION) (version 25.6.1.667 (official build)) (from [::1]:51300) (comment: 03519_storage_url.sh) (query 1, line 2) (in query: insert into src values ), Stack trace (when copying this message, always include the lines below):
2025-05-22 01:47:39 
2025-05-22 01:47:39 0. ./contrib/llvm-project/libcxx/include/__exception/exception.h:113: Poco::Exception::Exception(String const&, String const&, int) @ 0x0000000021c67d43
2025-05-22 01:47:39 1. ./ci/tmp/build/./base/poco/Foundation/src/Exception.cpp:145: Poco::SyntaxException::SyntaxException(String const&, String const&, int) @ 0x0000000021c771d1
2025-05-22 01:47:39 2. ./ci/tmp/build/./base/poco/Foundation/src/NumberParser.cpp:44: Poco::NumberParser::parse(String const&, char) @ 0x0000000021cc5765
2025-05-22 01:47:39 3. ./ci/tmp/build/./base/poco/Net/src/HTTPResponse.cpp:156: Poco::Net::HTTPResponse::read(std::basic_istream<char, std::char_traits<char>>&) @ 0x0000000021d3b561
2025-05-22 01:47:39 4. ./ci/tmp/build/./base/poco/Net/src/HTTPClientSession.cpp:357: Poco::Net::HTTPClientSession::receiveResponse(Poco::Net::HTTPResponse&) @ 0x0000000021d1fcf7
2025-05-22 01:47:39 5. ./ci/tmp/build/./src/Common/HTTPConnectionPool.cpp:415: DB::EndpointConnectionPool<Poco::Net::HTTPClientSession>::PooledConnection::receiveResponse(Poco::Net::HTTPResponse&) @ 0x0000000011d6b2c5
2025-05-22 01:47:39 6. ./ci/tmp/build/./src/IO/HTTPCommon.cpp:71: DB::receiveResponse(Poco::Net::HTTPClientSession&, Poco::Net::HTTPRequest const&, Poco::Net::HTTPResponse&, bool) @ 0x0000000011d7a575
2025-05-22 01:47:39 7. ./ci/tmp/build/./src/IO/WriteBufferFromHTTP.cpp:63: DB::WriteBufferFromHTTP::finalizeImpl() @ 0x0000000011d797fc
2025-05-22 01:47:39 8. ./ci/tmp/build/./src/IO/WriteBuffer.cpp:95: DB::WriteBuffer::finalize() @ 0x0000000011a26bfb
2025-05-22 01:47:39 9. ./ci/tmp/build/./src/Storages/StorageURL.cpp:684: DB::StorageURLSink::finalizeBuffers() @ 0x000000001bd2985b
2025-05-22 01:47:39 10. ./ci/tmp/build/./src/Storages/StorageURL.cpp:663: DB::StorageURLSink::onFinish() @ 0x000000001bd2973b
2025-05-22 01:47:39 11. ./ci/tmp/build/./src/Processors/Transforms/ExceptionKeepingTransform.cpp:172: void std::__function::__policy_invoker<void ()>::__call_impl[abi:ne190107]<std::__function::__default_alloc_func<DB::ExceptionKeepingTransform::work()::$_3, void ()>>(std::__function::__policy_storage const*) @ 0x000000001cfc58b1
2025-05-22 01:47:39 12. ./contrib/llvm-project/libcxx/include/__functional/function.h:716: ? @ 0x000000001cfc52f4
2025-05-22 01:47:39 13. ./ci/tmp/build/./src/Processors/Transforms/ExceptionKeepingTransform.cpp:172: DB::ExceptionKeepingTransform::work() @ 0x000000001cfc4d65
2025-05-22 01:47:39 14. ./ci/tmp/build/./src/Processors/Executors/ExecutionThreadContext.cpp:53: DB::ExecutionThreadContext::executeTask() @ 0x000000001cc1f452
2025-05-22 01:47:39 15. ./ci/tmp/build/./src/Processors/Executors/PipelineExecutor.cpp:305: DB::PipelineExecutor::executeStepImpl(unsigned long, std::atomic<bool>*) @ 0x000000001cc0e52f
2025-05-22 01:47:39 16. ./ci/tmp/build/./src/Processors/Executors/PipelineExecutor.cpp:275: void std::__function::__policy_invoker<void ()>::__call_impl[abi:ne190107]<std::__function::__default_alloc_func<DB::PipelineExecutor::spawnThreadsImpl(std::shared_ptr<DB::IAcquiredSlot>)::$_0, void ()>>(std::__function::__policy_storage const*) @ 0x000000001cc0f594
2025-05-22 01:47:39 17. ./contrib/llvm-project/libcxx/include/__functional/function.h:716: ? @ 0x0000000011a8777b
2025-05-22 01:47:39 18. ./contrib/llvm-project/libcxx/include/__type_traits/invoke.h:117: ThreadFromGlobalPoolImpl<false, true>::ThreadFromGlobalPoolImpl<void (ThreadPoolImpl<ThreadFromGlobalPoolImpl<false, true>>::ThreadFromThreadPool::*)(), ThreadPoolImpl<ThreadFromGlobalPoolImpl<false, true>>::ThreadFromThreadPool*>(void (ThreadPoolImpl<ThreadFromGlobalPoolImpl<false, true>>::ThreadFromThreadPool::*&&)(), ThreadPoolImpl<ThreadFromGlobalPoolImpl<false, true>>::ThreadFromThreadPool*&&)::'lambda'()::operator()() @ 0x0000000011a8fdc6
2025-05-22 01:47:39 19. ./contrib/llvm-project/libcxx/include/__type_traits/invoke.h:149: void std::__function::__policy_invoker<void ()>::__call_impl[abi:ne190107]<std::__function::__default_alloc_func<ThreadFromGlobalPoolImpl<false, true>::ThreadFromGlobalPoolImpl<void (ThreadPoolImpl<ThreadFromGlobalPoolImpl<false, true>>::ThreadFromThreadPool::*)(), ThreadPoolImpl<ThreadFromGlobalPoolImpl<false, true>>::ThreadFromThreadPool*>(void (ThreadPoolImpl<ThreadFromGlobalPoolImpl<false, true>>::ThreadFromThreadPool::*&&)(), ThreadPoolImpl<ThreadFromGlobalPoolImpl<false, true>>::ThreadFromThreadPool*&&)::'lambda'(), void ()>>(std::__function::__policy_storage const*) @ 0x0000000011a8fce2
2025-05-22 01:47:39 20. ./contrib/llvm-project/libcxx/include/__functional/function.h:716: ? @ 0x0000000011a83d23
2025-05-22 01:47:39 21. ./contrib/llvm-project/libcxx/include/__type_traits/invoke.h:117: void* std::__thread_proxy[abi:ne190107]<std::tuple<std::unique_ptr<std::__thread_struct, std::default_delete<std::__thread_struct>>, void (ThreadPoolImpl<std::thread>::ThreadFromThreadPool::*)(), ThreadPoolImpl<std::thread>::ThreadFromThreadPool*>>(void*) @ 0x0000000011a8ca7c
2025-05-22 01:47:39 22. __tsan_thread_start_func @ 0x000000000889a428
2025-05-22 01:47:39 23. ? @ 0x00007f62db400ac3
2025-05-22 01:47:39 24. ? @ 0x00007f62db492850
2025-05-22 01:47:39 
2025-05-22 01:47:39 Received exception from server (version 25.6.1):
2025-05-22 01:47:39 Code: 1000. DB::Exception: Received from localhost:9000. DB::Exception: Syntax error: Not a valid integer: 'is'. (POCO_EXCEPTION)
2025-05-22 01:47:39 (query: insert into src values (1, 0), (2, 1), (3, 0), (4, 1);)
2025-05-22 01:47:39 
2025-05-22 01:47:39 /repo/tests/queries/0_stateless/test_ay4bgeut/03519_storage_url.sh.debuglog:
2025-05-22 01:47:39 + [2025-05-22 01:47:37] [:7] set -eu
2025-05-22 01:47:39 + [2025-05-22 01:47:37] [:9] /usr/bin/clickhouse-client --send_logs_level=warning --database=test_ay4bgeut --log_comment 03519_storage_url.sh --max_insert_threads 2 --group_by_two_level_threshold 675326 --group_by_two_level_threshold_bytes 1 --distributed_aggregation_memory_efficient 0 --fsync_metadata 0 --output_format_parallel_formatting 1 --input_format_parallel_parsing 0 --min_chunk_bytes_for_parallel_parsing 5467050 --max_read_buffer_size 850167 --prefer_localhost_replica 1 --max_block_size 31088 --max_joined_block_size_rows 27438 --max_threads 2 --optimize_append_index 1 --use_hedged_requests 1 --optimize_if_chain_to_multiif 1 --optimize_if_transform_strings_to_enum 0 --optimize_read_in_order 0 --optimize_or_like_chain 1 --optimize_substitute_columns 0 --enable_multiple_prewhere_read_steps 1 --read_in_order_two_level_merge_threshold 63 --optimize_aggregation_in_order 0 --aggregation_in_order_max_block_bytes 39038719 --use_uncompressed_cache 1 --min_bytes_to_use_direct_io 10737418240 --min_bytes_to_use_mmap_io 9068540771 --local_filesystem_read_method mmap --remote_filesystem_read_method threadpool --local_filesystem_read_prefetch 0 --filesystem_cache_segments_batch_size 50 --read_from_filesystem_cache_if_exists_otherwise_bypass_cache 1 --throw_on_error_from_cache_on_write_operations 0 --remote_filesystem_read_prefetch 0 --allow_prefetched_read_pool_for_remote_filesystem 1 --filesystem_prefetch_max_memory_usage 64Mi --filesystem_prefetches_limit 0 --filesystem_prefetch_min_bytes_for_single_read_task 8Mi --filesystem_prefetch_step_marks 0 --filesystem_prefetch_step_bytes 100Mi --compile_expressions 1 --compile_aggregate_expressions 1 --compile_sort_description 0 --merge_tree_coarse_index_granularity 13 --optimize_distinct_in_order 0 --max_bytes_before_remerge_sort 48562569 --min_compress_block_size 2188113 --max_compress_block_size 781253 --merge_tree_compact_parts_min_granules_to_multibuffer_read 11 --optimize_sorting_by_input_stream_properties 0 --http_response_buffer_size 10167657 --http_wait_end_of_query False --enable_memory_bound

@CheSema CheSema force-pushed the chesema-debug-tttp-responce branch from be35c6d to 0ea067d Compare May 22, 2025 17:01
@tuanpach tuanpach self-assigned this May 22, 2025
@CheSema CheSema added this pull request to the merge queue May 23, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to no response for status checks May 23, 2025
@CheSema CheSema added this pull request to the merge queue May 23, 2025
Merged via the queue into master with commit e96a664 May 23, 2025
119 of 121 checks passed
@CheSema CheSema deleted the chesema-debug-tttp-responce branch May 23, 2025 11:12
@robot-ch-test-poll robot-ch-test-poll added the pr-synced-to-cloud The PR is synced to the cloud repo label May 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-not-for-changelog This PR should not be mentioned in the changelog pr-synced-to-cloud The PR is synced to the cloud repo

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants