@justinvelluppillai opened this Issue on November 13th 2022 Member

Currently we are restricting the request to use curl https://github.com/matomo-org/matomo/pull/19957/files#diff-105cf795eee08d8e19b4daf399977e29fbbf8b3d5d2b6995e06d0909e0b68785R116, whereas we can just use sendHttpRequest(). Let's switch it to use that unless there is reason not to?

Also can we make sure to cache the result for say 4+ weeks or forever or something? Then we don't try to request the data every time which would make these pages and widgets etc quite slow. Ideally, we would even mostly update the cached result only in the background (or store it forever).

@justinvelluppillai commented on November 14th 2022 Member

@mattab I have added this directly to the current patch milestone as an extension of the previous work which was also scheduled for this release. I recommend we include it but let me know if it's something you would prefer to delay 👍🏽

@peterhashair commented on November 14th 2022 Contributor

@justinvelluppillai I think this is because sendHttpRequestBy contains a param defines, $acceptInvalidSslCertificate. sendHttpRequest does not have the feature, if I am correct.

@justinvelluppillai commented on November 14th 2022 Member

If needed we can still use that function but instead of specifying curl we can use Http::getTransportMethod() - perhaps this would need investigation.

@sgiehl commented on November 14th 2022 Member

Yes. Simply using Http::getTransportMethod() should be they way to go here...

This Issue was closed on November 15th 2022
Powered by GitHub Issue Mirror