java.lang.Object
de.iip_ecosphere.platform.support.aas.basyx2.server.apps.submodelRepository.SubmodelRepositorySpringApp
All Implemented Interfaces:
org.springframework.web.servlet.config.annotation.WebMvcConfigurer

@SpringBootApplication @Configuration @ComponentScan(basePackages={"org.eclipse.digitaltwin.basyx","de.iip_ecosphere.platform.support.aas.basyx2.server.apps.security"}, excludeFilters=) public class SubmodelRepositorySpringApp extends Object implements org.springframework.web.servlet.config.annotation.WebMvcConfigurer
Spring application for serving a submodel repository with spring. Somehow feature-based composition does not work in here. More investigation needed.
Author:
Monika Staciwa
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private de.iip_ecosphere.platform.support.aas.AuthenticationDescriptor
     
    private de.iip_ecosphere.platform.support.aas.basyx2.common.AssetServerKeyStoreDescriptor
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    org.eclipse.digitaltwin.basyx.aasrepository.AasRepositoryFactory
    Returns the file repository factory instance.
    private org.springframework.web.reactive.function.client.WebClient
    createWebClient(com.fasterxml.jackson.databind.ObjectMapper mapper)
    Creates the web client.
    void
    extendHandlerExceptionResolvers(List<org.springframework.web.servlet.HandlerExceptionResolver> resolvers)
     
    org.springframework.security.web.SecurityFilterChain
    filterChain(org.springframework.security.config.annotation.web.builders.HttpSecurity http)
    Defines the security filter chain.
    static org.eclipse.digitaltwin.basyx.aasservice.backend.AasBackend
    Returns the AAS backend instance.
    static org.eclipse.digitaltwin.basyx.core.filerepository.FileRepository
    Returns the file repository instance.
    org.eclipse.digitaltwin.basyx.submodelrepository.feature.operation.delegation.OperationDelegation
    getOperationDelegation(com.fasterxml.jackson.databind.ObjectMapper mapper)
    Customizes the operation delegation.
    static org.eclipse.digitaltwin.basyx.submodelrepository.SubmodelRepository
    getSubmodelRepository(org.eclipse.digitaltwin.basyx.submodelrepository.feature.operation.delegation.OperationDelegation operationDelegation, de.iip_ecosphere.platform.support.aas.AuthenticationDescriptor authDesc)
    Returns the submodel repository instance.
    org.eclipse.digitaltwin.basyx.submodelservice.SubmodelServiceFactory
    Returns the submodel service factory.
    static void
    main(String[] args)
    Starts the application.

    Methods inherited from class java.lang.Object

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

    Methods inherited from interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer

    addArgumentResolvers, addCorsMappings, addErrorResponseInterceptors, addFormatters, addInterceptors, addResourceHandlers, addReturnValueHandlers, addViewControllers, configureAsyncSupport, configureContentNegotiation, configureDefaultServletHandling, configureHandlerExceptionResolvers, configureMessageConverters, configurePathMatch, configureViewResolvers, extendMessageConverters, getMessageCodesResolver, getValidator
  • Field Details

    • kstore

      @Autowired(required=false) private de.iip_ecosphere.platform.support.aas.basyx2.common.AssetServerKeyStoreDescriptor kstore
    • authDesc

      @Autowired(required=false) private de.iip_ecosphere.platform.support.aas.AuthenticationDescriptor authDesc
  • Constructor Details

    • SubmodelRepositorySpringApp

      public SubmodelRepositorySpringApp()
  • Method Details

    • main

      public static void main(String[] args)
      Starts the application.
      Parameters:
      args - the command line arguments
    • getOperationDelegation

      @Bean public org.eclipse.digitaltwin.basyx.submodelrepository.feature.operation.delegation.OperationDelegation getOperationDelegation(com.fasterxml.jackson.databind.ObjectMapper mapper)
      Customizes the operation delegation. [Copied]
      Parameters:
      mapper - the object mapper to customize
      Returns:
      the operation delegation instance
    • createWebClient

      private org.springframework.web.reactive.function.client.WebClient createWebClient(com.fasterxml.jackson.databind.ObjectMapper mapper)
      Creates the web client.
      Parameters:
      mapper - the object mapper to customize
      Returns:
      the configured web client
    • getSubmodelRepository

      @Bean public static org.eclipse.digitaltwin.basyx.submodelrepository.SubmodelRepository getSubmodelRepository(org.eclipse.digitaltwin.basyx.submodelrepository.feature.operation.delegation.OperationDelegation operationDelegation, @Nullable de.iip_ecosphere.platform.support.aas.AuthenticationDescriptor authDesc)
      Returns the submodel repository instance.
      Parameters:
      operationDelegation - the configured/created operation delegation instance
      authDesc - the actual authentication descriptor
      Returns:
      the instance
    • getAasBackend

      @Bean public static org.eclipse.digitaltwin.basyx.aasservice.backend.AasBackend getAasBackend()
      Returns the AAS backend instance.
      Returns:
      the instance
    • getFileRepository

      @Bean public static org.eclipse.digitaltwin.basyx.core.filerepository.FileRepository getFileRepository()
      Returns the file repository instance.
      Returns:
      the instance
    • aasRepositoryFactory

      @Bean public org.eclipse.digitaltwin.basyx.aasrepository.AasRepositoryFactory aasRepositoryFactory()
      Returns the file repository factory instance.
      Returns:
      the instance
    • getSubmodelServiceFactory

      @Bean @Lazy public org.eclipse.digitaltwin.basyx.submodelservice.SubmodelServiceFactory getSubmodelServiceFactory()
      Returns the submodel service factory.
      Returns:
      the instance
    • filterChain

      @Profile("test") @Bean public org.springframework.security.web.SecurityFilterChain filterChain(org.springframework.security.config.annotation.web.builders.HttpSecurity http) throws Exception
      Defines the security filter chain.
      Parameters:
      http - the security instance
      Returns:
      the filterchain
      Throws:
      Exception - if something fails
    • extendHandlerExceptionResolvers

      public void extendHandlerExceptionResolvers(List<org.springframework.web.servlet.HandlerExceptionResolver> resolvers)
      Specified by:
      extendHandlerExceptionResolvers in interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer