Search in sources :

Example 11 with Operation

use of com.vmware.xenon.common.Operation in project photon-model by vmware.

the class TestAWSEnumerationDocumentCountInLongRun method assertNetworkInterfaceLinksAreValid.

private void assertNetworkInterfaceLinksAreValid() {
    for (String computeLink : this.computeStateLinks) {
        Operation getCompute = Operation.createGet((UriUtils.buildUri(this.host, computeLink))).setReferer(this.host.getUri());
        Operation compute = this.host.waitForResponse(getCompute);
        if (compute.getStatusCode() == 200) {
            ComputeState state = compute.getBody(ComputeState.class);
            for (String nicLink : state.networkInterfaceLinks) {
                Operation getNic = Operation.createGet((UriUtils.buildUri(this.host, nicLink))).setReferer(this.host.getUri());
                Operation nic = this.host.waitForResponse(getNic);
                assertEquals("GET on NIC failed.", Operation.STATUS_CODE_OK, nic.getStatusCode());
            }
        }
    }
}
Also used : ComputeState(com.vmware.photon.controller.model.resources.ComputeService.ComputeState) Operation(com.vmware.xenon.common.Operation)

Example 12 with Operation

use of com.vmware.xenon.common.Operation in project photon-model by vmware.

the class TestAWSEnumerationDocumentCountInLongRun method verifyResourceDuplicates.

/**
 * Verify documents for duplicates after multiple enumerations.
 */
private void verifyResourceDuplicates() {
    int total_dup_resource_count = 0;
    for (Class resource : resourcesList) {
        QueryTask.Query.Builder qBuilder = QueryTask.Query.Builder.create().addKindFieldClause(resource).addFieldClause("endpointLinks.item", this.endpointState.documentSelfLink, QueryTask.QueryTerm.MatchType.TERM, QueryTask.Query.Occurance.MUST_OCCUR);
        if (resource.getSimpleName().equals("ComputeState")) {
            qBuilder.addFieldClause("type", "VM_GUEST", QueryTask.QueryTerm.MatchType.TERM, QueryTask.Query.Occurance.MUST_OCCUR);
        }
        QueryTask resourceQt = QueryTask.Builder.createDirectTask().setQuery(qBuilder.build()).addOption(QueryTask.QuerySpecification.QueryOption.EXPAND_CONTENT).addOption(QueryTask.QuerySpecification.QueryOption.TOP_RESULTS).setResultLimit(10000).build();
        Operation queryDocuments = QueryUtils.createQueryTaskOperation(this.host, resourceQt, ServiceTypeCluster.INVENTORY_SERVICE).setReferer(this.host.getUri());
        Operation queryResponse = this.host.waitForResponse(queryDocuments);
        Assert.assertTrue("Error retrieving enumerated documents", queryResponse.getStatusCode() == 200);
        QueryTask qt = queryResponse.getBody(QueryTask.class);
        Set<String> resourceIdSet = new HashSet<>();
        if (qt.results != null && qt.results.documentLinks != null && qt.results.documentLinks.size() > 0) {
            this.host.log("Number of %s docs: %d", resource.getSimpleName(), qt.results.documentLinks.size());
            for (String resourceDocumentLink : qt.results.documentLinks) {
                Object object = qt.results.documents.get(resourceDocumentLink);
                ResourceState resourceState = Utils.fromJson(object, ResourceState.class);
                String resourceId = resourceState.id;
                if (!resourceIdSet.contains(resourceId)) {
                    resourceIdSet.add(resourceId);
                } else {
                    this.host.log("duplicate %s id = %s, with state: ", resource.getSimpleName(), resourceId, Utils.toJsonHtml(resourceState));
                    total_dup_resource_count++;
                }
            }
        }
    }
    assertEquals("Duplicate resources found: ", 0, total_dup_resource_count);
}
Also used : QueryTask(com.vmware.xenon.services.common.QueryTask) ResourceState(com.vmware.photon.controller.model.resources.ResourceState) Operation(com.vmware.xenon.common.Operation) TestAWSSetupUtils.deleteVMsOnThisEndpoint(com.vmware.photon.controller.model.adapters.awsadapter.TestAWSSetupUtils.deleteVMsOnThisEndpoint) HashSet(java.util.HashSet)

Example 13 with Operation

use of com.vmware.xenon.common.Operation in project photon-model by vmware.

the class TestAWSCostAdapterService method triggerStatsCollection.

private void triggerStatsCollection(ResourcePoolState pool) {
    StatsCollectionTaskState statCollectionState = new StatsCollectionTaskState();
    statCollectionState.resourcePoolLink = pool.documentSelfLink;
    statCollectionState.statsAdapterReference = UriUtils.buildUri(this.host, AWSCostStatsService.SELF_LINK);
    statCollectionState.documentSelfLink = "cost-stats-adapter" + UUID.randomUUID().toString();
    statCollectionState.options = EnumSet.of(TaskOption.SELF_DELETE_ON_COMPLETION);
    statCollectionState.taskInfo = TaskState.createDirect();
    Operation op = Operation.createPost(this.host, StatsCollectionTaskService.FACTORY_LINK).setBody(statCollectionState).setReferer(this.host.getReferer());
    this.host.sendAndWaitExpectSuccess(op);
}
Also used : Operation(com.vmware.xenon.common.Operation) StatsCollectionTaskState(com.vmware.photon.controller.model.tasks.monitoring.StatsCollectionTaskService.StatsCollectionTaskState) SingleResourceStatsCollectionTaskState(com.vmware.photon.controller.model.tasks.monitoring.SingleResourceStatsCollectionTaskService.SingleResourceStatsCollectionTaskState)

Example 14 with Operation

use of com.vmware.xenon.common.Operation in project photon-model by vmware.

the class AWSCostStatsService method getAccountDescription.

protected void getAccountDescription(AWSCostStatsCreationContext statsData, AWSCostStatsCreationStages next) {
    Consumer<Operation> onSuccess = (op) -> {
        ComputeStateWithDescription compute = op.getBody(ComputeStateWithDescription.class);
        statsData.computeDesc = compute;
        inferEndpointLink(statsData);
        String accountId = AWSUtils.isAwsS3Proxy() ? "mock" : compute.customProperties.get(AWS_ACCOUNT_ID_KEY);
        if (compute.type != ComputeType.ENDPOINT_HOST || compute.parentLink != null || compute.endpointLink == null || accountId == null || CollectionUtils.isEmpty(compute.endpointLinks)) {
            logWithContext(statsData, Level.SEVERE, () -> "Malformed Root Compute.");
            postAccumulatedCostStats(statsData, true);
            return;
        }
        statsData.accountId = accountId;
        statsData.awsAccountIdToComputeStates.put(accountId, Collections.singletonList(compute));
        getEndpointState(statsData, next);
    };
    URI computeUri = UriUtils.extendUriWithQuery(statsData.statsRequest.resourceReference, UriUtils.URI_PARAM_ODATA_EXPAND, Boolean.TRUE.toString());
    AdapterUtils.getServiceState(this, computeUri, onSuccess, getFailureConsumer(statsData));
}
Also used : AuthCredentialsServiceState(com.vmware.xenon.services.common.AuthCredentialsService.AuthCredentialsServiceState) Arrays(java.util.Arrays) DateTimeZone(org.joda.time.DateTimeZone) AWS_ACCOUNT_BILL_PROCESSED_TIME_MILLIS(com.vmware.photon.controller.model.adapters.awsadapter.AWSConstants.AWS_ACCOUNT_BILL_PROCESSED_TIME_MILLIS) AWSCsvBillParser(com.vmware.photon.controller.model.adapters.awsadapter.util.AWSCsvBillParser) ServiceTypeCluster(com.vmware.photon.controller.model.util.ClusterUtil.ServiceTypeCluster) QueryTask(com.vmware.xenon.services.common.QueryTask) ServiceDocument(com.vmware.xenon.common.ServiceDocument) ComputeType(com.vmware.photon.controller.model.resources.ComputeDescriptionService.ComputeDescription.ComputeType) EndpointAllocationTaskService(com.vmware.photon.controller.model.tasks.EndpointAllocationTaskService) SingleResourceStatsCollectionTaskState(com.vmware.photon.controller.model.tasks.monitoring.SingleResourceStatsCollectionTaskService.SingleResourceStatsCollectionTaskState) ProgressListener(com.amazonaws.event.ProgressListener) STORAGE_TYPE_EBS(com.vmware.photon.controller.model.adapters.awsadapter.AWSConstants.STORAGE_TYPE_EBS) Utils(com.vmware.xenon.common.Utils) STORAGE_TYPE_S3(com.vmware.photon.controller.model.adapters.awsadapter.AWSConstants.STORAGE_TYPE_S3) ACCOUNT_IS_AUTO_DISCOVERED(com.vmware.photon.controller.model.adapters.awsadapter.AWSConstants.ACCOUNT_IS_AUTO_DISCOVERED) Map(java.util.Map) URI(java.net.URI) ProgressEventType(com.amazonaws.event.ProgressEventType) AWSMissingResourcesEnumerationService(com.vmware.photon.controller.model.adapters.awsadapter.enumeration.AWSMissingResourcesEnumerationService) Path(java.nio.file.Path) AWSClientManager(com.vmware.photon.controller.model.adapters.awsadapter.util.AWSClientManager) EndpointState(com.vmware.photon.controller.model.resources.EndpointService.EndpointState) PrintWriter(java.io.PrintWriter) ComputeStatsResponse(com.vmware.photon.controller.model.adapterapi.ComputeStatsResponse) ComputeStatsRequest(com.vmware.photon.controller.model.adapterapi.ComputeStatsRequest) StatelessService(com.vmware.xenon.common.StatelessService) ConcurrentHashMap(java.util.concurrent.ConcurrentHashMap) TaskManager(com.vmware.photon.controller.model.adapters.util.TaskManager) Set(java.util.Set) DiskState(com.vmware.photon.controller.model.resources.DiskService.DiskState) Occurance(com.vmware.xenon.services.common.QueryTask.Query.Occurance) UUID(java.util.UUID) Collectors(java.util.stream.Collectors) AwsServiceDetailDto(com.vmware.photon.controller.model.adapters.aws.dto.AwsServiceDetailDto) Objects(java.util.Objects) List(java.util.List) AWS_LINKED_ACCOUNT_IDS(com.vmware.photon.controller.model.adapters.awsadapter.AWSConstants.AWS_LINKED_ACCOUNT_IDS) Stream(java.util.stream.Stream) UriUtils(com.vmware.xenon.common.UriUtils) Entry(java.util.Map.Entry) QueryOption(com.vmware.xenon.services.common.QueryTask.QuerySpecification.QueryOption) AwsServices(com.vmware.photon.controller.model.adapters.awsadapter.util.AWSCsvBillParser.AwsServices) ResourceMetrics(com.vmware.photon.controller.model.monitoring.ResourceMetricsService.ResourceMetrics) SingleResourceTaskCollectionStage(com.vmware.photon.controller.model.tasks.monitoring.SingleResourceStatsCollectionTaskService.SingleResourceTaskCollectionStage) AwsAccountDetailDto(com.vmware.photon.controller.model.adapters.aws.dto.AwsAccountDetailDto) TransferManager(com.amazonaws.services.s3.transfer.TransferManager) QueryByPages(com.vmware.photon.controller.model.query.QueryUtils.QueryByPages) OperationContext(com.vmware.xenon.common.OperationContext) AWS_ACCOUNT_ID_KEY(com.vmware.photon.controller.model.adapters.awsadapter.AWSConstants.AWS_ACCOUNT_ID_KEY) HashMap(java.util.HashMap) ComputeDescriptionService(com.vmware.photon.controller.model.resources.ComputeDescriptionService) GetObjectRequest(com.amazonaws.services.s3.model.GetObjectRequest) ResourceMetricsService(com.vmware.photon.controller.model.monitoring.ResourceMetricsService) Function(java.util.function.Function) Supplier(java.util.function.Supplier) ArrayList(java.util.ArrayList) Level(java.util.logging.Level) ProgressEvent(com.amazonaws.event.ProgressEvent) HashSet(java.util.HashSet) AuthCredentialsService(com.vmware.xenon.services.common.AuthCredentialsService) Query(com.vmware.xenon.services.common.QueryTask.Query) UriPaths(com.vmware.photon.controller.model.UriPaths) CollectionUtils(org.apache.commons.collections.CollectionUtils) ComputeState(com.vmware.photon.controller.model.resources.ComputeService.ComputeState) BiConsumer(java.util.function.BiConsumer) ComputeStats(com.vmware.photon.controller.model.adapterapi.ComputeStatsResponse.ComputeStats) AwsClientType(com.vmware.photon.controller.model.adapters.awsadapter.AWSConstants.AwsClientType) StatsUtil(com.vmware.photon.controller.model.tasks.monitoring.StatsUtil) ExecutorService(java.util.concurrent.ExecutorService) AdapterUtils(com.vmware.photon.controller.model.adapters.util.AdapterUtils) AmazonS3Exception(com.amazonaws.services.s3.model.AmazonS3Exception) ResourceState(com.vmware.photon.controller.model.resources.ResourceState) Files(java.nio.file.Files) StringWriter(java.io.StringWriter) Operation(com.vmware.xenon.common.Operation) QueryUtils(com.vmware.photon.controller.model.query.QueryUtils) IOException(java.io.IOException) ServiceStat(com.vmware.xenon.common.ServiceStats.ServiceStat) AwsResourceDetailDto(com.vmware.photon.controller.model.adapters.aws.dto.AwsResourceDetailDto) TimeUnit(java.util.concurrent.TimeUnit) Consumer(java.util.function.Consumer) LocalDate(org.joda.time.LocalDate) ConcurrentSkipListMap(java.util.concurrent.ConcurrentSkipListMap) Paths(java.nio.file.Paths) ClusterUtil(com.vmware.photon.controller.model.util.ClusterUtil) AWSStatsNormalizer(com.vmware.photon.controller.model.adapters.awsadapter.util.AWSStatsNormalizer) ComputeStateWithDescription(com.vmware.photon.controller.model.resources.ComputeService.ComputeStateWithDescription) PhotonModelConstants(com.vmware.photon.controller.model.constants.PhotonModelConstants) AWSClientManagerFactory(com.vmware.photon.controller.model.adapters.awsadapter.util.AWSClientManagerFactory) ServiceDocumentDescription(com.vmware.xenon.common.ServiceDocumentDescription) Collections(java.util.Collections) OperationJoin(com.vmware.xenon.common.OperationJoin) PhotonModelUriUtils.createInventoryUri(com.vmware.photon.controller.model.util.PhotonModelUriUtils.createInventoryUri) ComputeStateWithDescription(com.vmware.photon.controller.model.resources.ComputeService.ComputeStateWithDescription) Operation(com.vmware.xenon.common.Operation) URI(java.net.URI)

Example 15 with Operation

use of com.vmware.xenon.common.Operation in project photon-model by vmware.

the class AWSCostStatsService method getMarkerMetricsOp.

private Operation getMarkerMetricsOp(AWSCostStatsCreationContext context, ComputeState accComputeState) {
    QueryTask qTask = getQueryTaskForMetric(accComputeState);
    Operation.CompletionHandler completionHandler = (operation, exception) -> {
        if (exception != null) {
            logWarning(() -> String.format("Failed to get bill processed time for account: %s", accComputeState.documentSelfLink));
            getFailureConsumer(context).accept(exception);
            return;
        }
        QueryTask body = operation.getBody(QueryTask.class);
        String accountId = accComputeState.customProperties.get(AWS_ACCOUNT_ID_KEY);
        if (body.results.documentCount == 0) {
            ResourceMetrics markerMetrics = new ResourceMetrics();
            markerMetrics.timestampMicrosUtc = getCurrentMonthStartTimeMicros();
            markerMetrics.entries = new HashMap<>();
            markerMetrics.entries.put(AWSConstants.AWS_ACCOUNT_BILL_PROCESSED_TIME_MILLIS, 0d);
            markerMetrics.documentSelfLink = StatsUtil.getMetricKey(accComputeState.documentSelfLink, Utils.getNowMicrosUtc());
            context.accountsMarkersMap.put(accountId, markerMetrics);
        } else {
            ResourceMetrics markerMetrics = body.results.documents.values().stream().map(o -> Utils.fromJson(o, ResourceMetrics.class)).collect(Collectors.toList()).get(0);
            context.accountsMarkersMap.putIfAbsent(accountId, markerMetrics);
        }
    };
    return QueryUtils.createQueryTaskOperation(this, qTask, ServiceTypeCluster.METRIC_SERVICE).setExpiration(Utils.fromNowMicrosUtc(TimeUnit.SECONDS.toMicros(INTERNAL_REQUEST_TIMEOUT_SECONDS))).setCompletion(completionHandler);
}
Also used : AuthCredentialsServiceState(com.vmware.xenon.services.common.AuthCredentialsService.AuthCredentialsServiceState) Arrays(java.util.Arrays) DateTimeZone(org.joda.time.DateTimeZone) AWS_ACCOUNT_BILL_PROCESSED_TIME_MILLIS(com.vmware.photon.controller.model.adapters.awsadapter.AWSConstants.AWS_ACCOUNT_BILL_PROCESSED_TIME_MILLIS) AWSCsvBillParser(com.vmware.photon.controller.model.adapters.awsadapter.util.AWSCsvBillParser) ServiceTypeCluster(com.vmware.photon.controller.model.util.ClusterUtil.ServiceTypeCluster) QueryTask(com.vmware.xenon.services.common.QueryTask) ServiceDocument(com.vmware.xenon.common.ServiceDocument) ComputeType(com.vmware.photon.controller.model.resources.ComputeDescriptionService.ComputeDescription.ComputeType) EndpointAllocationTaskService(com.vmware.photon.controller.model.tasks.EndpointAllocationTaskService) SingleResourceStatsCollectionTaskState(com.vmware.photon.controller.model.tasks.monitoring.SingleResourceStatsCollectionTaskService.SingleResourceStatsCollectionTaskState) ProgressListener(com.amazonaws.event.ProgressListener) STORAGE_TYPE_EBS(com.vmware.photon.controller.model.adapters.awsadapter.AWSConstants.STORAGE_TYPE_EBS) Utils(com.vmware.xenon.common.Utils) STORAGE_TYPE_S3(com.vmware.photon.controller.model.adapters.awsadapter.AWSConstants.STORAGE_TYPE_S3) ACCOUNT_IS_AUTO_DISCOVERED(com.vmware.photon.controller.model.adapters.awsadapter.AWSConstants.ACCOUNT_IS_AUTO_DISCOVERED) Map(java.util.Map) URI(java.net.URI) ProgressEventType(com.amazonaws.event.ProgressEventType) AWSMissingResourcesEnumerationService(com.vmware.photon.controller.model.adapters.awsadapter.enumeration.AWSMissingResourcesEnumerationService) Path(java.nio.file.Path) AWSClientManager(com.vmware.photon.controller.model.adapters.awsadapter.util.AWSClientManager) EndpointState(com.vmware.photon.controller.model.resources.EndpointService.EndpointState) PrintWriter(java.io.PrintWriter) ComputeStatsResponse(com.vmware.photon.controller.model.adapterapi.ComputeStatsResponse) ComputeStatsRequest(com.vmware.photon.controller.model.adapterapi.ComputeStatsRequest) StatelessService(com.vmware.xenon.common.StatelessService) ConcurrentHashMap(java.util.concurrent.ConcurrentHashMap) TaskManager(com.vmware.photon.controller.model.adapters.util.TaskManager) Set(java.util.Set) DiskState(com.vmware.photon.controller.model.resources.DiskService.DiskState) Occurance(com.vmware.xenon.services.common.QueryTask.Query.Occurance) UUID(java.util.UUID) Collectors(java.util.stream.Collectors) AwsServiceDetailDto(com.vmware.photon.controller.model.adapters.aws.dto.AwsServiceDetailDto) Objects(java.util.Objects) List(java.util.List) AWS_LINKED_ACCOUNT_IDS(com.vmware.photon.controller.model.adapters.awsadapter.AWSConstants.AWS_LINKED_ACCOUNT_IDS) Stream(java.util.stream.Stream) UriUtils(com.vmware.xenon.common.UriUtils) Entry(java.util.Map.Entry) QueryOption(com.vmware.xenon.services.common.QueryTask.QuerySpecification.QueryOption) AwsServices(com.vmware.photon.controller.model.adapters.awsadapter.util.AWSCsvBillParser.AwsServices) ResourceMetrics(com.vmware.photon.controller.model.monitoring.ResourceMetricsService.ResourceMetrics) SingleResourceTaskCollectionStage(com.vmware.photon.controller.model.tasks.monitoring.SingleResourceStatsCollectionTaskService.SingleResourceTaskCollectionStage) AwsAccountDetailDto(com.vmware.photon.controller.model.adapters.aws.dto.AwsAccountDetailDto) TransferManager(com.amazonaws.services.s3.transfer.TransferManager) QueryByPages(com.vmware.photon.controller.model.query.QueryUtils.QueryByPages) OperationContext(com.vmware.xenon.common.OperationContext) AWS_ACCOUNT_ID_KEY(com.vmware.photon.controller.model.adapters.awsadapter.AWSConstants.AWS_ACCOUNT_ID_KEY) HashMap(java.util.HashMap) ComputeDescriptionService(com.vmware.photon.controller.model.resources.ComputeDescriptionService) GetObjectRequest(com.amazonaws.services.s3.model.GetObjectRequest) ResourceMetricsService(com.vmware.photon.controller.model.monitoring.ResourceMetricsService) Function(java.util.function.Function) Supplier(java.util.function.Supplier) ArrayList(java.util.ArrayList) Level(java.util.logging.Level) ProgressEvent(com.amazonaws.event.ProgressEvent) HashSet(java.util.HashSet) AuthCredentialsService(com.vmware.xenon.services.common.AuthCredentialsService) Query(com.vmware.xenon.services.common.QueryTask.Query) UriPaths(com.vmware.photon.controller.model.UriPaths) CollectionUtils(org.apache.commons.collections.CollectionUtils) ComputeState(com.vmware.photon.controller.model.resources.ComputeService.ComputeState) BiConsumer(java.util.function.BiConsumer) ComputeStats(com.vmware.photon.controller.model.adapterapi.ComputeStatsResponse.ComputeStats) AwsClientType(com.vmware.photon.controller.model.adapters.awsadapter.AWSConstants.AwsClientType) StatsUtil(com.vmware.photon.controller.model.tasks.monitoring.StatsUtil) ExecutorService(java.util.concurrent.ExecutorService) AdapterUtils(com.vmware.photon.controller.model.adapters.util.AdapterUtils) AmazonS3Exception(com.amazonaws.services.s3.model.AmazonS3Exception) ResourceState(com.vmware.photon.controller.model.resources.ResourceState) Files(java.nio.file.Files) StringWriter(java.io.StringWriter) Operation(com.vmware.xenon.common.Operation) QueryUtils(com.vmware.photon.controller.model.query.QueryUtils) IOException(java.io.IOException) ServiceStat(com.vmware.xenon.common.ServiceStats.ServiceStat) AwsResourceDetailDto(com.vmware.photon.controller.model.adapters.aws.dto.AwsResourceDetailDto) TimeUnit(java.util.concurrent.TimeUnit) Consumer(java.util.function.Consumer) LocalDate(org.joda.time.LocalDate) ConcurrentSkipListMap(java.util.concurrent.ConcurrentSkipListMap) Paths(java.nio.file.Paths) ClusterUtil(com.vmware.photon.controller.model.util.ClusterUtil) AWSStatsNormalizer(com.vmware.photon.controller.model.adapters.awsadapter.util.AWSStatsNormalizer) ComputeStateWithDescription(com.vmware.photon.controller.model.resources.ComputeService.ComputeStateWithDescription) PhotonModelConstants(com.vmware.photon.controller.model.constants.PhotonModelConstants) AWSClientManagerFactory(com.vmware.photon.controller.model.adapters.awsadapter.util.AWSClientManagerFactory) ServiceDocumentDescription(com.vmware.xenon.common.ServiceDocumentDescription) Collections(java.util.Collections) OperationJoin(com.vmware.xenon.common.OperationJoin) PhotonModelUriUtils.createInventoryUri(com.vmware.photon.controller.model.util.PhotonModelUriUtils.createInventoryUri) ResourceMetrics(com.vmware.photon.controller.model.monitoring.ResourceMetricsService.ResourceMetrics) QueryTask(com.vmware.xenon.services.common.QueryTask) ConcurrentHashMap(java.util.concurrent.ConcurrentHashMap) HashMap(java.util.HashMap) Operation(com.vmware.xenon.common.Operation)

Aggregations

Operation (com.vmware.xenon.common.Operation)391 URI (java.net.URI)142 ArrayList (java.util.ArrayList)132 QueryTask (com.vmware.xenon.services.common.QueryTask)118 List (java.util.List)118 Utils (com.vmware.xenon.common.Utils)111 StatelessService (com.vmware.xenon.common.StatelessService)108 UriUtils (com.vmware.xenon.common.UriUtils)106 ComputeState (com.vmware.photon.controller.model.resources.ComputeService.ComputeState)98 Map (java.util.Map)92 HashMap (java.util.HashMap)90 OperationJoin (com.vmware.xenon.common.OperationJoin)86 Query (com.vmware.xenon.services.common.QueryTask.Query)86 QueryUtils (com.vmware.photon.controller.model.query.QueryUtils)82 Collectors (java.util.stream.Collectors)79 HashSet (java.util.HashSet)78 AuthCredentialsServiceState (com.vmware.xenon.services.common.AuthCredentialsService.AuthCredentialsServiceState)73 AdapterUtils (com.vmware.photon.controller.model.adapters.util.AdapterUtils)70 DeferredResult (com.vmware.xenon.common.DeferredResult)69 Consumer (java.util.function.Consumer)69