| OLD | NEW |
| 1 # Copyright 2015 The LUCI Authors. All rights reserved. | 1 # Copyright 2015 The LUCI Authors. All rights reserved. |
| 2 # Use of this source code is governed by the Apache v2.0 license that can be | 2 # Use of this source code is governed under the Apache License, Version 2.0 |
| 3 # found in the LICENSE file. | 3 # that can be found in the LICENSE file. |
| 4 | 4 |
| 5 """Policies for machines in the Machine Provider Catalog.""" | 5 """Policies for machines in the Machine Provider Catalog.""" |
| 6 | 6 |
| 7 from protorpc import messages | 7 from protorpc import messages |
| 8 | 8 |
| 9 | 9 |
| 10 class KeyValuePair(messages.Message): | 10 class KeyValuePair(messages.Message): |
| 11 """Represents a key-value pair.""" | 11 """Represents a key-value pair.""" |
| 12 key = messages.StringField(1, required=True) | 12 key = messages.StringField(1, required=True) |
| 13 value = messages.StringField(2) | 13 value = messages.StringField(2) |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 56 # Action the Machine Provider should take when reclaiming a machine | 56 # Action the Machine Provider should take when reclaiming a machine |
| 57 # from a lessee. | 57 # from a lessee. |
| 58 on_reclamation = messages.EnumField( | 58 on_reclamation = messages.EnumField( |
| 59 MachineReclamationPolicy, | 59 MachineReclamationPolicy, |
| 60 4, | 60 4, |
| 61 default=MachineReclamationPolicy.MAKE_AVAILABLE, | 61 default=MachineReclamationPolicy.MAKE_AVAILABLE, |
| 62 ) | 62 ) |
| 63 # Cloud Pub/Sub message attributes to include when communicating with the | 63 # Cloud Pub/Sub message attributes to include when communicating with the |
| 64 # backend regarding this machine. | 64 # backend regarding this machine. |
| 65 backend_attributes = messages.MessageField(KeyValuePair, 5, repeated=True) | 65 backend_attributes = messages.MessageField(KeyValuePair, 5, repeated=True) |
| OLD | NEW |