Squashed merge: Add elements exclude mode
* Start working on elements enhancement
* Work on elements projection
* Work on elements filter
* Feature is now working
* Just some cleanup
* Address compile issues
Squashed commit adding subscription debug logger
* Work on subscription debug logger
* Add subscription logging interceptor
* Remove unneeded variables
* A bit of cleanup
* Tweak the output logs a bit
* Address review comments
* Fixed a bug in standalone subscription subscriber: It was adding REQUESTED subscriptions to the active subscription registry. (Only ACTIVE subscriptions should be added.)
* Start work on this
* Work on interceptors
* Attempt fix
* Avoid environment dependency
* Test fixes
* One more test fix
* One more build tweak
* Lots of cleanup
* A bit more cleanup
* Still more cleanup
* Some test fixes
* Add legacy methods temporarily
* Don't auto-scan interceptor beans
* One more test fix
* rsolve merge conflicts
* Address review comments
SearchParamRegistry and SubscriptionRegistry now both poll retrying connection to the server. This will help in particular in the scenario where the subscriptions are managed in a standalone server that depends on a FHIR Server being available to pull search parameters and subscriptions from.
* Reorganizing packages and dependencies to support standalone subscription running within a CDR container where all hapi modules are on the classpath.
* EXPERIMENTAL: Moved Subscription registry out of interceptor and introduced ISubscriptionLoader that will be either a Database or FhirClient loader.
5 tests fail. Looks like we're getting too many matches--likely because there is now just one list of subscriptions instead of one list per interceptor.
* Created ActiveSubscription and moved cache bits into it
* Compiles. Next step is get app context to load.
* Application context loads. Now fix NullPointer.
* All subscription tests pass
* FIXME cleanup
* jpa-subscription tests
* fixed config so other module tests work
* MAJOR MILESTONE: All hapi-fhir tests pass.
updated READMEs in example projects
* Moved ExecutorQueue stuff out into its own class
* Organize Imports
* FIXME cleanup
* Null check -> Optional
* Add test and supporting code to validate SubscriptionConstants.EXT_SUBSCRIPTION_RESTHOOK_DELIVER_LATEST_VERSION behaviour
* Added SubscriptionCheckingSubscriber test that works without a database
* Moved a few beans to @ComponentScan
* Replaced use of beanFactory with concrete factory classes
* Switched test to use subscribablechannel
* Added SubscriptionLoaderFhirClientTest
* Undid changes that caused SearchParamProviderFhirClientTest to revert to the Database version. It's now calling the FhirClient version again. (oops)
* Confirm that our SubscriptionProviderFhirClient works with a live fhir client
* Organize imports
* Organize imports
* Register interceptors with DaoConfig instead of RestServer.
Also, Rename @VisibleForTesting methods with ForUnitTest
* Ready to go
* organize imports
* add processing queue
* Fixed interface implementation names
* Fix triggering service so it uses new subscriptionmatcherinterceptor
* fixed example
* Renamed "Database" classes to "Dao"
* Tightened up StoppableSubscriber API
* final code review
* processing -> matching naming change
* fix required by CDR
* oops
* Updated changes.xml
* Renamed subscriptioncheckingsubscriber to subscriptionmatchingsubscriber
* Renamed subscriptioncheckingsubscriber to subscriptionmatchingsubscriber
* CDR integration now works
* Changing subscribable channel abstraction layer in preparation for supporting more types of subscribable channels
* Add interface over both types of messages put on queues
* cosmetic change
* added subscription support for r4
* fixed again
* oops
* self code-review
* Reorganizing packages and dependencies to support standalone subscription running within a CDR container where all hapi modules are on the classpath.
Moved Subscription registry out of interceptor and introduced SubscriptionLoader
* Created ActiveSubscription and moved cache bits into it
* Moved ExecutorQueue stuff out into its own class
* Add test and supporting code to validate SubscriptionConstants.EXT_SUBSCRIPTION_RESTHOOK_DELIVER_LATEST_VERSION behaviour
* Added SubscriptionCheckingSubscriber
* Moved a few beans to @ComponentScan
* Replaced use of beanFactory with concrete factory classes
* Switched test to use subscribablechannel
* Added SubscriptionLoaderFhirClientTest
* Confirm that our SubscriptionProviderFhirClient works with a live fhir client
* Register interceptors with DaoConfig instead of RestServer.
Also, Rename @VisibleForTesting methods with ForUnitTest
* Fix triggering service so it uses new subscriptionmatcherinterceptor
* Renamed "Database" classes to "Dao"
* processing -> matching naming change
* Initial refactoring to move database matcher out into its own class
* MAJOR REFACTOR: Pulled indexing code out of BaseHapiFhirDao into a new class ResourceIndexedSearchParams
* Moved calculateHashes
* Replaced @Bean definitions in BaseConfig.java with @ComponentScan
Annotated bean classes with either @Service (if it's stateless) or @Component (if it's stateful). It doesn't really matter which annotation is used, but it's helpful to see at a glance whether a bean is stateful or stateless.
* Move services out of BaseHapiFhirDao
Moved services required by ResourceIndexedSearchParams out of BaseHapiFhirDao and into new classes called LogicalReferenceHelper, IdHelperService, MatchUrlService, and DaoProvider.
Converted SearchBuilder into Prototype Bean
Mark Spring components that depend on daos and entitymanagers with @Lazy so they aren't picked up by hapi-fhir-spring-boot-autoconfigure.
* Added SubscriptionMatcherInMemory
Moved static data out of BaseHapiFhirDao into ResourceMetaParams
Moved translateMatchUrl methods out of BaseHapiFhirDao into MatchUrlService bean
Simplified SubscriptionMatcherInMemory to not depend on entity or dao
Turned all subscribers into prototype beans
* Moved searchParam method out to mySearchParamProvider
Also removed dao and contest parameters from of myMatchUrlService methods
Moved code out of SearchBuilder into SearchParameterMap.clean() so it can be used by inMemoryMatcher
Introduced a new composite subscription matcher that tries to match in memory and if it finds a parameter in the criteria it doesn't support, it falls back to the database matcher.
* Added support for references
Also fixed a small bug in SearchParameterMap that was missing the ";" after "_has" when creating a normalized query from search params.
* Finished implementing all tests from FhirResourceDaoR4SearchNoFtTest
* Make in-memory matcher configurable, disabled by default
* Validate Subscription criteria when they're submitted
Send HTTP 422 UnprocessableEntityException if the criteria fail validation.
* fixed Sonar "Blocker" issues.
* Don't reload the resource before sending it out
Since we can always force a reload using restHookDetails.isDeliverLatestVersion
* Added tests to cover Custom Search param.
* Split ResourceIndexedSearchParam into separate state and service classes
* Cleaned up SearchBuilder.
Removed uses of myCallingDao as an injection mechanism.
Left // FIXME KHS cookie crumbs to clean up
* Reduced dependencies on BaseHapiFhirDao
Removed methods from IDao interface that were used for injection
* Updated change log
* Initial refactoring to move database matcher out into its own class
* MAJOR REFOACTOR: Pulled indexing code out of BaseHapiFhirDao into a new class ResourceIndexedSearchParams
* made observations lists thread safe to stop intermittent test failures