| OLD | NEW |
| 1 # Copyright 2015 The Swarming 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 by the Apache v2.0 license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 """Cloud endpoints for the Machine Provider API.""" | 5 """Cloud endpoints for the Machine Provider API.""" |
| 6 | 6 |
| 7 import hashlib | 7 import hashlib |
| 8 import json | 8 import json |
| 9 import logging | 9 import logging |
| 10 | 10 |
| 11 import endpoints | 11 import endpoints |
| (...skipping 491 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 503 request_hash, | 503 request_hash, |
| 504 ) | 504 ) |
| 505 return rpc_messages.LeaseReleaseRequestError.ALREADY_RECLAIMED | 505 return rpc_messages.LeaseReleaseRequestError.ALREADY_RECLAIMED |
| 506 logging.info('Releasing LeaseRequest: %s', request_hash) | 506 logging.info('Releasing LeaseRequest: %s', request_hash) |
| 507 request.released = True | 507 request.released = True |
| 508 request.put() | 508 request.put() |
| 509 | 509 |
| 510 | 510 |
| 511 def create_endpoints_app(): | 511 def create_endpoints_app(): |
| 512 return endpoints.api_server([CatalogEndpoints, MachineProviderEndpoints]) | 512 return endpoints.api_server([CatalogEndpoints, MachineProviderEndpoints]) |
| OLD | NEW |