API having issue with Shopify SSL Verification

Highlighted
Tourist
9 0 4

Hi I have noticed since last night around 4 AM est that our server is having an issue connecting to Shopify API for all the stores we integrate with and it seems to be hanging when trying to verify ssl via cURL.

 

It is random too, on one product inventory sync it is fine then the next it might hang.

Here is an example of a cURL log that is errors and below that one that connects fine.

 

* Hostname was found in DNS cache
* Trying 23.227.38.64...
* Connected to ibeauty1.myshopify.com (23.227.38.64) port 443 (#69)
* successfully set certificate verify locations:
* CAfile: D:\common\ssl\cacert.pem
CApath: none
* Operation timed out after 0 milliseconds with 0 out of 0 bytes received
* Closing connection 69

 

This one is fine with the request id 5f3ffe12-1d81-4be0-a691-6a5402cb1ced, I don't even get a request id back on the one that hangs above.

* Hostname was found in DNS cache
* Trying 23.227.38.64...
* Connected to ibeauty1.myshopify.com (23.227.38.64) port 443 (#70)
* successfully set certificate verify locations:
* CAfile: D:\common\ssl\cacert.pem
CApath: none
* SSL connection using TLSv1.2 / ECDHE-ECDSA-AES128-GCM-SHA256
* Server certificate:
* subject: C=US; ST=CA; L=San Francisco; O=CloudFlare, Inc.; CN=*.myshopify.com
* start date: 2019-05-02 00:00:00 GMT
* expire date: 2020-05-02 12:00:00 GMT
* subjectAltName: ibeauty1.myshopify.com matched
* issuer: C=US; ST=CA; L=San Francisco; O=CloudFlare, Inc.; CN=CloudFlare Inc ECC CA-2
* SSL certificate verify ok.
* Server auth using Basic with user . . .

 

It's weird because it works sporadically and it was working smoothly till this morning when logs started showing this.

No server updates happened on our side, I checked, all our other web interfaces are working. I restarted the server as well, same issue.

 

Thanks,

Matt

1 Like
Shopify Partner
26 0 2

Yes we are having same issue for last 3 days. We think maybe Shopify is doing early morning server maintenance... but I have not seen any notifications from Shopify regarding this. We fetch orders using Order API early in the morning, but been broken last few days.

 

Shopify please communicate these things with us, or let us know if some other issue is happening

Danny Ward | Data+Design | Award Winning eCommerce Business Development | Shopify Expert
0 Likes
Shopify Staff
Shopify Staff
69 7 9

Hey @MHolt and @Data_Design,

 

In order to investigate this further, I'd like to gather some information from you. Feel free to send this to me in a private message if you prefer. Kindly provide:

 

- Some examples of errors with timestamp and URL, the more examples you can provide the better

 

- Details about the client making these calls (hosting provider, libraries being used, timeout settings, IP address, etc)

 

- From the same environment your app is running in, please visit https://_insert_shop_domain_/cdn-cgi/trace and provide the output from that page

 

Please get back to me with that and we'll investigate further.

JB | Developer Support @ Shopify
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Click Accept as Solution 

0 Likes
Tourist
9 0 4

@Data_Design

Did you happen to find a solution yet?

_JB is still working on it with me.

0 Likes
Shopify Partner
26 0 2

Only a duct tape solution... instead of fetching orders twice daily we are running every hour so if connection fails we will have somewhat fresh data... as they say on Gold Rush "it's a bush fix"

Danny Ward | Data+Design | Award Winning eCommerce Business Development | Shopify Expert
0 Likes
Tourist
9 0 4

Ya we are already doing hourly. I did find this article which I asked JB to look into which sounds similar to what we are dealing with in timeouts:

https://community.shopify.com/c/Shopify-APIs-SDKs/Timeouts/td-p/446220

 

We have tried all kinds of stuff in our firewall to try and resolve the issue as well to no avail.

0 Likes
Shopify Staff
Shopify Staff
69 7 9

Hey @Data_Design,

 

Can you kindly visit https://_insert_shop_domain_/cdn-cgi/trace from the server your app is running on, and provide the output from that page.

 

@MHolt and @Data_Design,

 

I had a look at the linked article. Although the issue seems similar, that issue was caused by known outages we were experiencing at the time which have since been resolved.

 

I have one more ask to assist with the troubleshooting here. Can you please provide the full response headers for any failed request? Specifically we're looking for the cf-ray field if it's present. As well can you kindly provide the x-request-id for any recent requests that succeeded immediately after a failed one? In our investigations so far we haven't been able to find anything in our logs to indicate requests are failing, so this will help us further narrow it down.

JB | Developer Support @ Shopify
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Click Accept as Solution 

0 Likes
Tourist
9 0 4

For anyone's future reference I'm not sure what fixed this. The only thing that was changed before we stopped receiving errors was updating to the current api version, even though the deprecated one was still working and not required to be changed until April.

And we halved the number of requests we sent to the api. We used to make a request to shop.json to check and see if we needed to switch app keys or wait a few seconds before going over the api bucket limit (35/40 or greater out of the bucket). Then make our call whether grabbing orders or posting products, etc.

Now we just check the api limit on grabbing or posting and loop back to try again with a different app key or after waiting if we hit the limit, essentially halving the calls for all our stores. I don't really think halving the calls was the issue since things were working smoothly with the same amount of calls the week prior.

 

 

0 Likes