Search in sources :

Example 1 with Api

use of io.apiman.gateway.engine.beans.Api in project apiman by apiman.

the class ActionResourceImpl method publishApi.

/**
 * Publishes an API to the gateway.
 * @param action
 */
private void publishApi(ActionBean action) throws ActionException, NotAuthorizedException {
    securityContext.checkPermissions(PermissionType.apiAdmin, action.getOrganizationId());
    ApiVersionBean versionBean;
    try {
        versionBean = orgs.getApiVersion(action.getOrganizationId(), action.getEntityId(), action.getEntityVersion());
    } catch (ApiVersionNotFoundException e) {
        // $NON-NLS-1$
        throw ExceptionFactory.actionException(Messages.i18n.format("ApiNotFound"));
    }
    // Validate that it's ok to perform this action - API must be Ready.
    if (!versionBean.isPublicAPI() && versionBean.getStatus() != ApiStatus.Ready) {
        // $NON-NLS-1$
        throw ExceptionFactory.actionException(Messages.i18n.format("InvalidApiStatus"));
    }
    if (versionBean.isPublicAPI()) {
        if (versionBean.getStatus() == ApiStatus.Retired || versionBean.getStatus() == ApiStatus.Created) {
            // $NON-NLS-1$
            throw ExceptionFactory.actionException(Messages.i18n.format("InvalidApiStatus"));
        }
        if (versionBean.getStatus() == ApiStatus.Published) {
            Date modOn = versionBean.getModifiedOn();
            Date publishedOn = versionBean.getPublishedOn();
            int c = modOn.compareTo(publishedOn);
            if (c <= 0) {
                // $NON-NLS-1$
                throw ExceptionFactory.actionException(Messages.i18n.format("ApiRePublishNotRequired"));
            }
        }
    }
    Api gatewayApi = new Api();
    gatewayApi.setEndpoint(versionBean.getEndpoint());
    gatewayApi.setEndpointType(versionBean.getEndpointType().toString());
    if (versionBean.getEndpointContentType() != null) {
        gatewayApi.setEndpointContentType(versionBean.getEndpointContentType().toString());
    }
    gatewayApi.setEndpointProperties(versionBean.getEndpointProperties());
    gatewayApi.setOrganizationId(versionBean.getApi().getOrganization().getId());
    gatewayApi.setApiId(versionBean.getApi().getId());
    gatewayApi.setVersion(versionBean.getVersion());
    gatewayApi.setPublicAPI(versionBean.isPublicAPI());
    gatewayApi.setParsePayload(versionBean.isParsePayload());
    gatewayApi.setKeysStrippingDisabled(versionBean.getDisableKeysStrip());
    boolean hasTx = false;
    try {
        if (versionBean.isPublicAPI()) {
            List<Policy> policiesToPublish = new ArrayList<>();
            List<PolicySummaryBean> apiPolicies = query.getPolicies(action.getOrganizationId(), action.getEntityId(), action.getEntityVersion(), PolicyType.Api);
            storage.beginTx();
            hasTx = true;
            for (PolicySummaryBean policySummaryBean : apiPolicies) {
                PolicyBean apiPolicy = storage.getPolicy(PolicyType.Api, action.getOrganizationId(), action.getEntityId(), action.getEntityVersion(), policySummaryBean.getId());
                Policy policyToPublish = new Policy();
                policyToPublish.setPolicyJsonConfig(apiPolicy.getConfiguration());
                policyToPublish.setPolicyImpl(apiPolicy.getDefinition().getPolicyImpl());
                policiesToPublish.add(policyToPublish);
            }
            gatewayApi.setApiPolicies(policiesToPublish);
        }
    } catch (StorageException e) {
        // $NON-NLS-1$
        throw ExceptionFactory.actionException(Messages.i18n.format("PublishError"), e);
    } finally {
        if (hasTx) {
            storage.rollbackTx();
        }
    }
    // Publish the API to all relevant gateways
    try {
        storage.beginTx();
        Set<ApiGatewayBean> gateways = versionBean.getGateways();
        if (gateways == null) {
            // $NON-NLS-1$
            throw new PublishingException("No gateways specified for API!");
        }
        for (ApiGatewayBean apiGatewayBean : gateways) {
            IGatewayLink gatewayLink = createGatewayLink(apiGatewayBean.getGatewayId());
            gatewayLink.publishApi(gatewayApi);
            gatewayLink.close();
        }
        versionBean.setStatus(ApiStatus.Published);
        versionBean.setPublishedOn(new Date());
        ApiBean api = storage.getApi(action.getOrganizationId(), action.getEntityId());
        if (api == null) {
            // $NON-NLS-1$ //$NON-NLS-2$
            throw new PublishingException("Error: could not find API - " + action.getOrganizationId() + "=>" + action.getEntityId());
        }
        if (api.getNumPublished() == null) {
            api.setNumPublished(1);
        } else {
            api.setNumPublished(api.getNumPublished() + 1);
        }
        storage.updateApi(api);
        storage.updateApiVersion(versionBean);
        storage.createAuditEntry(AuditUtils.apiPublished(versionBean, securityContext));
        storage.commitTx();
    } catch (PublishingException e) {
        storage.rollbackTx();
        // $NON-NLS-1$
        throw ExceptionFactory.actionException(Messages.i18n.format("PublishError"), e);
    } catch (Exception e) {
        storage.rollbackTx();
        // $NON-NLS-1$
        throw ExceptionFactory.actionException(Messages.i18n.format("PublishError"), e);
    }
    log.debug(// $NON-NLS-1$
    String.format(// $NON-NLS-1$
    "Successfully published API %s on specified gateways: %s", versionBean.getApi().getName(), versionBean.getApi()));
}
Also used : Policy(io.apiman.gateway.engine.beans.Policy) PolicySummaryBean(io.apiman.manager.api.beans.summary.PolicySummaryBean) PolicyBean(io.apiman.manager.api.beans.policies.PolicyBean) ArrayList(java.util.ArrayList) Date(java.util.Date) IGatewayLink(io.apiman.manager.api.gateway.IGatewayLink) ApiVersionNotFoundException(io.apiman.manager.api.rest.exceptions.ApiVersionNotFoundException) StorageException(io.apiman.manager.api.core.exceptions.StorageException) GatewayNotFoundException(io.apiman.manager.api.rest.exceptions.GatewayNotFoundException) NotAuthorizedException(io.apiman.manager.api.rest.exceptions.NotAuthorizedException) ActionException(io.apiman.manager.api.rest.exceptions.ActionException) PlanVersionNotFoundException(io.apiman.manager.api.rest.exceptions.PlanVersionNotFoundException) PublishingException(io.apiman.gateway.engine.beans.exceptions.PublishingException) ClientVersionNotFoundException(io.apiman.manager.api.rest.exceptions.ClientVersionNotFoundException) ApiVersionNotFoundException(io.apiman.manager.api.rest.exceptions.ApiVersionNotFoundException) ApiBean(io.apiman.manager.api.beans.apis.ApiBean) ApiGatewayBean(io.apiman.manager.api.beans.apis.ApiGatewayBean) PublishingException(io.apiman.gateway.engine.beans.exceptions.PublishingException) Api(io.apiman.gateway.engine.beans.Api) ApiVersionBean(io.apiman.manager.api.beans.apis.ApiVersionBean) StorageException(io.apiman.manager.api.core.exceptions.StorageException)

Example 2 with Api

use of io.apiman.gateway.engine.beans.Api in project apiman by apiman.

the class ApiRequestExecutorImpl method createRequestChain.

/**
 * Creates the chain used to apply policies in order to the api request.
 */
private Chain<ApiRequest> createRequestChain(IAsyncHandler<ApiRequest> requestHandler) {
    RequestChain chain = new RequestChain(policyImpls, context);
    chain.headHandler(requestHandler);
    chain.policyFailureHandler(failure -> {
        // It will likely not have been initialised, so create one.
        if (responseChain == null) {
            // Its response will not be used as we take the failure path only, so we just use an empty lambda.
            responseChain = createResponseChain((ignored) -> {
            });
        }
        responseChain.doFailure(failure);
    });
    chain.policyErrorHandler(policyErrorHandler);
    return chain;
}
Also used : Date(java.util.Date) IPayloadIO(io.apiman.gateway.engine.io.IPayloadIO) JsonPayloadIO(io.apiman.gateway.engine.io.JsonPayloadIO) ApiResponse(io.apiman.gateway.engine.beans.ApiResponse) IAsyncResult(io.apiman.gateway.engine.async.IAsyncResult) RequestChain(io.apiman.gateway.engine.policy.RequestChain) BytesPayloadIO(io.apiman.gateway.engine.io.BytesPayloadIO) IAsyncResultHandler(io.apiman.gateway.engine.async.IAsyncResultHandler) Map(java.util.Map) IApiConnector(io.apiman.gateway.engine.IApiConnector) GatewayConfigProperties(io.apiman.gateway.engine.GatewayConfigProperties) StrSubstitutor(org.apache.commons.lang3.text.StrSubstitutor) ISignalWriteStream(io.apiman.gateway.engine.io.ISignalWriteStream) RequestAbortedException(io.apiman.gateway.engine.beans.exceptions.RequestAbortedException) RequestMetric(io.apiman.gateway.engine.metrics.RequestMetric) IDataPolicy(io.apiman.gateway.engine.policy.IDataPolicy) Policy(io.apiman.gateway.engine.beans.Policy) Set(java.util.Set) PolicyFailure(io.apiman.gateway.engine.beans.PolicyFailure) IConnectorInterceptor(io.apiman.gateway.engine.policy.IConnectorInterceptor) List(java.util.List) IApimanBuffer(io.apiman.gateway.engine.io.IApimanBuffer) InvalidApiException(io.apiman.gateway.engine.beans.exceptions.InvalidApiException) Messages(io.apiman.gateway.engine.i18n.Messages) IRegistry(io.apiman.gateway.engine.IRegistry) Entry(java.util.Map.Entry) IApiConnection(io.apiman.gateway.engine.IApiConnection) Chain(io.apiman.gateway.engine.policy.Chain) IPolicy(io.apiman.gateway.engine.policy.IPolicy) IApiConnectionResponse(io.apiman.gateway.engine.IApiConnectionResponse) PolicyContextKeys(io.apiman.gateway.engine.policy.PolicyContextKeys) AsyncResultImpl(io.apiman.gateway.engine.async.AsyncResultImpl) TreeSet(java.util.TreeSet) ArrayList(java.util.ArrayList) PolicyWithConfiguration(io.apiman.gateway.engine.policy.PolicyWithConfiguration) HashSet(java.util.HashSet) ApimanStrLookup(io.apiman.common.util.ApimanStrLookup) SoapPayloadIO(io.apiman.gateway.engine.io.SoapPayloadIO) IConnectorConfig(io.apiman.gateway.engine.IConnectorConfig) IApiRequestExecutor(io.apiman.gateway.engine.IApiRequestExecutor) RequiredAuthType(io.apiman.gateway.engine.auth.RequiredAuthType) IBufferFactoryComponent(io.apiman.gateway.engine.components.IBufferFactoryComponent) StrLookup(org.apache.commons.lang3.text.StrLookup) IEngineResult(io.apiman.gateway.engine.IEngineResult) ByteBuffer(io.apiman.gateway.engine.io.ByteBuffer) InvalidContractException(io.apiman.gateway.engine.beans.exceptions.InvalidContractException) ApiRequest(io.apiman.gateway.engine.beans.ApiRequest) Api(io.apiman.gateway.engine.beans.Api) ResponseChain(io.apiman.gateway.engine.policy.ResponseChain) ApiNotFoundException(io.apiman.gateway.engine.beans.exceptions.ApiNotFoundException) IMetrics(io.apiman.gateway.engine.IMetrics) IConnectorFactory(io.apiman.gateway.engine.IConnectorFactory) IAsyncHandler(io.apiman.gateway.engine.async.IAsyncHandler) IPolicyContext(io.apiman.gateway.engine.policy.IPolicyContext) ApiContract(io.apiman.gateway.engine.beans.ApiContract) IPolicyFactory(io.apiman.gateway.engine.policy.IPolicyFactory) XmlPayloadIO(io.apiman.gateway.engine.io.XmlPayloadIO) RequestChain(io.apiman.gateway.engine.policy.RequestChain)

Example 3 with Api

use of io.apiman.gateway.engine.beans.Api in project apiman by apiman.

the class ApiResourceImpl method retire.

/**
 * @see IApiResource#retire(java.lang.String, java.lang.String, java.lang.String)
 */
@Override
public void retire(String organizationId, String apiId, String version) throws RegistrationException, NotAuthorizedException {
    final Set<Throwable> errorHolder = new HashSet<>();
    final CountDownLatch latch = new CountDownLatch(1);
    Api api = new Api();
    api.setOrganizationId(organizationId);
    api.setApiId(apiId);
    api.setVersion(version);
    // Retire api; latch until result returned and evaluated
    getEngine().getRegistry().retireApi(api, latchedResultHandler(latch, errorHolder));
    awaitOnLatch(latch, errorHolder);
}
Also used : Api(io.apiman.gateway.engine.beans.Api) CountDownLatch(java.util.concurrent.CountDownLatch) HashSet(java.util.HashSet)

Example 4 with Api

use of io.apiman.gateway.engine.beans.Api in project apiman by apiman.

the class ActionService method retireApi.

/**
 * Retires an API that is currently published to the Gateway.
 */
public void retireApi(String orgId, String apiId, String apiVersion) throws ActionException, NotAuthorizedException {
    ApiVersionBean versionBean;
    try {
        versionBean = storage.getApiVersion(orgId, apiId, apiVersion);
    } catch (ApiVersionNotFoundException e) {
        // $NON-NLS-1$
        throw ExceptionFactory.actionException(Messages.i18n.format("ApiNotFound"));
    } catch (StorageException e) {
        throw new RuntimeException(e);
    }
    // Validate that it's ok to perform this action - API must be Published.
    if (versionBean.getStatus() != ApiStatus.Published) {
        // $NON-NLS-1$
        throw ExceptionFactory.actionException(Messages.i18n.format("InvalidApiStatus"));
    }
    Api gatewayApi = new Api();
    gatewayApi.setOrganizationId(versionBean.getApi().getOrganization().getId());
    gatewayApi.setApiId(versionBean.getApi().getId());
    gatewayApi.setVersion(versionBean.getVersion());
    // Retire the API from all relevant gateways
    try {
        Set<ApiGatewayBean> gateways = versionBean.getGateways();
        if (gateways == null) {
            // $NON-NLS-1$
            throw new PublishingException("No gateways specified for API!");
        }
        for (ApiGatewayBean apiGatewayBean : gateways) {
            IGatewayLink gatewayLink = createGatewayLink(apiGatewayBean.getGatewayId());
            gatewayLink.retireApi(gatewayApi);
            gatewayLink.close();
        }
        versionBean.setStatus(ApiStatus.Retired);
        versionBean.setRetiredOn(new Date());
        ApiBean api = storage.getApi(orgId, apiId);
        if (api == null) {
            // $NON-NLS-1$ //$NON-NLS-2$
            throw new PublishingException("Error: could not find API - " + orgId + "=>" + apiId);
        }
        if (api.getNumPublished() == null || api.getNumPublished() == 0) {
            api.setNumPublished(0);
        } else {
            api.setNumPublished(api.getNumPublished() - 1);
        }
        storage.updateApi(api);
        storage.updateApiVersion(versionBean);
        storage.createAuditEntry(AuditUtils.apiRetired(versionBean, securityContext));
    } catch (Exception e) {
        // $NON-NLS-1$
        throw ExceptionFactory.actionException(Messages.i18n.format("RetireError"), e);
    }
    LOGGER.debug(// $NON-NLS-1$
    String.format(// $NON-NLS-1$
    "Successfully retired API %s on specified gateways: %s", versionBean.getApi().getName(), versionBean.getApi()));
}
Also used : ApiBean(io.apiman.manager.api.beans.apis.ApiBean) ApiGatewayBean(io.apiman.manager.api.beans.apis.ApiGatewayBean) PublishingException(io.apiman.gateway.engine.beans.exceptions.PublishingException) Api(io.apiman.gateway.engine.beans.Api) ApiVersionBean(io.apiman.manager.api.beans.apis.ApiVersionBean) StorageException(io.apiman.manager.api.core.exceptions.StorageException) IGatewayLink(io.apiman.manager.api.gateway.IGatewayLink) Date(java.util.Date) ApiVersionNotFoundException(io.apiman.manager.api.rest.exceptions.ApiVersionNotFoundException) StorageException(io.apiman.manager.api.core.exceptions.StorageException) GatewayNotFoundException(io.apiman.manager.api.rest.exceptions.GatewayNotFoundException) NotAuthorizedException(io.apiman.manager.api.rest.exceptions.NotAuthorizedException) ActionException(io.apiman.manager.api.rest.exceptions.ActionException) PlanVersionNotFoundException(io.apiman.manager.api.rest.exceptions.PlanVersionNotFoundException) PublishingException(io.apiman.gateway.engine.beans.exceptions.PublishingException) ClientVersionNotFoundException(io.apiman.manager.api.rest.exceptions.ClientVersionNotFoundException) ApiVersionNotFoundException(io.apiman.manager.api.rest.exceptions.ApiVersionNotFoundException)

Example 5 with Api

use of io.apiman.gateway.engine.beans.Api in project apiman by apiman.

the class ActionService method unregisterClient.

/**
 * De-registers an client that is currently registered with the gateway.
 */
public void unregisterClient(String orgId, String clientId, String clientVersion) throws ActionException, NotAuthorizedException {
    ClientVersionBean versionBean;
    List<ContractSummaryBean> contractBeans;
    try {
        versionBean = clientAppService.getClientVersion(orgId, clientId, clientVersion);
    } catch (ClientVersionNotFoundException e) {
        // $NON-NLS-1$
        throw ExceptionFactory.actionException(Messages.i18n.format("ClientNotFound"));
    }
    try {
        contractBeans = query.getClientContracts(orgId, clientId, clientVersion).stream().peek(c -> {
            if (c.getStatus() != ContractStatus.Created) {
                LOGGER.debug("Will not try to delete contract {0} from gateway(s) as it is not in 'Created' state", c);
            }
        }).filter(c -> c.getStatus() == ContractStatus.Created).collect(Collectors.toList());
    } catch (StorageException e) {
        // $NON-NLS-1$
        throw ExceptionFactory.actionException(Messages.i18n.format("ClientNotFound"), e);
    }
    // Validate that it's ok to perform this action - client must be either registered or awaiting approval (or there's nothing to unregister)
    if (versionBean.getStatus() != ClientStatus.Registered && versionBean.getStatus() != ClientStatus.AwaitingApproval) {
        // $NON-NLS-1$
        throw ExceptionFactory.actionException(Messages.i18n.format("InvalidClientStatus"));
    }
    Client client = new Client();
    client.setOrganizationId(versionBean.getClient().getOrganization().getId());
    client.setClientId(versionBean.getClient().getId());
    client.setVersion(versionBean.getVersion());
    // Each of those gateways must be told about the client.
    try {
        Map<String, IGatewayLink> links = new HashMap<>();
        for (ContractSummaryBean contractBean : contractBeans) {
            ApiVersionBean svb = storage.getApiVersion(contractBean.getApiOrganizationId(), contractBean.getApiId(), contractBean.getApiVersion());
            Set<ApiGatewayBean> gateways = svb.getGateways();
            if (gateways == null) {
                // $NON-NLS-1$
                throw new PublishingException("No gateways specified for API: " + svb.getApi().getName());
            }
            for (ApiGatewayBean apiGatewayBean : gateways) {
                if (!links.containsKey(apiGatewayBean.getGatewayId())) {
                    IGatewayLink gatewayLink = createGatewayLink(apiGatewayBean.getGatewayId());
                    links.put(apiGatewayBean.getGatewayId(), gatewayLink);
                }
            }
        }
        for (IGatewayLink gatewayLink : links.values()) {
            gatewayLink.unregisterClient(client);
            gatewayLink.close();
        }
    } catch (Exception e) {
        // $NON-NLS-1$
        throw ExceptionFactory.actionException(Messages.i18n.format("UnregisterError"), e);
    }
    ClientStatus oldStatus = versionBean.getStatus();
    versionBean.setStatus(ClientStatus.Retired);
    versionBean.setRetiredOn(new Date());
    clientAppService.fireClientStatusChangeEvent(versionBean, oldStatus);
    try {
        storage.updateClientVersion(versionBean);
        storage.createAuditEntry(AuditUtils.clientUnregistered(versionBean, securityContext));
    } catch (Exception e) {
        // $NON-NLS-1$
        throw ExceptionFactory.actionException(Messages.i18n.format("UnregisterError"), e);
    }
    LOGGER.debug(// $NON-NLS-1$
    String.format(// $NON-NLS-1$
    "Successfully registered Client %s on specified gateways: %s", versionBean.getClient().getName(), versionBean.getClient()));
}
Also used : ClientVersionBean(io.apiman.manager.api.beans.clients.ClientVersionBean) ContractApprovalEvent(io.apiman.manager.api.beans.events.ContractApprovalEvent) ApiGatewayBean(io.apiman.manager.api.beans.apis.ApiGatewayBean) Date(java.util.Date) ApiVersionNotFoundException(io.apiman.manager.api.rest.exceptions.ApiVersionNotFoundException) StorageException(io.apiman.manager.api.core.exceptions.StorageException) ApiVersionBean(io.apiman.manager.api.beans.apis.ApiVersionBean) ISecurityContext(io.apiman.manager.api.security.ISecurityContext) GatewayNotFoundException(io.apiman.manager.api.rest.exceptions.GatewayNotFoundException) IGatewayLinkFactory(io.apiman.manager.api.gateway.IGatewayLinkFactory) ApimanEventHeaders(io.apiman.manager.api.beans.events.ApimanEventHeaders) UserBean(io.apiman.manager.api.beans.idm.UserBean) Client(io.apiman.gateway.engine.beans.Client) ApiBean(io.apiman.manager.api.beans.apis.ApiBean) UserMapper(io.apiman.manager.api.beans.idm.UserMapper) IClientValidator(io.apiman.manager.api.core.IClientValidator) Map(java.util.Map) URI(java.net.URI) ApimanLoggerFactory(io.apiman.common.logging.ApimanLoggerFactory) Contract(io.apiman.gateway.engine.beans.Contract) OrganizationBean(io.apiman.manager.api.beans.orgs.OrganizationBean) Policy(io.apiman.gateway.engine.beans.Policy) Transactional(javax.transaction.Transactional) IGatewayLink(io.apiman.manager.api.gateway.IGatewayLink) EventService(io.apiman.manager.api.events.EventService) Set(java.util.Set) UUID(java.util.UUID) Streams(com.google.common.collect.Streams) Collectors(java.util.stream.Collectors) ContractStatus(io.apiman.manager.api.beans.contracts.ContractStatus) NotAuthorizedException(io.apiman.manager.api.rest.exceptions.NotAuthorizedException) List(java.util.List) IApimanLogger(io.apiman.common.logging.IApimanLogger) PolicySummaryBean(io.apiman.manager.api.beans.summary.PolicySummaryBean) ContractActionDto(io.apiman.manager.api.beans.actions.ContractActionDto) ApplicationScoped(javax.enterprise.context.ApplicationScoped) ActionException(io.apiman.manager.api.rest.exceptions.ActionException) HashMap(java.util.HashMap) ApiStatus(io.apiman.manager.api.beans.apis.ApiStatus) PolicyBean(io.apiman.manager.api.beans.policies.PolicyBean) AuditUtils(io.apiman.manager.api.rest.impl.audit.AuditUtils) ArrayList(java.util.ArrayList) ContractBean(io.apiman.manager.api.beans.contracts.ContractBean) HashSet(java.util.HashSet) Inject(javax.inject.Inject) PlanVersionNotFoundException(io.apiman.manager.api.rest.exceptions.PlanVersionNotFoundException) PublishingException(io.apiman.gateway.engine.beans.exceptions.PublishingException) IStorageQuery(io.apiman.manager.api.core.IStorageQuery) DataAccessUtilMixin(io.apiman.manager.api.rest.impl.util.DataAccessUtilMixin) PlanVersionBean(io.apiman.manager.api.beans.plans.PlanVersionBean) Iterator(java.util.Iterator) GatewayBean(io.apiman.manager.api.beans.gateways.GatewayBean) ClientStatus(io.apiman.manager.api.beans.clients.ClientStatus) ContractSummaryBean(io.apiman.manager.api.beans.summary.ContractSummaryBean) IStorage(io.apiman.manager.api.core.IStorage) ClientVersionBean(io.apiman.manager.api.beans.clients.ClientVersionBean) ClientVersionNotFoundException(io.apiman.manager.api.rest.exceptions.ClientVersionNotFoundException) Api(io.apiman.gateway.engine.beans.Api) PolicyType(io.apiman.manager.api.beans.policies.PolicyType) Messages(io.apiman.manager.api.rest.exceptions.i18n.Messages) PlanStatus(io.apiman.manager.api.beans.plans.PlanStatus) ExceptionFactory(io.apiman.manager.api.rest.exceptions.util.ExceptionFactory) ClientStatus(io.apiman.manager.api.beans.clients.ClientStatus) ClientVersionNotFoundException(io.apiman.manager.api.rest.exceptions.ClientVersionNotFoundException) HashMap(java.util.HashMap) IGatewayLink(io.apiman.manager.api.gateway.IGatewayLink) ApiVersionNotFoundException(io.apiman.manager.api.rest.exceptions.ApiVersionNotFoundException) StorageException(io.apiman.manager.api.core.exceptions.StorageException) GatewayNotFoundException(io.apiman.manager.api.rest.exceptions.GatewayNotFoundException) NotAuthorizedException(io.apiman.manager.api.rest.exceptions.NotAuthorizedException) ActionException(io.apiman.manager.api.rest.exceptions.ActionException) PlanVersionNotFoundException(io.apiman.manager.api.rest.exceptions.PlanVersionNotFoundException) PublishingException(io.apiman.gateway.engine.beans.exceptions.PublishingException) ClientVersionNotFoundException(io.apiman.manager.api.rest.exceptions.ClientVersionNotFoundException) Date(java.util.Date) ApiGatewayBean(io.apiman.manager.api.beans.apis.ApiGatewayBean) PublishingException(io.apiman.gateway.engine.beans.exceptions.PublishingException) ContractSummaryBean(io.apiman.manager.api.beans.summary.ContractSummaryBean) Client(io.apiman.gateway.engine.beans.Client) StorageException(io.apiman.manager.api.core.exceptions.StorageException) ApiVersionBean(io.apiman.manager.api.beans.apis.ApiVersionBean)

Aggregations

Api (io.apiman.gateway.engine.beans.Api)41 Client (io.apiman.gateway.engine.beans.Client)16 ApiContract (io.apiman.gateway.engine.beans.ApiContract)11 Contract (io.apiman.gateway.engine.beans.Contract)10 Policy (io.apiman.gateway.engine.beans.Policy)10 PublishingException (io.apiman.gateway.engine.beans.exceptions.PublishingException)10 ApiNotFoundException (io.apiman.gateway.engine.beans.exceptions.ApiNotFoundException)8 ApiRetiredException (io.apiman.gateway.engine.beans.exceptions.ApiRetiredException)8 NoContractFoundException (io.apiman.gateway.engine.beans.exceptions.NoContractFoundException)8 ClientNotFoundException (io.apiman.gateway.engine.beans.exceptions.ClientNotFoundException)7 ApiGatewayBean (io.apiman.manager.api.beans.apis.ApiGatewayBean)7 ApiVersionBean (io.apiman.manager.api.beans.apis.ApiVersionBean)7 StorageException (io.apiman.manager.api.core.exceptions.StorageException)7 IGatewayLink (io.apiman.manager.api.gateway.IGatewayLink)7 ArrayList (java.util.ArrayList)7 Date (java.util.Date)7 RegistrationException (io.apiman.gateway.engine.beans.exceptions.RegistrationException)6 ApiBean (io.apiman.manager.api.beans.apis.ApiBean)6 ActionException (io.apiman.manager.api.rest.exceptions.ActionException)6 ApiVersionNotFoundException (io.apiman.manager.api.rest.exceptions.ApiVersionNotFoundException)6