question

Lech Migdal avatar image
Lech Migdal asked

I/AmazonInsightsSDK﹕ Failed submission of X events

Hi, I am getting interesting behaviour of AmazonInsights. Everything seems to be fine on a first glance, but then in the onPause when events should be submitted I see information that the events weren't submitted: I/AmazonInsightsSDK﹕ Amazon Insights SDK(2.1.16.0) initialization successfully completed I/AmazonInsightsSDK﹕ Event: '_sess...' recorded to local filestore I/AmazonInsightsSDK﹕ Event: '_http...' recorded to local filestore I/AmazonInsightsSDK﹕ Session Resume Failed: Session is already running. I/AmazonInsightsSDK﹕ Session Paused. I/AmazonInsightsSDK﹕ Event: '_sess...' recorded to local filestore I/AmazonInsightsSDK﹕ Failed submission of 3 events No other errors or information. AmazonInsights are initialised in a standard manner: InsightsCredentials credentials = AmazonInsights.newCredentials(Globals.AMAZON_INSIGHT_APP_ID, Globals.AMAZON_INSIGHT_KEY); InsightsOptions options = AmazonInsights.newOptions(true, true); insightsInstance = AmazonInsights.newInstance(credentials, getApplicationContext(), options); It is tested on two devices (one smartphone, one tablet), both on wifi. As you can imagine I am not getting any info in the reports ;-) Any suggestions what I should check to make it work are more than appreciated :) Thank you, Leszek
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Lech Migdal avatar image
Lech Migdal answered
Problem solved - apparently the APP_KEY mentioned in the Android GettingStarted isn't the App Identifier mentioned in the step 1, but App PUBLIC_KEY. Thank you for this blog - https://developer.amazon.com/public/community/post/TxKJA6Q6PDW4E8/-span-class-matches-Analytics-span-and-A-span-class-matches-B-span-span-class-ma You may want to update the Analytics setup article to make it clear. Kind regards, Leszek
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Sujoy@Amazon avatar image
Sujoy@Amazon answered
Thanks for sharing the problem and solution. This may also occur when the SDK can't communicate with our service, which can be caused by restrictive firewall settings on the developers end, or having a wifi signal but no connection to the internet. There are a couple things the developer can try to troubleshoot this and narrow down the cause: 1. Try submitting the events over 3G or non-wifi connection. This will show if the problem is limited to Wifi submission only. 2. While on Wifi try navigating to https://applab-sdk.amazon.com/1.0/applications/YOUR_PUBLIC_KEY in the devices browser. You should see "The signature was not present on the request". If you do not see this message there is likely a connection issue on the device or on their network, such as being blocked by a firewall
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.