SmartHomeApp.reportState error
See original GitHub issueIs this error below because the grpc-core version is too low?
io.grpc.internal.ManagedChannelOrphanWrapper line:163 -*~*~*~ Channel ManagedChannelImpl{logId=144961, target=homegraph.googleapis.com} was not shutdown properly!!! ~*~*~*
Make sure to call shutdown()/shutdownNow() and wait until awaitTermination() returns true.
java.lang.RuntimeException: ManagedChannel allocation site
at io.grpc.internal.ManagedChannelOrphanWrapper$ManagedChannelReference.<init>(ManagedChannelOrphanWrapper.java:103) [grpc-core-1.15.1.jar:1.15.1]
at io.grpc.internal.ManagedChannelOrphanWrapper.<init>(ManagedChannelOrphanWrapper.java:53) [grpc-core-1.15.1.jar:1.15.1]
at io.grpc.internal.ManagedChannelOrphanWrapper.<init>(ManagedChannelOrphanWrapper.java:44) [grpc-core-1.15.1.jar:1.15.1]
at io.grpc.internal.AbstractManagedChannelImplBuilder.build(AbstractManagedChannelImplBuilder.java:410) [grpc-core-1.15.1.jar:1.15.1]
at com.google.actions.api.smarthome.SmartHomeApp.reportState(SmartHomeApp.kt:126) [actions-on-google-1.5.0.jar:?]
Issue Analytics
- State:
- Created 4 years ago
- Comments:32 (11 by maintainers)
Top Results From Across the Web
SmartHomeApp: reportState on Java always returning ...
I'm guessing the problem is that I'm not passing the device name or any device identifier, but it doesn't seems to have an...
Read more >Report State | Cloud-to-cloud - Google Home Developers
Prerequisites; Deploy the Report State dashboard. Error Responses. Key Point: You must implement Report State in order to submit a smart ...
Read more >Understand State and Change Reporting | Alexa Skills Kit
You report state to Alexa in three ways: Alexa requests the state with an Alexa.ReportState directive. For example, a customer opens the Alexa...
Read more >actions-on-google@3.0.0 - jsDocs.io
SmartHome; SmartHomeApp ... HTTP Code 403 will be thrown by default on verification error. ... This is used for report state.
Read more >App | Local Home SDK | Actions on Google Smart Home
import App = smarthome.App; const localHomeApp: App = new App("1.0.0"); localHomeApp .onIdentify(identifyHandler) .
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Sorry for not seeing the @mention earlier.
It seems that
action-on-google-java
creates a newManagedChannel
on every request: https://github.com/actions-on-google/actions-on-google-java/blob/master/src/main/kotlin/com/google/actions/api/smarthome/SmartHomeApp.kt#L126As pointed by @cbeaujoin in https://github.com/actions-on-google/actions-on-google-java/issues/30#issuecomment-529400776 and comments in the official gRPC sample for Java: https://github.com/grpc/grpc-java/blob/master/examples/src/main/java/io/grpc/examples/helloworld/HelloWorldClient.java#L96 such channels should be explicitly shutdown when no longer being used to prevent leaks.
A workaround could be for client to directly depends on the
HomeGraph API Client Library for Java
https://github.com/googleapis/google-api-java-client-services/tree/master/clients/google-api-services-homegraph/v1 instead of using thereportState
helper and reuse a single channel tied to the lifetime of the application.@Fleker Hi,how is this issue?it’s a long time.