Kuali Rice Development
  1. Kuali Rice Development
  2. KULRICE-5808

Fix cache errors when injecting service containing cache annotations with spring

    Details

    • Type: Task Task
    • Status: Closed Closed
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.0.0-b1, 2.0
    • Security Level: Public (Public: Anyone can view)
    • Labels:
      None
    • Similar issues:
      KULRICE-11840TermRepositoryService Spring injected needed
      KULRICE-2351Remove the need to inject "cache" into the KSBConfigurer
      KULRICE-5941Determine the proper way to handle client-side caching and eviction operations
      KULRICE-3007Implement caching in the RiceApplicationConfigurationMediationServiceImpl
      KULRICE-5942See if we can improve our cache flushing with new Spring cache annotations
      KULRICE-5638Figure out how to make caching possible for services in the core module
      KULRICE-7258Implement caching on ExtensionRepositoryService
      KULRICE-8955MessageServiceImpl getDefaultLocaleCode Caching
      KULRICE-8714Bug related to caching used to improve role service performance.
      KULRICE-11278Add caching annotations to translate Natural Language methods in the KRMS RuleManagementService
    • KAI Review Status:
      Not Required
    • KTI Review Status:
      Not Required

      Description

      We are getting errors saying the cache can't be found when we are injecting a service containing cache annotations with spring.

      Example integration test is PeopleFlowRoutingTest, where RoleService is injected into the peopleFlowRequestGenerator in KEWSpringBeans.

      2011-10-21 20:30:04,165 [main] ERROR org.kuali.rice.kew.engine.node.RequestsNode - Caught exception routing
      java.lang.IllegalArgumentException: Cannot find cache named http://rice.kuali.org/kim/v2_0/RoleType for CacheDefinition[public abstract org.kuali.rice.kim.api.role.Role org.kuali.rice.kim.api.role.RoleService.getRole(java.lang.String) throws org.kuali.rice.core.api.exception.RiceIllegalArgumentException] caches=http://rice.kuali.org/kim/v2_0/RoleType | condition='' | key=''id=' + #p0'
      at org.springframework.cache.interceptor.CacheAspectSupport.getCaches(CacheAspectSupport.java:163)
      at org.springframework.cache.interceptor.CacheAspectSupport$CacheOperationContext.<init>(CacheAspectSupport.java:303)
      at org.springframework.cache.interceptor.CacheAspectSupport.getOperationContext(CacheAspectSupport.java:173)
      at org.springframework.cache.interceptor.CacheAspectSupport.execute(CacheAspectSupport.java:196)
      at org.springframework.cache.interceptor.CacheInterceptor.invoke(CacheInterceptor.java:66)
      at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
      at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:202)
      at $Proxy129.getRole(Unknown Source)
      at org.kuali.rice.kew.impl.peopleflow.PeopleFlowRequestGeneratorImpl.generateRequestForRoleMember(PeopleFlowRequestGeneratorImpl.java:76)
      at org.kuali.rice.kew.impl.peopleflow.PeopleFlowRequestGeneratorImpl.generateRequestForMember(PeopleFlowRequestGeneratorImpl.java:60)
      at org.kuali.rice.kew.impl.peopleflow.PeopleFlowRequestGeneratorImpl.generateRequests(PeopleFlowRequestGeneratorImpl.java:49)
      at org.kuali.rice.kew.impl.peopleflow.PeopleFlowRouteModule.findActionRequests(PeopleFlowRouteModule.java:58)

        Activity

          People

          • Assignee:
            Jeremy Hanson
            Reporter:
            Jeremy Hanson
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Time Tracking

              Estimated:
              Original Estimate - 1 day
              1d
              Remaining:
              Remaining Estimate - 1 day
              1d
              Logged:
              Time Spent - Not Specified
              Not Specified

                Structure Helper Panel