@Bean(name = "mySystemProviderDstu2") public ca.uhn.fhir.jpa.provider.JpaSystemProviderDstu2 systemProviderDstu2() { ca.uhn.fhir.jpa.provider.JpaSystemProviderDstu2 retVal = new ca.uhn.fhir.jpa.provider.JpaSystemProviderDstu2(); retVal.setDao(systemDaoDstu2()); retVal.setContext(fhirContextDstu2()); return retVal; }
@Override public FhirContext fhirContext() { return fhirContextDstu2(); }
@Bean(name = "myInstanceValidatorDstu2") @Lazy public IValidatorModule instanceValidatorDstu2() { FhirInstanceValidator retVal = new FhirInstanceValidator(); retVal.setBestPracticeWarningLevel(IResourceValidator.BestPracticeWarningLevel.Warning); retVal.setValidationSupport(new CachingValidationSupport(new ValidationSupportChain(new DefaultProfileValidationSupport(), jpaValidationSupportDstu2()))); return retVal; }
@Bean(name = "myResourceCountsCache") public ResourceCountCache resourceCountsCache() { ResourceCountCache retVal = new ResourceCountCache(() -> systemDaoDstu2().getResourceCounts()); retVal.setCacheMillis(60 * DateUtils.MILLIS_PER_SECOND); return retVal; }
@Bean @Primary public FhirContext defaultFhirContext() { return fhirContextDstu2(); }
@Bean(name = "myInstanceValidatorDstu2") @Lazy public IValidatorModule instanceValidatorDstu2() { FhirInstanceValidator retVal = new FhirInstanceValidator(); retVal.setBestPracticeWarningLevel(IResourceValidator.BestPracticeWarningLevel.Warning); retVal.setValidationSupport(new CachingValidationSupport(new ValidationSupportChain(new DefaultProfileValidationSupport(), jpaValidationSupportDstu2()))); return retVal; }
@Bean(name = "myResourceCountsCache") public ResourceCountCache resourceCountsCache() { ResourceCountCache retVal = new ResourceCountCache(() -> systemDaoDstu2().getResourceCounts()); retVal.setCacheMillis(60 * DateUtils.MILLIS_PER_SECOND); return retVal; }
@Bean(name = "mySystemProviderDstu2") public ca.uhn.fhir.jpa.provider.JpaSystemProviderDstu2 systemProviderDstu2() { ca.uhn.fhir.jpa.provider.JpaSystemProviderDstu2 retVal = new ca.uhn.fhir.jpa.provider.JpaSystemProviderDstu2(); retVal.setDao(systemDaoDstu2()); retVal.setContext(fhirContextDstu2()); return retVal; }
@Override public FhirContext fhirContext() { return fhirContextDstu2(); }
@Bean @Primary public FhirContext defaultFhirContext() { return fhirContextDstu2(); }