GithubHelp home page GithubHelp logo

Comments (2)

kshivakumar avatar kshivakumar commented on May 20, 2024

@dwc0011

...trying to detect the others is a waste of time and resources

There's no waste of time since all the providers are checked concurrently. When the correct provider is identifier, other checks are cancelled immediately.
I don't think any application that uses this library will check the cloud provider every other minute or hour, making few additional http requests once in a while is not waste of resources.
Moreover, by not having to pass my_providers to the provider function we keep our api simple.

The only case where the library takes considerable time to respond is when the environment is not one of the supported cloud providers. See this comment for additional info - #12 (comment).
When the environment is supported, the response is almost instantaneous.

from cloud-detect.

dwc0011 avatar dwc0011 commented on May 20, 2024

@kshivakumar

Moreover, by not having to pass my_providers to the provider function we keep our api simple.

I understand that you wish to keep the api simple, but at the same time I understand the need for not checking for resources that will never be. An optional param is also still pretty simple to me, heck this feature was even part of the API up until April, just as an opposite "excluded" param.

The only case where the library takes considerable time to respond is when the environment is not one of the supported cloud providers.

This is the exact case I am trying to prevent, we wanted to use in our application which does run quite often on environments that are not supported. The more cloud providers it has to check the more resources and time that is wasted, even if concurrent.

I appreciate you responding and hope that you reconsider but I understand either way. Feel free to close if your decision is final. Thanks.

from cloud-detect.

Related Issues (15)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.