com.elastisys.scale.cloudpool.openstack.requests

## Class ListServersWithTagRequest

- java.lang.Object
- - com.elastisys.scale.cloudpool.openstack.requests.AbstractOpenstackRequest<List<org.openstack4j.model.compute.Server>>
  - - com.elastisys.scale.cloudpool.openstack.requests.ListServersWithTagRequest

All Implemented Interfaces:
  Callable<List<org.openstack4j.model.compute.Server>>

    public class ListServersWithTagRequest
    extends AbstractOpenstackRequest<List<org.openstack4j.model.compute.Server>>

An OpenStack request task that, when executed, retrieves all `Server`s with a certain meta data tag.

### Constructor Summary

Constructors
Constructor and Description
`ListServersWithTagRequest(com.elastisys.scale.commons.openstack.OSClientFactory clientFactory, String tag, String tagValue)` Constructs a new `ListServersWithTagRequest` task.

### Method Summary

All Methods Instance Methods Concrete Methods
`List<org.openstack4j.model.compute.Server>` `doRequest(org.openstack4j.api.OSClient api)` Carries out the request and returns the response.

### Methods inherited from class com.elastisys.scale.cloudpool.openstack.requests.AbstractOpenstackRequest

`call, getApiAccessConfig, getClientFactory`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### ListServersWithTagRequest

    public ListServersWithTagRequest(com.elastisys.scale.commons.openstack.OSClientFactory clientFactory,
                                     String tag,
                                     String tagValue)

Constructs a new `ListServersWithTagRequest` task.

Parameters:
  `clientFactory` - OpenStack API client factory.
  `tag` - A meta data tag that must be present on returned servers.
  `tagValue` - The value for the meta data tag that must be present on returned servers.

### Method Detail

#### doRequest

    public List<org.openstack4j.model.compute.Server> doRequest(org.openstack4j.api.OSClient api)

Description copied from class: `AbstractOpenstackRequest`
Carries out the request and returns the response.

Specified by:
  `doRequest` in class `AbstractOpenstackRequest<List<org.openstack4j.model.compute.Server>>`
Parameters:
  `api` - An authenticated OpenStack API client that is instructed to operate against the configured region.
Returns:
  The response.