简体   繁体   中英

Dependency Isolation meaning

I 'm reading the 12-factor-app manifesto and I'm at the dependencies section right now. Dependency Isolation is something I cannot get my head around, though.

Unfortunately no actual definition as to what that is is given, aside from that 12-factor-apps should "use a dependency isolation tool during execution to ensure that no implicit dependencies “leak in” from the surrounding system ".

Searching for answers to that, I 'm only finding questions about how to achieve dependency isolation in a specific language/framework.

Maybe it is just a limitation in my understanding of english, but could someone enlighten me on this?

Application dependencies should be managed by application build itself, but not manage from outside or separately. Tools can be used like maven pom.xml or gradle.build or package.json or Gemfile etc

Lets assume you are building an app with Python. You decide to use Django web-framework. As you are starting you install Django using pip install django . Django 3.1 is installed on your local system.

After two months you decide to host the Django project on server. You install django by pip install django . This time Django 3.3 is installed. Because of version upgrade your code might break.

To avoid such scenarios it is recommended to note the version of Django and Python. You can add the Django version in requirement.txt or piplock file.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM