The URLSessionConfiguration class defines the behavior and policies to use when using the URLSession object to connect to a URL. When using the URLSession object, we usually create a URLSessionConfiguration instance first, because an instance of this class is required when we create an instance of the URLSession class.
The URLSessionConfiguration class defines three session types:
- Default session configuration: This manages the upload and download tasks with default configurations
- Ephemeral session configuration: This configuration behaves similarly to the default session configuration, except that it does not cache anything to disk
- Background session configuration: This session allows for uploads and downloads to ...