azure-mgmt-network is huge
- Package Name: azure-mgmt-network
- Package Version: 10.1.0
- Operating System: alpine-3.11.6
- Python Version: 3.8
Describe the bug
azure-mgmt-network is the biggest dependency by far for my project, the size on disk is 110MB, which means that it slows down everything else - like building & publishing my application.
To Reproduce Steps to reproduce the behavior:
pip install azure-mgmt-network- inspect the
site-packages/azure/mgmt/networkfolder
Expected behavior
I would expect the SDK to be much lighter, for comparison the entire GCP python SDK is ~5MB and boto3+botocore is ~50MB (which includes the entire SDK).
If I were to install azure-mgmt-compute & azure-mgmt-resource I would get another 30MB, in one of my applications the azure folder is 250MB bigger than all the rest of the filesystem combined.
hi @yoava333 , i checked the pkg size, it is huge because network has multi versions, when you download this pkg, it will download pkgs of all version, we will discuss this on our meeting, thx.
@lmazuel , do you have any suggestion here? is it possible to optimize the codegen to reduce the size? thanks.
Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @aznetsuppgithub.
We did some investigation and found that the current network package still include very old api-version. Add "Service Attention" label to include service team to confirm whether we still need to support all the api-versions, it will be helpful to reduce the size if some old api-version can be removed from the package. thanks.
Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @aznetsuppgithub.
Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @vnetsuppgithub.
Any update on this?
Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @vnetsuppgithub.
Could you update on the status of this issue?
Azure right now is ~330MB I cannot use the sdk it in an AWS Lambda function anymore

i have the same problem as well... Please update
@chenjianfei2017 - I'm from the SDN team, did you come to any conclusion about how to fix this?
The issue is only becoming worse over time, it's now ~370MB

Where azure-mgmt-network is the biggest offender with ~230MB

@MikhailTryakhov, is it possible that we can make the package smaller? for example, deprecate some very old versions such as 2015-xx-xx.
Actually this need cross team collaboration as network has many feature teams, do you know who can be the coordinator to collect thoughts from different feature team?
Before deprecation, we need data to insure there is no users to use those deprecated version recently.

The sheer size of azure-mgmt-network even makes PyCharm unresponsive by selecting or searching for begin_create_or_update.
https://github.com/Azure/azure-cli/blob/b0815f704b1c3a34c4b5a4aecf9489166eef30ef/src/azure-cli/azure/cli/command_modules/rdbms/flexible_server_virtual_network.py#L173
nw_client.virtual_networks.begin_create_or_update(resource_group, ...)
I have to set the project to "No interpreter" for coding.

Hey @jsntcy I assume that's impossible. different customers are using different api versions and I'm not sure it's a good idea to deprecate some of them
@MikhailTryakhov,
- We know different customers use different api versions, and we can collect data from telemetry to see if all existing API versions are used, if some versions are not used recently, we may probably deprecate them; otherwise the package will be bigger and bigger in the future as Network will include all existing features in new versions.
- Also we can suggest customers to upgrade from very old version to new version for better/more features provided.
- Another possible way: can we split Network package into multiple packages for different sub services.
@jsntcy can you share these metrics?
@jsntcy regarding to collect data from telemetry to see if all existing API versions are used
@jsntcy any update?
Has there been any resolution or progress on this issue?