Working with the object oriented APIs
This means that besides the driver object you also work with ,and NodeSize
object in the compute API, Container
and object in the Storage API, Zone
and Record
object in the DNS APIand so on.
Methods which operate on those resources usually require you to pass in aninstance of the resource you want to manipulate or work with and not just anid.
A couple of examples are shown below.
In this example, the method call results in an HTTPcall.
As you can see above, most of those getter methods retrieve extra informationabout the resource from the provider API and result in an HTTP request.
There are some cases when you might not want this:
- You don’t care about the extra attributes
- You want to avoid an extra HTTP request