This example adds timestamp in a tag description to identify when a resource was last reconfigured. The tag description is updated with the timestamp after the resources is reconfigured.
This example is based on the information that is provided in Updating a Tag.
import java.util.Date; import java.text.Dateformat; String newDateTime = Dateformat.getDateInstance().format(new Date()); String newDescription = String.format(“Server tag updated at (%s).”, newDateTime); TagTypes.UpdateSpec updateSpec = new TagTypes.UpdateSpec(); updateSpec.setDescription(newDescription); tagStub.update(myTagId, updateSpec);