Skip to content

TransmissionNetworkOutput loops forever if encountering java.lang.IllegalStateException #406

@andresol

Description

@andresol

When using tomcat with autoDeploy TransmissionNetworkOutput goes into a forever loop when encountering a IllegalStateException. I have created a fix with pull req. #405

org.apache.catalina.loader.WebappClassLoaderBase.checkStateForResourceLoading Illegal access: this web application instance has been stopped already. Could not load [com.microsoft.applicationinsights.core.dependencies.http.pool.PoolStats]. The following stack trace is thrown for debugging purposes as well as to attempt to terminate the thread which caused the illegal access.
  #java.lang.IllegalStateException: Illegal access: this web application instance has been stopped already. Could not load [com.microsoft.applicationinsights.core.dependencies.http.pool.PoolStats]. The following stack trace is thrown for debugging purposes as well as to attempt to terminate the thread which caused the illegal access.
	at org.apache.catalina.loader.WebappClassLoaderBase.checkStateForResourceLoading(WebappClassLoaderBase.java:1354)
	at org.apache.catalina.loader.WebappClassLoaderBase.checkStateForClassLoading(WebappClassLoaderBase.java:1340)
	at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1205)
	at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1166)
	at com.microsoft.applicationinsights.core.dependencies.http.pool.AbstractConnPool.getTotalStats(AbstractConnPool.java:508)
	at com.microsoft.applicationinsights.core.dependencies.http.impl.conn.PoolingHttpClientConnectionManager.formatStats(PoolingHttpClientConnectionManager.java:228)
	at com.microsoft.applicationinsights.core.dependencies.http.impl.conn.PoolingHttpClientConnectionManager.requestConnection(PoolingHttpClientConnectionManager.java:255)
	at com.microsoft.applicationinsights.core.dependencies.http.impl.execchain.MainClientExec.execute(MainClientExec.java:176)
	at com.microsoft.applicationinsights.core.dependencies.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:185)
	at com.microsoft.applicationinsights.core.dependencies.http.impl.execchain.RetryExec.execute(RetryExec.java:89)
	at com.microsoft.applicationinsights.core.dependencies.http.impl.execchain.RedirectExec.execute(RedirectExec.java:111)
	at com.microsoft.applicationinsights.core.dependencies.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:185)
	at com.microsoft.applicationinsights.core.dependencies.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:83)
	at com.microsoft.applicationinsights.core.dependencies.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:108)
	at com.microsoft.applicationinsights.internal.channel.common.ApacheSender43.sendPostRequest(ApacheSender43.java:57)
	at com.microsoft.applicationinsights.internal.channel.common.TransmissionNetworkOutput.send(TransmissionNetworkOutput.java:142)
	at com.microsoft.applicationinsights.internal.channel.common.ActiveTransmissionNetworkOutput$2.run(ActiveTransmissionNetworkOutput.java:87)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions