Commit Graph

1036 Commits

Author SHA1 Message Date
michaelabuckley 92db526786
Skip database query when hibernate search fully satisfies search (#3478)
If a query is completely satisfied by Hibernate Search, skip the database.

Co-authored-by: Jaison Baskaran <jaisonb@gmail.com>
2022-03-22 22:41:21 +00:00
Jaison Baskaran 3eb3014d25
Revert change to treat Canonical URLs as Locals (#3483)
* Revert change added in MR: https://github.com/hapifhir/hapi-fhir/pull/3050 to add support for treating Canonical Urls as locals. This is no longer needed as the issue reported in #2843 (_include not working for Canonicals) has been addressed in MR: https://github.com/hapifhir/hapi-fhir/pull/3440
2022-03-22 17:46:10 +00:00
James Agnew f82534ca51
Convert Reindex into Batch2 Job (#3458)
* Start working on reindex job

* Updates

* Ongoing work

* Ongoing work

* Work on reindex

* Reindex work

* Add logging

* Fix typo

* Test fix

* Test fix

* Address fixme

* Liocense header

* Resolve fixme

* Add logging

* Update logs

* Address review comments

* License header

* Test fixes

* Test fix

* Test fixes

* Test fix

* Version bump

* Version bump
2022-03-19 16:07:58 -04:00
jmarchionatto f518f30506
Issue 3450 there is no way to recreate freetext indexes for terminology entities (#3481)
* Add reindex-terminology batch command

* Handle number of thread throttling and concurrency with other terminology batch operations

* Add required dbcp2 dependency

* Fix test

* Improve ConnectionPoolInfoProvider setup. Handle maximum connections.

* Remove java higher version construction

* Remove unused config

* Add reindex terminology integration test.
Reset termConcept counters before pre-expanding, which otherwise accumulate if it was pre-expanded before.

* Address MR comments

* Adjust test to tested class change

* Adjust test to tested class change

Co-authored-by: juan.marchionatto <juan.marchionatto@smilecdr.com>
2022-03-18 15:09:25 -04:00
jmarchionatto e45f7ee9cb
Issue 3450 there is no way to recreate freetext indexes for terminology entities (#3463)
* Add reindex-terminology batch command

* Handle number of thread throttling and concurrency with other terminology batch operations

* Add required dbcp2 dependency

* Fix test

* Improve ConnectionPoolInfoProvider setup. Handle maximum connections.

* Remove java higher version construction

* Remove unused config

* Add reindex terminology integration test.
Reset termConcept counters before pre-expanding, which otherwise accumulate if it was pre-expanded before.

Co-authored-by: juan.marchionatto <juan.marchionatto@smilecdr.com>
2022-03-18 08:39:12 -04:00
Tadgh 17cf1ed9ce
Rel 5 7 1 mergeback (#3480)
* fix handling of common search parameters

* Revert "fix handling of common search parameters"

This reverts commit 89c45eebdc.

* Fix implementation, add test (#3378)

* Fix implementation, add test

* Tighten test

* Rip out dead modules

* Add changelog

* Jr 20220210 handle common search params in contained searches (#3377)

* fix handling of common search parameters

* add support for reference search parameters with multiple paths

* Issue 3357

* Version bump

* Fixed null pointer exception for re-loading subscription on cdr restart and when there's no partition id in the request, and added tests

* added changelogs for this fix

* Fix broken changelog file

* Can't specify specific resource type permissions for bulk export (#3376)

* deny user from exporting without perms

* add unit tests

* add changelog

Co-authored-by: olivia-you <olivia.you@smilecdr.com>

* Make migration donothing as it was added in error

* Remove ehcache

* Add version.yaml:

* Add to sources/javadocs for dist

* Fix typo

* fix up pom

* wip test removing checkstyle plugin from deployable pom

* remove test pom changes, instead just dont deploy to sonatype

* typo

* Version bump

* Add implementation, testing, and changelog

* Add backport info, make aware of 6_0_0

* add jira ref

* Fix test

* Add versionenum

* Remove dups

* Remove unnecessary stuff

Co-authored-by: Jason Roberts <jason.roberts@smilecdr.com>
Co-authored-by: JasonRoberts-smile <85363818+JasonRoberts-smile@users.noreply.github.com>
Co-authored-by: Mark Iantorno <markiantorno@gmail.com>
Co-authored-by: Steven Li <steven@smilecdr.com>
Co-authored-by: Olivia You <46392181+oliviayou@users.noreply.github.com>
Co-authored-by: olivia-you <olivia.you@smilecdr.com>
2022-03-17 22:31:40 -04:00
Mark Iantorno 49e19d9779
Issue 3441 reindex query being ignored (#3451)
https://github.com/hapifhir/hapi-fhir/issues/3441

Co-authored-by: Tadgh <garygrantgraham@gmail.com>
2022-03-14 15:18:43 -04:00
Ken Stevens dfd99c5471
improve search parameter registry logging (#3452)
* Startup log cleanup.  Use cached fhir contexts.

* improve logging

* improve logging

* add full comparator

* wrap resource search param map

* rename wrapped map methods

* add fixmes

* further searchparam encapsulation

* fix regression found by test

* improve logging

* pre-review cleanup

* pre-review cleanup

* bump hapi version

* license

* since I'm bumping hapi-fhir now, improve the api dependency

* licenses
2022-03-09 19:57:38 -05:00
Tadgh 7eb1bd14d1
Do not validate auto-created placeholder resources (#3461)
* Add implementation, testing, and changelog

* add jira ref
2022-03-08 22:22:04 +00:00
samuelwlee2 cde39dcc6c
3423 include with client assigned id partition (#3448)
* changes to doResolvePersistentIds

* make changes to tests

* Add code changes after the review
2022-03-08 11:48:33 -05:00
James Agnew ac80c7ffaa
Search Narrowing by Code Tweaks (#3453)
* Search narrowing tweaks

* Search narrowing tweaks

* Test

* Test fixes

* Try to fix LGTM

* Add license headers

* Test fixes

* Test fixes
2022-03-07 20:27:21 -05:00
jmarchionatto 4b5f75c069
Issue 3421 pre expansion fails for valuesets with more than 1024 concepts (#3434)
* Build search queries involving many predicates avoiding crashing when number is larger than configured BooleanQuery.maxClauseCount

* Add changelog

* Restore temp directory config

Co-authored-by: juan.marchionatto <juan.marchionatto@smilecdr.com>
2022-03-02 14:11:55 -05:00
James Agnew f614eaf6c8
Avoid error when unknown code system behaviour set to warning (#3436)
* Avoid error when unknown code system behaviour set to warning

* Add changelog

* Test fix

* Build fix

* Fixes

* Address review comment
2022-03-01 17:30:59 +00:00
James Agnew 2cba62b4e8
Enable search narrowing on large ValueSets (#3405)
* Enable search narrowing on large ValueSets

* ValueSet improvements

* Work on narrowing

* Work on narrowing

* Work on narrowing

* Work on narrowing

* Add test

* Work on narrowing interceptor

* Work on narrowing

* License headers

* Refactor code narrowing

* Add docs

* Version bump

* Test fix

* Test fixes

* Build fix

* Fixes

* Version bump

* Test fix

* License header updates

* Build fix

* Test fixes

* Test fix

* Test fix

* Docs fix

* Test fix

* Test fix

* Resolve fixme

* Bump

* Force a CI build

* Make CI happen again
2022-03-01 09:16:31 -05:00
Tadgh 68c1015552
Bump core to 5.6.36 (#3433)
* Bump version

* Add changelog, make use of theNoInactive flag

* add test

* remove magic strings
2022-03-01 08:23:48 -05:00
kailiu-smile 1bc6e0e3ae
Smile 2775 package install logs ignore resource validation (#3381)
* Added log to the create() and valiForUpload() methods in the PackageInstallerSvcImpl class

* Added helper methods to extract URL from SearchParameter.Tested and fixed log entries.

* Changelog entry

* Update 3384-Package-Install-added-logs-for-resources-validation.yaml

Co-authored-by: Kai Liu <kliu@Kais-MacBook-Pro.local>
2022-02-28 19:52:43 +00:00
James Agnew b7d1ae217d
New batch framework / Bulk Import (#3387)
* Work on new batch framework

* Work on new batch framework

* Work on new batch framework

* Work on batch

* Compile working

* Work on bulk import

* Adjust import

* Work

* Work on batch

* Bump version

* WOrk on new batch processes

* Work on bath

* Bump to PRE4

* Build fixes

* CLeanup

* Small tweak

* Add exception code

* Test fixes

* Test fixes

* Test fix

* Additional synchronization

* Add license headers

* Test fixes

* Test fixes

* Add changelogs

* Address PG

* Test fix

* Test fix

* Test fixes

* Review notes

* Work on tests

* Test fixes

* Test fix

* Work on tests

* Tets fix

* Test fixes

* Test fixes

* Add missing exception codes

* Test fix

* Test fixes

* More test fixing

* License headers

* Test fix

* Add new test logging

* Work on tests

* Test fixes

* Test fix

* Resolve fixme

* Try to avoid test failure

* Add import command

* Work on storage

* Fix error codes

* Fixes

* License header

* Build fix

* Build fixes

* Fix dep
2022-02-27 16:04:49 -05:00
katiesmilecdr c9b87d7c67
3418 get resource, response doesn't contain total if consent service enabled (#3420)
* throw an exception if parameter in use

* fix string

* add msg code

* fix msg code

* only check _total=accurate

* extract validateParameter()

* update validateParameter
2022-02-24 17:11:14 -05:00
jmarchionatto dbc9427a05
Issue 3391 2588 expand valueset regex include not working (#3410)
* Refactor ValueSet expansion code to simplify property filtering by using new Hibernate search V6 nested classes capabilities; use generic hibernate search queries where possible (mostly everywhere but regex queries) and add R4 integration tests  for both elastic and lucene.

* Refactor ValueSet expansion code to simplify property filtering by using new Hibernate search V6 nested classes capabilities; use generic hibernate search queries where possible (mostly everywhere but regex queries) and add R4 integration tests  for both elastic and lucene.

* Add comment for trick

* Add codes to exception messages

* Add test specific for the fix

* Move changelog to current release. Add upgrade notice.

* Improve fail-fast method

* Update upgrade instructions

* Try luck with new exception codes

* Update hapi-fhir-storage/src/test/java/ca/uhn/fhir/jpa/search/ElasticsearchNestedQueryBuilderUtilTest.java

Add missed quote

Co-authored-by: michaelabuckley <michael.buckley@smilecdr.com>

Co-authored-by: juan.marchionatto <juan.marchionatto@smilecdr.com>
Co-authored-by: michaelabuckley <michael.buckley@smilecdr.com>
2022-02-24 21:32:11 +00:00
jmarchionatto 53c5a9bbeb
Add FK index to avoid timeout when deleting large ValueSet (#3416)
* Add FK index to avoid timeout when deleting large ValueSet

* Add exception to allow same name for index and FK

Co-authored-by: juan.marchionatto <juan.marchionatto@smilecdr.com>
2022-02-23 13:54:30 -05:00
James Agnew cc44deee1a
GraphQL Introspection Support (#3348)
* Start working on graphql Schema

* Start testing

* Work on introspection

* Work on introspection

* Use integers for date ordinals

* Add changelog

* GraphQL updates

* Ongoing wrk

* Cleanup

* Bump core lib

* Add changelog

* Clean up dependencies

* CLeanup

* Add missing message

* Test fix

* Change to force CI
2022-02-22 09:48:57 -05:00
James Agnew 1e2e17784a
Fix parameter count limitation on MSSQL/Oracle large transactions (#3075)
* Fix parameter count limitation on MSSQL/Oracle large transactions

* Changelog fix

* Move changelog

* Force a change to trigger CI

* Test refactoring
2022-02-20 11:52:42 -05:00
Olivia You e55f9d510a
3400 bulk export rules incorrectly applied to group and patient exports (#3403)
* export rules are applied now

* add changelog and test

* add changelog

* Delete 2797-bulk-export-getting-incorrect-group-data.yml

* update test

* add test

Co-authored-by: olivia-you <olivia.you@smilecdr.com>
2022-02-20 11:39:21 -05:00
James Agnew 058e53616f
Use integers for date ordinals (#3346)
* Use integers for date ordinals

* Add changelog

* Adjust changelog
2022-02-19 18:50:18 -05:00
Tadgh 3561672fe7
Rel 5 7 mergeback (#3401)
* fix handling of common search parameters

* Revert "fix handling of common search parameters"

This reverts commit 89c45eebdc.

* Fix implementation, add test (#3378)

* Fix implementation, add test

* Tighten test

* Rip out dead modules

* Add changelog

* Jr 20220210 handle common search params in contained searches (#3377)

* fix handling of common search parameters

* add support for reference search parameters with multiple paths

* Issue 3357

* Version bump

* Fixed null pointer exception for re-loading subscription on cdr restart and when there's no partition id in the request, and added tests

* added changelogs for this fix

* Fix broken changelog file

* Can't specify specific resource type permissions for bulk export (#3376)

* deny user from exporting without perms

* add unit tests

* add changelog

Co-authored-by: olivia-you <olivia.you@smilecdr.com>

* Make migration donothing as it was added in error

* Remove ehcache

* Add version.yaml:

* Add to sources/javadocs for dist

* Fix typo

* fix up pom

* wip test removing checkstyle plugin from deployable pom

* remove test pom changes, instead just dont deploy to sonatype

* typo

* Remove ehcache

Co-authored-by: Jason Roberts <jason.roberts@smilecdr.com>
Co-authored-by: JasonRoberts-smile <85363818+JasonRoberts-smile@users.noreply.github.com>
Co-authored-by: Mark Iantorno <markiantorno@gmail.com>
Co-authored-by: Steven Li <steven@smilecdr.com>
Co-authored-by: Olivia You <46392181+oliviayou@users.noreply.github.com>
Co-authored-by: olivia-you <olivia.you@smilecdr.com>
2022-02-18 19:22:44 +00:00
Patrick Werner 0c5d868f44
encode narratives of contained resources (#3402)
* encode narratives of contained resources
fixes #1466

* encode narratives of contained resources
fixes #1466
2022-02-17 18:54:03 +00:00
Ken Stevens 631391819b
remove hapi jpa spring config hierarchy (#3390)
* initial refactor to remove hapi jpa spring config hierarchy

* fix poms

* fix batch config

* dependency rearrangement arising from further testing

* fix searchDao bean name

* fixed dstu2 tests

* consolidate validation config

* dstu2 validation regression (man dstu2 support is expensive)

* fix test (with WIP comment)

* restore poms

* fix demo projects

* fix build

* bumping version

* rename generated config class
2022-02-16 20:44:03 -05:00
StevenXLi 69a614d823
fixed ticket number to the correct issue number in hapi-fhir (#3393)
Co-authored-by: Steven Li <steven@smilecdr.com>
2022-02-14 18:46:37 +00:00
Tadgh 38912423c1
Remove dead modules (#3380)
* fix handling of common search parameters

* Revert "fix handling of common search parameters"

This reverts commit 89c45eebdc.

* Fix implementation, add test (#3378)

* Fix implementation, add test

* Tighten test

* Rip out dead modules

* Add changelog

Co-authored-by: Jason Roberts <jason.roberts@smilecdr.com>
2022-02-10 16:44:26 -05:00
StevenXLi 7841e578ab
2789 nullpointerexception rest hook subscription is not being triggered when cross partition is (#3370)
* Fixed null pointer exception for re-loading subscription on cdr restart and when there's no partition id in the request, and added tests

* added changelogs for this fix

Co-authored-by: Steven Li <steven@smilecdr.com>
2022-02-10 14:14:41 -05:00
Tadgh 43f570259e Merge branch 'rel_5_7' 2022-02-10 08:44:07 -08:00
michaelabuckley 3531d9b4fc
Fix exception when contained indexing met hibernate search. (#3372)
* Fix exception when contained indexing met hibernate search.
2022-02-09 20:27:40 -05:00
James Agnew 0f2fc7a882
Allow search narrowing and auth interceptor by `token:in` (#3360)
* Optmize valueset expansion

* Working

* Version bump

* Add documentation

* Add test

* Checkstyle message cleanup

* Add reverse rule

* Test ficx

* Test fix

* Test fix

* Test fixes

* Test fixes

* Test fix

* Update hapi-fhir-docs/src/main/resources/ca/uhn/hapi/fhir/docs/security/search_narrowing_interceptor.md

Co-authored-by: Ken Stevens <khstevens@gmail.com>

* Update hapi-fhir-docs/src/main/resources/ca/uhn/hapi/fhir/docs/security/search_narrowing_interceptor.md

Co-authored-by: Ken Stevens <khstevens@gmail.com>

* Test fixes

* Fix conflict

* Add setter

* Test fixes

Co-authored-by: Ken Stevens <khstevens@gmail.com>
2022-02-09 14:27:14 -05:00
Tadgh 0ccf1bfa52 Merge branch 'rel_5_7' 2022-02-07 12:11:35 -08:00
Tadgh a9348b6c51
Bump dependencies for CVES (#3359)
* Bump dependencies for CVES

* Add to cchangesyaml

* Bump java agent
2022-02-07 07:56:25 -05:00
Patrick Werner 2531e6e57d
feat: added support for package.tgz uri in the "file:/" format (#3347)
* feat: added support for package.zgz uri in the "file:/" format

* added changelog entry

* add error code to thrown message

Co-authored-by: Tadgh <garygrantgraham@gmail.com>
2022-02-05 13:25:50 -05:00
James Agnew 1d5714aec2
Fix #3261 - Incorrect revinclude selector (#3358) 2022-02-04 07:50:13 -05:00
michaelabuckley 6b15754b4a
Mb auto complete code (#3330)
New autocomplete extension to ValueSet $expand with contextDirection=existing
2022-02-02 21:03:53 +00:00
Tadgh 6982c4d680
bump version to 6.0.0-PRE1-SNAPSHOT (#3353)
* bump version

* Add new version enum

* Bumped to 6.0.0
2022-02-02 12:11:31 -08:00
Johnson Lu c42ecc5c08
Add error codes to all exceptions (#3278)
* Initial design of adding exception codes to exceptions

* Initial design of adding exception codes to exceptions

* change int module name to string

* add comment

* shorten message

* shorten message

* added checkstyle

* developing checker

* completed checkstyle plugin and unit test for it

* fix NPE

* fix checker so it ignores throws on exceptions that aren't new

* change parameter order in InvalidResponseException

* accept Msg.code() in any parameter since some exceptions like MessageException have the message string as the second parameter

* exclude generated files

* BIG COMMIT added error codes to all exception throws

* example test fix

* Modified tests such that the assert statements would better match the message responses.

* Modified additional tests such that the assert statements would better match the message responses.

* fix test

* merge master

* merge master

* Fourth commit of modified tests such that the assert statements would better match the message response

* Changes made to modify assert statements such that they match the new errors which now use error codes. Also changed ResourceNotFoundException to include error codes in its messages.

* Modified assert messages to better match new error codes

* Time Zone changes DRAFT. Certain tests pass in intellij and fail during mvn install

* Modified assert messages to better match new error codes

* Added comments for time zone fixes. Previous commit comment on time zone fixes was incorrect. By invaliding caches, all tests on both intellij and mvn install passed.

* Reverted changes on azure-pipelines.yml

* updated hapi-fhir version for checkstyle module

* changes to azure-pipelines.yml

* changes to azure-pipelines.yml

* change to pom.xml to include hapi-fhir-checkstyle in ALLMODULES

* changes to azure-piplines (these changes are to be reverted after testing)

* reverted changes to azure-piplines

* reverted change where hapi-fhir-checkstyle was added to pom.xml (hapi-fhir)

* Attempted fix on checkstyle build error

* modified azure-piplines.yml to change maven repository for checkstyle build

* Attempted fix on checkstyle build error

* checkstyle config location change for hapi-depoloyable-pom. (will be reverted if it does not work)

* attempted dependency add for hapi-depoloyable-pom. (will be reverted if it does not work)

* reverted changes for hapi-deployable-pom

* add javadoc

* update last code

* Attempted fix on checkstyle build error

* Finished adding in missing error codes to pass Checkstyle checks

* Test pipelining

* Fixing errors and bumping version (as suggested by Gary)

* Merge

* Fixing Checkstyle error

* Attempted fix for date error

* Add error code onto assert statement

* Add in a couple more error codes

* Fixing assert statements

* Bump to static version for dependency

* Adding error code to message

* Adding error codes to exceptions

* Adding error codes to exceptions

* Change to work with cdr branch

* Update to faulty error message

* Merge changes

* allow checkstyle pom to deploy

Co-authored-by: Ken Stevens <khstevens@gmail.com>
Co-authored-by: Simon Zuccherato <simon.zuccherato@smilecdr.com>
Co-authored-by: Predap <simon.zuccherato@gmail.com>
Co-authored-by: Predap <46201929+Predap@users.noreply.github.com>
Co-authored-by: Tadgh <garygrantgraham@gmail.com>
2022-01-31 13:10:15 -08:00
TipzCM 65398ca14f
3156 multiple tag race condition (#3297)
* 3156 fix race condition that results in multiple tags being created

* 3156 added changelog

* cleanup

* added smile jira ticket

* 3156 review fixes

* review fixes

* 3156 added an additional integratoin test

* cleanup

* review fix and master merge

* threadsafe stuff

* small change

* upping min threads for tests to pass

* changing test

* test check

* fix

* test testing

* one more update

* using threadpoolutil

* temporary measure

* git push

* all builds

Co-authored-by: leif stawnyczy <leifstawnyczy@leifs-MacBook-Pro.local>
2022-01-31 08:49:12 -08:00
Jens Kristian Villadsen fc84fdc33e
Update instance_validator.md (#3328) 2022-01-28 13:16:44 +01:00
TipzCM 41193c60db
3335 allow alternative character encoding length in searchparam (#3336)
* added fixme

* 2714 added support for specifying max code lengths for supported phonetic encoders

* 3335git status

* 3335 updated changelog

* 3335 review fixes

* review fixes

* fixing test

Co-authored-by: Ken Stevens <khstevens@gmail.com>
Co-authored-by: leif stawnyczy <leifstawnyczy@leifs-MacBook-Pro.local>
2022-01-27 17:29:07 +00:00
James Agnew 3f42414287
Validate include statements for JPA (#3331)
* Validate include statements for JPA

* Add changelog

* Optmize test fix
2022-01-26 09:16:28 -05:00
James Agnew 31bb1d9e9a
Bump RestEasy to 5.0.2 (#3329)
* Bump deps

* Test fix

* Add test logging

* Add test logging

* Add logging
2022-01-24 20:15:41 -05:00
katiesmilecdr a11d72ba51
3322 graph ql searches cannot be executed when number of matching results exceeds default page size (#3323)
* fix NPE

* check if size is null
2022-01-24 11:53:21 -05:00
James Agnew 715a4c4602
Fix resource version regression caused by Hibernate 5.6 (#3325)
* failing test

* failing test

* Fixes

* Updated note to self

* Improve pre-caching of resource IDs

* Work on tests

* Test fixes

* Add changelog

Co-authored-by: Ken Stevens <khstevens@gmail.com>
2022-01-23 19:05:02 -05:00
Ken Stevens ed2ea91f56
concurrent validation performance improvement (#3327) 2022-01-23 15:55:31 -05:00
Tadgh 42ff607561
Rel 5 5 5 merge back (#3326)
* Add backport

* Add versions

* remove not real versions
2022-01-22 12:47:34 -05:00
dependabot[bot] 2b4ace3c78
Bump h2 from 2.0.206 to 2.1.210 (#3324)
* Bump h2 from 2.0.206 to 2.1.210

Bumps [h2](https://github.com/h2database/h2database) from 2.0.206 to 2.1.210.
- [Release notes](https://github.com/h2database/h2database/releases)
- [Commits](https://github.com/h2database/h2database/compare/version-2.0.206...version-2.1.210)

---
updated-dependencies:
- dependency-name: com.h2database:h2
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>

* Add chasngelog

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: jamesagnew <jamesagnew@gmail.com>
2022-01-22 11:18:57 -05:00