I have a django app up and running. I never encountered any performance problems, though the app is hosted on a shared hosting platform.
The provider asked my recently to use python's virtualenv
. Since then the performance has been really bad, though I can't detect the change in CPU usage or any other statistic.
So my question is: does using a virtual environment influence the performance? If yes, how?
Portability. It's possible to seamlessly move VMs across virtual environments and even from one physical server to another, with minimal input on the part of IT teams. VMs are isolated from one another and have their own virtual hardware, making them hardware-independent.
Importance of Virtual EnvironmentsAs your project portfolio grows, managing package dependencies becomes more important. Jumping from one project to another means different libraries used for various purposes and the need for version adjustment to ensure compatability.
A virtual environment is a tool that helps to keep dependencies required by different projects separate by creating isolated python virtual environments for them. This is one of the most important tools that most of the Python developers use.
Activating a virtual environment Before you can start installing or using packages in your virtual environment you'll need to activate it. Activating a virtual environment will put the virtual environment-specific python and pip executables into your shell's PATH .
Nope, it doesnt infuence the performance. Basically all what it do is changing python path to the virtualenvs ones. So there shouldn`t be any difference with performance.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With