Search in sources :

Example 1 with Repository

use of io.micronaut.data.annotation.Repository in project micronaut-data by micronaut-projects.

the class DataIntroductionAdvice method findInterceptor.

@NonNull
private DataInterceptor<Object, Object> findInterceptor(@Nullable String dataSourceName, @NonNull Class<?> operationsType, @NonNull Class<?> interceptorType) {
    DataInterceptor interceptor;
    if (!RepositoryOperations.class.isAssignableFrom(operationsType)) {
        throw new IllegalArgumentException("Repository type must be an instance of RepositoryOperations!");
    }
    RepositoryOperations datastore;
    try {
        if (dataSourceName != null) {
            Qualifier qualifier = Qualifiers.byName(dataSourceName);
            datastore = (RepositoryOperations) beanLocator.getBean(operationsType, qualifier);
        } else {
            datastore = (RepositoryOperations) beanLocator.getBean(operationsType);
        }
    } catch (NoSuchBeanException e) {
        throw new ConfigurationException("No backing RepositoryOperations configured for repository. Check your configuration and try again", e);
    }
    BeanIntrospection<Object> introspection = BeanIntrospector.SHARED.findIntrospections(ref -> ref.isPresent() && interceptorType.isAssignableFrom(ref.getBeanType())).stream().findFirst().orElseThrow(() -> new DataAccessException("No Data interceptor found for type: " + interceptorType));
    if (introspection.getConstructorArguments().length == 0) {
        interceptor = (DataInterceptor) introspection.instantiate();
    } else {
        interceptor = (DataInterceptor) introspection.instantiate(datastore);
    }
    return interceptor;
}
Also used : RepositoryConfiguration(io.micronaut.data.annotation.RepositoryConfiguration) EmptyResultException(io.micronaut.data.exceptions.EmptyResultException) Qualifier(io.micronaut.context.Qualifier) CompletableFuture(java.util.concurrent.CompletableFuture) Internal(io.micronaut.core.annotation.Internal) InterceptedMethod(io.micronaut.aop.InterceptedMethod) DataMethod(io.micronaut.data.intercept.annotation.DataMethod) CoroutineTxHelper(io.micronaut.transaction.interceptor.CoroutineTxHelper) MethodInterceptor(io.micronaut.aop.MethodInterceptor) Nullable(io.micronaut.core.annotation.Nullable) PrimaryRepositoryOperations(io.micronaut.data.operations.PrimaryRepositoryOperations) Map(java.util.Map) DataAccessException(io.micronaut.data.exceptions.DataAccessException) TransactionSynchronizationManager(io.micronaut.transaction.support.TransactionSynchronizationManager) BeanLocator(io.micronaut.context.BeanLocator) KotlinInterceptedMethod(io.micronaut.aop.kotlin.KotlinInterceptedMethod) ConfigurationException(io.micronaut.context.exceptions.ConfigurationException) ConcurrentHashMap(java.util.concurrent.ConcurrentHashMap) Qualifiers(io.micronaut.inject.qualifiers.Qualifiers) Singleton(jakarta.inject.Singleton) CompletionException(java.util.concurrent.CompletionException) KotlinUtils(io.micronaut.core.util.KotlinUtils) Objects(java.util.Objects) NonNull(io.micronaut.core.annotation.NonNull) CompletionStage(java.util.concurrent.CompletionStage) RepositoryOperations(io.micronaut.data.operations.RepositoryOperations) NoSuchBeanException(io.micronaut.context.exceptions.NoSuchBeanException) MethodInvocationContext(io.micronaut.aop.MethodInvocationContext) AnnotationValue(io.micronaut.core.annotation.AnnotationValue) BeanIntrospection(io.micronaut.core.beans.BeanIntrospection) Repository(io.micronaut.data.annotation.Repository) Inject(jakarta.inject.Inject) BeanIntrospector(io.micronaut.core.beans.BeanIntrospector) PrimaryRepositoryOperations(io.micronaut.data.operations.PrimaryRepositoryOperations) RepositoryOperations(io.micronaut.data.operations.RepositoryOperations) NoSuchBeanException(io.micronaut.context.exceptions.NoSuchBeanException) ConfigurationException(io.micronaut.context.exceptions.ConfigurationException) Qualifier(io.micronaut.context.Qualifier) DataAccessException(io.micronaut.data.exceptions.DataAccessException) NonNull(io.micronaut.core.annotation.NonNull)

Example 2 with Repository

use of io.micronaut.data.annotation.Repository in project micronaut-data by micronaut-projects.

the class RepositoryTypeElementVisitor method processMethodInfo.

private void processMethodInfo(MethodMatchContext methodMatchContext, MethodMatchInfo methodInfo) {
    QueryBuilder queryEncoder = methodMatchContext.getQueryBuilder();
    MethodElement element = methodMatchContext.getMethodElement();
    SourcePersistentEntity entity = methodMatchContext.getRootEntity();
    ParameterElement[] parameters = methodMatchContext.getParameters();
    // populate parameter roles
    for (Map.Entry<String, Element> entry : methodMatchContext.getParametersInRole().entrySet()) {
        methodInfo.addParameterRole(entry.getKey(), entry.getValue().getName());
    }
    List<QueryParameterBinding> parameterBinding = null;
    boolean encodeEntityParameters = false;
    boolean supportsImplicitQueries = methodMatchContext.supportsImplicitQueries();
    QueryResult queryResult = methodInfo.getQueryResult();
    if (queryResult != null) {
        if (methodInfo.isRawQuery()) {
            // no need to annotation since already annotated, just replace the
            // the computed parameter names
            parameterBinding = queryResult.getParameterBindings();
            element.annotate(Query.class, (builder) -> builder.member(DataMethod.META_MEMBER_RAW_QUERY, element.stringValue(Query.class).map(q -> addRawQueryParameterPlaceholders(queryEncoder, queryResult.getQuery(), queryResult.getQueryParts())).orElse(null)));
            ClassElement genericReturnType = methodMatchContext.getReturnType();
            if (methodMatchContext.isTypeInRole(genericReturnType, TypeRole.PAGE) || element.isPresent(Query.class, "countQuery")) {
                QueryResult countQueryResult = methodInfo.getCountQueryResult();
                if (countQueryResult == null) {
                    throw new MatchFailedException("Query returns a Page and does not specify a 'countQuery' member.", element);
                } else {
                    element.annotate(Query.class, (builder) -> builder.member(DataMethod.META_MEMBER_RAW_COUNT_QUERY, addRawQueryParameterPlaceholders(queryEncoder, countQueryResult.getQuery(), countQueryResult.getQueryParts())));
                }
            }
            encodeEntityParameters = methodInfo.isEncodeEntityParameters();
        } else {
            encodeEntityParameters = methodInfo.isEncodeEntityParameters();
            parameterBinding = queryResult.getParameterBindings();
            bindAdditionalParameters(methodMatchContext, entity, parameterBinding, parameters, queryResult.getAdditionalRequiredParameters());
            QueryResult preparedCount = methodInfo.getCountQueryResult();
            if (preparedCount != null) {
                element.annotate(Query.class, annotationBuilder -> {
                    annotationBuilder.value(queryResult.getQuery());
                    annotationBuilder.member(DataMethod.META_MEMBER_COUNT_QUERY, preparedCount.getQuery());
                });
            } else {
                element.annotate(Query.class, annotationBuilder -> {
                    annotationBuilder.value(queryResult.getQuery());
                    String update = queryResult.getUpdate();
                    if (StringUtils.isNotEmpty(update)) {
                        annotationBuilder.member("update", update);
                    }
                });
            }
        }
    }
    ClassElement runtimeInterceptor = methodInfo.getRuntimeInterceptor();
    if (runtimeInterceptor == null) {
        throw new MatchFailedException("Unable to implement Repository method: " + currentRepository.getSimpleName() + "." + element.getName() + "(..). No possible runtime implementations found.", element);
    }
    boolean finalEncodeEntityParameters = encodeEntityParameters;
    List<QueryParameterBinding> finalParameterBinding = parameterBinding;
    element.annotate(DataMethod.class, annotationBuilder -> {
        annotationBuilder.member(DataMethod.META_MEMBER_OPERATION_TYPE, methodInfo.getOperationType());
        annotationBuilder.member(DataMethod.META_MEMBER_ROOT_ENTITY, new AnnotationClassValue<>(entity.getName()));
        // include the roles
        methodInfo.getParameterRoles().forEach(annotationBuilder::member);
        if (methodInfo.isDto()) {
            annotationBuilder.member(DataMethod.META_MEMBER_DTO, true);
        }
        if (methodInfo.isOptimisticLock()) {
            annotationBuilder.member(DataMethod.META_MEMBER_OPTIMISTIC_LOCK, true);
        }
        TypedElement resultType = methodInfo.getResultType();
        if (resultType != null) {
            annotationBuilder.member(DataMethod.META_MEMBER_RESULT_TYPE, new AnnotationClassValue<>(resultType.getName()));
            ClassElement type = resultType.getType();
            if (!TypeUtils.isVoid(type)) {
                annotationBuilder.member(DataMethod.META_MEMBER_RESULT_DATA_TYPE, TypeUtils.resolveDataType(type, dataTypes));
            }
        }
        String idType = resolveIdType(entity);
        if (idType != null) {
            annotationBuilder.member(DataMethod.META_MEMBER_ID_TYPE, idType);
        }
        annotationBuilder.member(DataMethod.META_MEMBER_INTERCEPTOR, new AnnotationClassValue<>(runtimeInterceptor.getName()));
        if (queryResult != null) {
            if (finalParameterBinding.stream().anyMatch(QueryParameterBinding::isExpandable)) {
                annotationBuilder.member(DataMethod.META_MEMBER_EXPANDABLE_QUERY, queryResult.getQueryParts().toArray(new String[0]));
                QueryResult preparedCount = methodInfo.getCountQueryResult();
                if (preparedCount != null) {
                    annotationBuilder.member(DataMethod.META_MEMBER_EXPANDABLE_COUNT_QUERY, preparedCount.getQueryParts().toArray(new String[0]));
                }
            }
            int max = queryResult.getMax();
            if (max > -1) {
                annotationBuilder.member(DataMethod.META_MEMBER_PAGE_SIZE, max);
            }
            long offset = queryResult.getOffset();
            if (offset > 0) {
                annotationBuilder.member(DataMethod.META_MEMBER_PAGE_INDEX, offset);
            }
        }
        Arrays.stream(parameters).filter(p -> p.getGenericType().isAssignable(entity.getName())).findFirst().ifPresent(parameterElement -> annotationBuilder.member(DataMethod.META_MEMBER_ENTITY, parameterElement.getName()));
        if (CollectionUtils.isNotEmpty(finalParameterBinding)) {
            bindParameters(supportsImplicitQueries, finalParameterBinding, finalEncodeEntityParameters, annotationBuilder);
        }
    });
}
Also used : DataType(io.micronaut.data.model.DataType) OrderUtil(io.micronaut.core.order.OrderUtil) Arrays(java.util.Arrays) TypeRole(io.micronaut.data.annotation.TypeRole) Internal(io.micronaut.core.annotation.Internal) DataMethod(io.micronaut.data.intercept.annotation.DataMethod) SoftServiceLoader(io.micronaut.core.io.service.SoftServiceLoader) SqlQueryBuilder(io.micronaut.data.model.query.builder.sql.SqlQueryBuilder) Map(java.util.Map) QueryResult(io.micronaut.data.model.query.builder.QueryResult) AnnotationClassValue(io.micronaut.core.annotation.AnnotationClassValue) PersistentPropertyPath(io.micronaut.data.model.PersistentPropertyPath) PersistentProperty(io.micronaut.data.model.PersistentProperty) SourceParameterExpressionImpl(io.micronaut.data.processor.model.criteria.impl.SourceParameterExpressionImpl) Sort(io.micronaut.data.model.Sort) Query(io.micronaut.data.annotation.Query) Set(java.util.Set) Collectors(java.util.stream.Collectors) GenericRepository(io.micronaut.data.repository.GenericRepository) StringUtils(io.micronaut.core.util.StringUtils) List(java.util.List) AnnotationValue(io.micronaut.core.annotation.AnnotationValue) MethodElement(io.micronaut.inject.ast.MethodElement) MethodMatchInfo(io.micronaut.data.processor.visitors.finders.MethodMatchInfo) QueryParameterBinding(io.micronaut.data.model.query.builder.QueryParameterBinding) Parameter(io.micronaut.context.annotation.Parameter) RepositoryConfiguration(io.micronaut.data.annotation.RepositoryConfiguration) SourcePersistentProperty(io.micronaut.data.processor.model.SourcePersistentProperty) ClassElement(io.micronaut.inject.ast.ClassElement) HashMap(java.util.HashMap) Function(java.util.function.Function) ParameterElement(io.micronaut.inject.ast.ParameterElement) ArrayList(java.util.ArrayList) HashSet(java.util.HashSet) TypeElementVisitor(io.micronaut.inject.visitor.TypeElementVisitor) TypedElement(io.micronaut.inject.ast.TypedElement) Nullable(io.micronaut.core.annotation.Nullable) MethodMatcher(io.micronaut.data.processor.visitors.finders.MethodMatcher) Page(io.micronaut.data.model.Page) Pageable(io.micronaut.data.model.Pageable) TypeUtils(io.micronaut.data.processor.visitors.finders.TypeUtils) Element(io.micronaut.inject.ast.Element) Iterator(java.util.Iterator) Slice(io.micronaut.data.model.Slice) SourcePersistentEntity(io.micronaut.data.processor.model.SourcePersistentEntity) NonNull(io.micronaut.core.annotation.NonNull) BindingParameter(io.micronaut.data.model.query.BindingParameter) VisitorContext(io.micronaut.inject.visitor.VisitorContext) AnnotationValueBuilder(io.micronaut.core.annotation.AnnotationValueBuilder) PersistentEntity(io.micronaut.data.model.PersistentEntity) CollectionUtils(io.micronaut.core.util.CollectionUtils) QueryBuilder(io.micronaut.data.model.query.builder.QueryBuilder) Repository(io.micronaut.data.annotation.Repository) AnnotationMetadata(io.micronaut.core.annotation.AnnotationMetadata) DataMethodQueryParameter(io.micronaut.data.intercept.annotation.DataMethodQueryParameter) Collections(java.util.Collections) QueryParameterBinding(io.micronaut.data.model.query.builder.QueryParameterBinding) Query(io.micronaut.data.annotation.Query) SourcePersistentEntity(io.micronaut.data.processor.model.SourcePersistentEntity) MethodElement(io.micronaut.inject.ast.MethodElement) ClassElement(io.micronaut.inject.ast.ClassElement) ParameterElement(io.micronaut.inject.ast.ParameterElement) TypedElement(io.micronaut.inject.ast.TypedElement) Element(io.micronaut.inject.ast.Element) TypedElement(io.micronaut.inject.ast.TypedElement) MethodElement(io.micronaut.inject.ast.MethodElement) ClassElement(io.micronaut.inject.ast.ClassElement) SqlQueryBuilder(io.micronaut.data.model.query.builder.sql.SqlQueryBuilder) QueryBuilder(io.micronaut.data.model.query.builder.QueryBuilder) QueryResult(io.micronaut.data.model.query.builder.QueryResult) ParameterElement(io.micronaut.inject.ast.ParameterElement) Map(java.util.Map) HashMap(java.util.HashMap)

Example 3 with Repository

use of io.micronaut.data.annotation.Repository in project micronaut-coherence by micronaut-projects.

the class CoherenceDataIntroductionAdvice method findInterceptor.

@NonNull
private DataInterceptor<Object, Object> findInterceptor(@Nullable String dataSourceName, @NonNull Class<?> operationsType, @NonNull Class<?> interceptorType) {
    DataInterceptor interceptor;
    if (!RepositoryOperations.class.isAssignableFrom(operationsType)) {
        throw new IllegalArgumentException("Repository type must be an instance of RepositoryOperations!");
    }
    Qualifier qualifier = Qualifiers.byName(dataSourceName);
    RepositoryOperations datastore;
    try {
        datastore = (RepositoryOperations) beanLocator.getBean(operationsType, qualifier);
    } catch (NoSuchBeanException e) {
        // if there is no explicit configuration, use a DefaultCoherenceRepositoryOperations implementation
        // using the default Coherence session
        datastore = new DefaultCoherenceRepositoryOperations(dataSourceName, (ApplicationContext) beanLocator, (BeanContext) beanLocator);
        ((ApplicationContext) beanLocator).registerSingleton(RepositoryOperations.class, datastore, qualifier);
    }
    BeanIntrospection<Object> introspection = BeanIntrospector.SHARED.findIntrospections(ref -> interceptorType.isAssignableFrom(ref.getBeanType())).stream().findFirst().orElseThrow(() -> new DataAccessException("No Data interceptor found for type: " + interceptorType));
    if (introspection.getConstructorArguments().length == 0) {
        interceptor = (DataInterceptor) introspection.instantiate();
    } else {
        interceptor = (DataInterceptor) introspection.instantiate(datastore);
    }
    return interceptor;
}
Also used : RepositoryConfiguration(io.micronaut.data.annotation.RepositoryConfiguration) BeanContext(io.micronaut.context.BeanContext) Qualifier(io.micronaut.context.Qualifier) DefaultCoherenceRepositoryOperations(io.micronaut.coherence.data.ops.DefaultCoherenceRepositoryOperations) DataInterceptor(io.micronaut.data.intercept.DataInterceptor) DataMethod(io.micronaut.data.intercept.annotation.DataMethod) ApplicationContext(io.micronaut.context.ApplicationContext) MethodInterceptor(io.micronaut.aop.MethodInterceptor) Nullable(io.micronaut.core.annotation.Nullable) PrimaryRepositoryOperations(io.micronaut.data.operations.PrimaryRepositoryOperations) Map(java.util.Map) Ordered(io.micronaut.core.order.Ordered) DataAccessException(io.micronaut.data.exceptions.DataAccessException) BeanLocator(io.micronaut.context.BeanLocator) ConcurrentHashMap(java.util.concurrent.ConcurrentHashMap) Qualifiers(io.micronaut.inject.qualifiers.Qualifiers) Singleton(jakarta.inject.Singleton) NonNull(io.micronaut.core.annotation.NonNull) RepositoryOperations(io.micronaut.data.operations.RepositoryOperations) NoSuchBeanException(io.micronaut.context.exceptions.NoSuchBeanException) MethodInvocationContext(io.micronaut.aop.MethodInvocationContext) AnnotationValue(io.micronaut.core.annotation.AnnotationValue) BeanIntrospection(io.micronaut.core.beans.BeanIntrospection) Repository(io.micronaut.data.annotation.Repository) RepositoryMethodKey(io.micronaut.data.intercept.RepositoryMethodKey) BeanIntrospector(io.micronaut.core.beans.BeanIntrospector) DataInterceptor(io.micronaut.data.intercept.DataInterceptor) DefaultCoherenceRepositoryOperations(io.micronaut.coherence.data.ops.DefaultCoherenceRepositoryOperations) PrimaryRepositoryOperations(io.micronaut.data.operations.PrimaryRepositoryOperations) RepositoryOperations(io.micronaut.data.operations.RepositoryOperations) NoSuchBeanException(io.micronaut.context.exceptions.NoSuchBeanException) DefaultCoherenceRepositoryOperations(io.micronaut.coherence.data.ops.DefaultCoherenceRepositoryOperations) Qualifier(io.micronaut.context.Qualifier) DataAccessException(io.micronaut.data.exceptions.DataAccessException) NonNull(io.micronaut.core.annotation.NonNull)

Example 4 with Repository

use of io.micronaut.data.annotation.Repository in project micronaut-data by micronaut-projects.

the class RepositoryTypeElementVisitor method resolvePersistentEntity.

private SourcePersistentEntity resolvePersistentEntity(MethodElement element, Map<String, Element> parametersInRole) {
    ClassElement returnType = element.getGenericReturnType();
    SourcePersistentEntity entity = resolveEntityForCurrentClass();
    if (entity == null) {
        entity = Utils.resolvePersistentEntity(returnType, entityResolver);
    }
    if (entity != null) {
        List<PersistentProperty> propertiesInRole = entity.getPersistentProperties().stream().filter(pp -> pp.getAnnotationMetadata().hasStereotype(TypeRole.class)).collect(Collectors.toList());
        for (PersistentProperty persistentProperty : propertiesInRole) {
            String role = persistentProperty.getAnnotationMetadata().getValue(TypeRole.class, "role", String.class).orElse(null);
            if (role != null) {
                parametersInRole.put(role, ((SourcePersistentProperty) persistentProperty).getPropertyElement());
            }
        }
        return entity;
    } else {
        throw new MatchFailedException("Could not resolved root entity. Either implement the Repository interface or define the entity as part of the signature", element);
    }
}
Also used : DataType(io.micronaut.data.model.DataType) OrderUtil(io.micronaut.core.order.OrderUtil) Arrays(java.util.Arrays) TypeRole(io.micronaut.data.annotation.TypeRole) Internal(io.micronaut.core.annotation.Internal) DataMethod(io.micronaut.data.intercept.annotation.DataMethod) SoftServiceLoader(io.micronaut.core.io.service.SoftServiceLoader) SqlQueryBuilder(io.micronaut.data.model.query.builder.sql.SqlQueryBuilder) Map(java.util.Map) QueryResult(io.micronaut.data.model.query.builder.QueryResult) AnnotationClassValue(io.micronaut.core.annotation.AnnotationClassValue) PersistentPropertyPath(io.micronaut.data.model.PersistentPropertyPath) PersistentProperty(io.micronaut.data.model.PersistentProperty) SourceParameterExpressionImpl(io.micronaut.data.processor.model.criteria.impl.SourceParameterExpressionImpl) Sort(io.micronaut.data.model.Sort) Query(io.micronaut.data.annotation.Query) Set(java.util.Set) Collectors(java.util.stream.Collectors) GenericRepository(io.micronaut.data.repository.GenericRepository) StringUtils(io.micronaut.core.util.StringUtils) List(java.util.List) AnnotationValue(io.micronaut.core.annotation.AnnotationValue) MethodElement(io.micronaut.inject.ast.MethodElement) MethodMatchInfo(io.micronaut.data.processor.visitors.finders.MethodMatchInfo) QueryParameterBinding(io.micronaut.data.model.query.builder.QueryParameterBinding) Parameter(io.micronaut.context.annotation.Parameter) RepositoryConfiguration(io.micronaut.data.annotation.RepositoryConfiguration) SourcePersistentProperty(io.micronaut.data.processor.model.SourcePersistentProperty) ClassElement(io.micronaut.inject.ast.ClassElement) HashMap(java.util.HashMap) Function(java.util.function.Function) ParameterElement(io.micronaut.inject.ast.ParameterElement) ArrayList(java.util.ArrayList) HashSet(java.util.HashSet) TypeElementVisitor(io.micronaut.inject.visitor.TypeElementVisitor) TypedElement(io.micronaut.inject.ast.TypedElement) Nullable(io.micronaut.core.annotation.Nullable) MethodMatcher(io.micronaut.data.processor.visitors.finders.MethodMatcher) Page(io.micronaut.data.model.Page) Pageable(io.micronaut.data.model.Pageable) TypeUtils(io.micronaut.data.processor.visitors.finders.TypeUtils) Element(io.micronaut.inject.ast.Element) Iterator(java.util.Iterator) Slice(io.micronaut.data.model.Slice) SourcePersistentEntity(io.micronaut.data.processor.model.SourcePersistentEntity) NonNull(io.micronaut.core.annotation.NonNull) BindingParameter(io.micronaut.data.model.query.BindingParameter) VisitorContext(io.micronaut.inject.visitor.VisitorContext) AnnotationValueBuilder(io.micronaut.core.annotation.AnnotationValueBuilder) PersistentEntity(io.micronaut.data.model.PersistentEntity) CollectionUtils(io.micronaut.core.util.CollectionUtils) QueryBuilder(io.micronaut.data.model.query.builder.QueryBuilder) Repository(io.micronaut.data.annotation.Repository) AnnotationMetadata(io.micronaut.core.annotation.AnnotationMetadata) DataMethodQueryParameter(io.micronaut.data.intercept.annotation.DataMethodQueryParameter) Collections(java.util.Collections) SourcePersistentEntity(io.micronaut.data.processor.model.SourcePersistentEntity) TypeRole(io.micronaut.data.annotation.TypeRole) ClassElement(io.micronaut.inject.ast.ClassElement) PersistentProperty(io.micronaut.data.model.PersistentProperty) SourcePersistentProperty(io.micronaut.data.processor.model.SourcePersistentProperty)

Aggregations

AnnotationValue (io.micronaut.core.annotation.AnnotationValue)4 NonNull (io.micronaut.core.annotation.NonNull)4 Nullable (io.micronaut.core.annotation.Nullable)4 Repository (io.micronaut.data.annotation.Repository)4 RepositoryConfiguration (io.micronaut.data.annotation.RepositoryConfiguration)4 DataMethod (io.micronaut.data.intercept.annotation.DataMethod)4 Internal (io.micronaut.core.annotation.Internal)3 Map (java.util.Map)3 MethodInterceptor (io.micronaut.aop.MethodInterceptor)2 MethodInvocationContext (io.micronaut.aop.MethodInvocationContext)2 BeanLocator (io.micronaut.context.BeanLocator)2 Qualifier (io.micronaut.context.Qualifier)2 Parameter (io.micronaut.context.annotation.Parameter)2 NoSuchBeanException (io.micronaut.context.exceptions.NoSuchBeanException)2 AnnotationClassValue (io.micronaut.core.annotation.AnnotationClassValue)2 AnnotationMetadata (io.micronaut.core.annotation.AnnotationMetadata)2 AnnotationValueBuilder (io.micronaut.core.annotation.AnnotationValueBuilder)2 BeanIntrospection (io.micronaut.core.beans.BeanIntrospection)2 BeanIntrospector (io.micronaut.core.beans.BeanIntrospector)2 SoftServiceLoader (io.micronaut.core.io.service.SoftServiceLoader)2