Do GCM registration id's expire?
Solution 1:
EDIT: THIS ANSWER IS WAY OUT OF DATE, I HAVE NO IDEA WHAT THE CURRENT BEHAVIOR IS
I found the answer myself. You don't explicitly need to re-register all the time, just once according to the example in the docs.
Also, unlike previous versions of GCM and C2DM, Google itself does not refresh the registration itself now: once you have the registration id from the initial registration you are good to go, except for one case: you do still need to re-register when the user upgrades to a new version (this case is also handled in the example in the link above):
When an application is updated, it should invalidate its existing registration ID, as it is not guaranteed to work with the new version. Because there is no lifecycle method called when the application is updated, the best way to achieve this validation is by storing the current application version when a registration ID is stored.
Solution 2:
I think that it is refreshed eventually, yes. From the official docs:
An existing registration ID may cease to be valid in a number of scenarios, including: If the application manually unregisters by issuing a com.google.android.c2dm.intent.UNREGISTER intent. If the application is automatically unregistered, which can happen (but is not guaranteed) if the user uninstalls the application. If the registration ID expires. Google might decide to refresh registration IDs. For all these cases, you should remove this registration ID from the 3rd-party server and stop using it to send messages. Happens when error code is NotRegistered.
This could happen in a request to GCM from your 3rd-party server, which returns a json response with the error Unregistered Device.
Once this happen, it'll be up to you to refresh the corresponding id's.
http://developer.android.com/guide/google/gcm/gcm.html