If you can take your service down you can always migrate directly to the latest version. If you need your service to keep running you need to follow any migration instructions for your particular datastore. In v1.22.0 only Cloud Spanner had a migration, so if you're not using cloud spanner you should be clear to go all the way from v1.20.0 to v1.23.1.