I know that C2DM registrations expire, and you are supposed to periodically refresh the registration ID. Is this the case with GCM? by looking at the following code on the Android GCM guide (shown below), it seems like you only do it once and don't need to refresh, but I dont see that explicitly written anywhere, so I just wanted to check.
final String regId = GCMRegistrar.getRegistrationId(this);
if (regId.equals("")) {
GCMRegistrar.register(this, SENDER_ID);
} else {
Log.v(TAG, "Already registered");
}
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.