Skip to content

Commit

Permalink
Refactor implementation for loading data on repositories to improve p…
Browse files Browse the repository at this point in the history
…erformance (#3634)

* Start register data refactor

Signed-off-by: Elly Kitoto <[email protected]>

* Fix loading related resources data

Signed-off-by: Elly Kitoto <[email protected]>

* Optimize import

Signed-off-by: Elly Kitoto <[email protected]>

* Refactor implementation for counting related resources

Signed-off-by: Elly Kitoto <[email protected]>

* Refactor implementation for loading profile data

Signed-off-by: Elly Kitoto <[email protected]>

* Refactor the rest of implementation using DefaultRepository

Signed-off-by: Elly Kitoto <[email protected]>

* Use coding system on REL filter query

Signed-off-by: Elly Kitoto <[email protected]>

* Fix count with REL filter applied

Signed-off-by: Elly Kitoto <[email protected]>

* Refactor retrieval of REL tag locationIds

Signed-off-by: Elly Kitoto <[email protected]>

* Revert paging3 implementation

Signed-off-by: Elly Kitoto <[email protected]>

* Set pager prefetch size to half of page size

Signed-off-by: Elly Kitoto <[email protected]>

* Run spotless

Signed-off-by: Elly Kitoto <[email protected]>

* Refactor code

Signed-off-by: Elly Kitoto <[email protected]>

* Fix redundant count of related resources

Signed-off-by: Elly Kitoto <[email protected]>

* Refactor implementation

Signed-off-by: Elly Kitoto <[email protected]>

* Remove unnecessary coroutine context switching

Signed-off-by: Elly Kitoto <[email protected]>

* Fix failing engine tests

Signed-off-by: Elly Kitoto <[email protected]>

* Fix failing tests

Signed-off-by: Elly Kitoto <[email protected]>

* Run spotlessApply

Signed-off-by: Elly Kitoto <[email protected]>

* Run spotless

Signed-off-by: Elly Kitoto <[email protected]>

* Fix failing lint check

Signed-off-by: Elly Kitoto <[email protected]>

* Run spotlessApply

Signed-off-by: Elly Kitoto <[email protected]>

* Fix failing lint check

Signed-off-by: Elly Kitoto <[email protected]>

* Run spotlessApply

Signed-off-by: Elly Kitoto <[email protected]>

* Fix failing tests

Signed-off-by: Elly Kitoto <[email protected]>

* Run spotlessApply

Signed-off-by: Elly Kitoto <[email protected]>

* Format code

Signed-off-by: Elly Kitoto <[email protected]>

---------

Signed-off-by: Elly Kitoto <[email protected]>
  • Loading branch information
Lentumunai-Mark committed Dec 5, 2024
1 parent 2a082e2 commit bb955f2
Show file tree
Hide file tree
Showing 58 changed files with 1,446 additions and 1,296 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import org.smartregister.fhircore.engine.domain.model.RuleConfig
data class MigrationConfig(
val updateValues: List<UpdateValueConfig>,
val resourceConfig: FhirResourceConfig,
val rules: List<RuleConfig>,
val rules: List<RuleConfig> = emptyList(),
val version: Int,
val purgeAffectedResources: Boolean = false,
val createLocalChangeEntitiesAfterPurge: Boolean = true,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ data class RegisterConfiguration(
val registerCard: RegisterCardConfig = RegisterCardConfig(),
val fabActions: List<NavigationMenuConfig> = emptyList(),
val noResults: NoResultsConfig? = null,
val pageSize: Int = 10,
val pageSize: Int = 20,
val activeResourceFilters: List<ActiveResourceFilterConfig> =
listOf(
ActiveResourceFilterConfig(resourceType = ResourceType.Patient, active = true),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ data class RegisterContentConfig(
val separator: String? = null,
val display: String? = null,
val placeholderColor: String? = null,
val rules: List<RuleConfig>? = null,
val rules: List<RuleConfig> = emptyList(),
val visible: Boolean? = null,
val computedRules: List<String>? = null,
val searchByQrCode: Boolean? = null,
Expand Down
Loading

0 comments on commit bb955f2

Please sign in to comment.