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

core: crash on runtime load on destruction #674

Closed
junr03 opened this issue Feb 10, 2020 · 1 comment · Fixed by #663
Closed

core: crash on runtime load on destruction #674

junr03 opened this issue Feb 10, 2020 · 1 comment · Fixed by #663
Assignees
Labels

Comments

@junr03
Copy link
Member

junr03 commented Feb 10, 2020


0  libsystem_kernel.dylib  ___pthread_kill
1  libsystem_pthread.dylib _pthread_kill
2  libsystem_c.dylib       _abort
3  Lyft                    Envoy::Runtime::LoaderImpl::snapshot() (Lyft)
4  Lyft                    Envoy::Upstream::ResourceManagerImpl::ResourceImpl::max() (Lyft)
5  Lyft                    Envoy::Upstream::ResourceManagerImpl::ResourceImpl::decBy(unsigned long long) (Lyft)
6  Lyft                    Envoy::Extensions::HttpFilters::DynamicForwardProxy::ProxyFilter::~ProxyFilter() (Lyft)
7  Lyft                    Envoy::Http::ConnectionManagerImpl::ActiveStreamDecoderFilter::~ActiveStreamDecoderFilter() (Lyft)
8  Lyft                    Envoy::Http::ConnectionManagerImpl::ActiveStream::~ActiveStream() (Lyft)
9  Lyft                    Envoy::Http::ConnectionManagerImpl::ActiveStream::~ActiveStream() (Lyft)
10 Lyft                    Envoy::Http::ConnectionManagerImpl::~ConnectionManagerImpl() (Lyft)
11 Lyft                    non-virtual thunk to Envoy::Http::ConnectionManagerImpl::~ConnectionManagerImpl() (Lyft)
12 Lyft                    Envoy::Server::HttpApiListener::~HttpApiListener() (Lyft)
13 Lyft                    Envoy::Server::ListenerManagerImpl::~ListenerManagerImpl() (Lyft)
14 Lyft                    Envoy::Server::ListenerManagerImpl::~ListenerManagerImpl() (Lyft)
15 Lyft                    Envoy::Server::InstanceImpl::~InstanceImpl() (Lyft)
16 Lyft                    Envoy::Server::InstanceImpl::~InstanceImpl() (Lyft)
17 Lyft                    Envoy::MainCommonBase::~MainCommonBase() (Lyft)
18 Lyft                    Envoy::Engine::run(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) (Lyft)
19 Lyft                    void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, envoy_status_t (Envoy::Engine::*)(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >), Envoy::Engine*, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > >(void*) (Lyft)
20 libsystem_pthread.dylib __pthread_start```

The assertion tripped is https://github.com/envoyproxy/envoy/blob/ea65c4e935e6af4eef75d39c1e03b9a64ac30d70/source/common/runtime/runtime_impl.cc#L634

This is happening because the ApiListener is being destroyed after the tls has been cleaned up for the main thread, and the assertion relies on TLS size being non-zero to define the thread as registered.
@junr03
Copy link
Member Author

junr03 commented Feb 10, 2020

Fixed by envoyproxy/envoy#9959. Needs Envoy Mobile Envoy ref bump to incorporate #663

@junr03 junr03 self-assigned this Feb 10, 2020
@junr03 junr03 added this to the v0.3 "Secondi" milestone Feb 10, 2020
@junr03 junr03 added the crash label Feb 10, 2020
rebello95 added a commit that referenced this issue Feb 10, 2020
Bumping to include the following fixes:
- `dns: destroy/reinitialize c-ares channel on ARES_ECONNREFUSED`: envoyproxy/envoy#9899. This should resolve the issues we've been seeing with Envoy Mobile hanging on startup and never properly issuing requests if started in the offline state on iOS. Fixes #672, though more improvements to DNS resolution will be investigated in #673
- `gzip: add force load factory declaration`: envoyproxy/envoy#9942. This will allow us to use the gzip filter with Envoy Mobile
- `api listener: add shutdown method and call during server termination`: envoyproxy/envoy#9959. Fixes #667. Fixes #674

Includes the following PRs to fix iOS liveliness tests as well:
- `metrics service: force link v2 config`: envoyproxy/envoy#9875
- `config: remove ApiTypeOracle assert`: envoyproxy/envoy#9973

Also contains necessary updates to accommodate [this change](envoyproxy/envoy@dea4eb0).

Signed-off-by: Michael Rebello <me@michaelrebello.com>
jpsim pushed a commit to envoyproxy/envoy that referenced this issue Nov 28, 2022
Bumping to include the following fixes:
- `dns: destroy/reinitialize c-ares channel on ARES_ECONNREFUSED`: #9899. This should resolve the issues we've been seeing with Envoy Mobile hanging on startup and never properly issuing requests if started in the offline state on iOS. Fixes envoyproxy/envoy-mobile#672, though more improvements to DNS resolution will be investigated in envoyproxy/envoy-mobile#673
- `gzip: add force load factory declaration`: #9942. This will allow us to use the gzip filter with Envoy Mobile
- `api listener: add shutdown method and call during server termination`: #9959. Fixes envoyproxy/envoy-mobile#667. Fixes envoyproxy/envoy-mobile#674

Includes the following PRs to fix iOS liveliness tests as well:
- `metrics service: force link v2 config`: #9875
- `config: remove ApiTypeOracle assert`: #9973

Also contains necessary updates to accommodate [this change](dea4eb0).

Signed-off-by: Michael Rebello <me@michaelrebello.com>
Signed-off-by: JP Simard <jp@jpsim.com>
jpsim pushed a commit to envoyproxy/envoy that referenced this issue Nov 29, 2022
Bumping to include the following fixes:
- `dns: destroy/reinitialize c-ares channel on ARES_ECONNREFUSED`: #9899. This should resolve the issues we've been seeing with Envoy Mobile hanging on startup and never properly issuing requests if started in the offline state on iOS. Fixes envoyproxy/envoy-mobile#672, though more improvements to DNS resolution will be investigated in envoyproxy/envoy-mobile#673
- `gzip: add force load factory declaration`: #9942. This will allow us to use the gzip filter with Envoy Mobile
- `api listener: add shutdown method and call during server termination`: #9959. Fixes envoyproxy/envoy-mobile#667. Fixes envoyproxy/envoy-mobile#674

Includes the following PRs to fix iOS liveliness tests as well:
- `metrics service: force link v2 config`: #9875
- `config: remove ApiTypeOracle assert`: #9973

Also contains necessary updates to accommodate [this change](dea4eb0).

Signed-off-by: Michael Rebello <me@michaelrebello.com>
Signed-off-by: JP Simard <jp@jpsim.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant