What is the difference between \"Download pipeline artifact\" and \"Download build artifacts\"? Which one should be used and when?
Pipeline artifact: provide a way to share files between stages in a pipeline or between different pipelines. They are typically the output of a build process that need to be consumed by another job or be deployed. Artifacts are associated with the run they were produced in and remain available after the run has completed.
Using Download Pipeline Artifacts in a build or release pipeline to download pipeline artifacts from earlier stages in this pipeline, or from another pipeline.
Build artifact :Artifacts are the files that you want your build to produce. Artifacts can be anything that your team needs to test or deploy your app.
Using Download Build Artifacts in a build or release pipeline to download build artifacts.
Pipeline artifacts are the next generation of build artifacts and are the recommended way to work with artifacts. Artifacts published using the Publish Build Artifacts task can continue to be downloaded using Download Build Artifacts, but can also be downloaded using the latest Download Pipeline Artifact task.
Note: It is recommended upgrading from build artifacts to pipeline artifacts for faster output storage speeds.
Here are some documents you can refer to: