Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FIX] access restrictions stack for TYPO3 13 #4172

Merged

Conversation

dkd-kaehm
Copy link
Collaborator

@dkd-kaehm dkd-kaehm commented Sep 30, 2024

This change fixes the access restrictions stack within TYPO3 13.
There were multiple troubles in classes and in integration tests.
The page indexer stack on live system runs in multiple isolated processes:

  1. CLI
  2. first FE request to get FE-groups
  3. multiple FE requests to get real content from page for desired FE-groups combination

unlike on integration test running the page indexer steps allways on single process.
This requires to unset the produced state on each step of indexing process.
The runtime cache was interfering between the steps and did things that had nothing to do withhin the own step.


The main problem within access restriction stack on page indexing was the registration of Event-Listeners methods within UserGroupDetector with #[AsEventListener] on EXT:solr.
Due of current troubles with circular dependencies the auto-wiring and auto-configuration was disabled in Servvices.yaml globally.
It requires to enable this features manually for classes, which was done for UserGroupDetector class.

Relates: #3995
Fixes: #4161

This change fixes the access restrictions stack within TYPO3 13.
There were multiple troubles in classes and in integration tests.
The page indexer stack on live system runs in multiple isolated processes:

1. CLI
2. first FE request to get FE-groups
3. multiple FE requests to get real content from page for desired FE-groups combination

unlike on integration test running the page indexer steps allways on single process. 
This requires to unset the produced state on each step of indexing process.
The runtime cache was interfering between the steps 
and did things that had nothing to do withhin the own step.

---

The main problem within access restriction stack on page indexing 
was the registration of Event-Listeners methods within `UserGroupDetector` with `#[AsEventListener]` on EXT:solr. 
Due of current troubles with circular dependencies 
the auto-wiring and auto-configuration was disabled in Servvices.yaml globally. 
It requires to enable this features manually for classes, which was done for `UserGroupDetector` class.

Relates: TYPO3-Solr#3995
Fixes: TYPO3-Solr#4161
@dkd-kaehm dkd-kaehm force-pushed the task/T3_13_Access_Restrictions_4146 branch from 12b7af9 to d6fdfdc Compare September 30, 2024 12:14
…rTest

Removed comment text from `#[Group('frontend')]` attribute in 

Relates: TYPO3-Solr#3995
@dkd-kaehm dkd-kaehm merged commit 0514886 into TYPO3-Solr:main Sep 30, 2024
1 check failed
@dkd-kaehm dkd-kaehm deleted the task/T3_13_Access_Restrictions_4146 branch September 30, 2024 12:54
dkd-friedrich added a commit to dkd-friedrich/ext-solr that referenced this pull request Oct 4, 2024
This is a first alpha release for upcoming TYPO3 13 LTS

Known bugs:

- Mount pages cannot be indexed, see TYPO3-Solr#4160

All changes:

-  [TASK] Use request object to retrieve query params instead of _GET by @sfroemkenjw in TYPO3-Solr#4045
-  [TASK] Use Attributes for PHPUnit tests by @bmack in TYPO3-Solr#4048
-  [TASK] Update PHP-Stan to at least 1.11.* by @sfroemkenjw in TYPO3-Solr#4055
-  [TASK] Apply and repair rector refactorings by @sfroemkenjw in TYPO3-Solr#4049
-  [TASK] Migrate requireJS to ES6. Solr BE Modal JS by @sfroemkenjw in TYPO3-Solr#4057
-  [TASK] Apache Solr 9.6 compatibility by @dkd-friedrich in TYPO3-Solr#4056
-  [TASK] Use new template module API by @sfroemkenjw in TYPO3-Solr#4054
-  [FEATURE] Add contentObjectData to searchController by @spoonerWeb in TYPO3-Solr#4059
-  [BUGFIX] Add empty array as fallback if null by @spoonerWeb in TYPO3-Solr#4061
-  [BUGFIX] Add empty array defaults in SearchFormViewHelper by @hnadler in TYPO3-Solr#4042
-  [TASK] Integrate content of Module layout into WithPageTree by @sfroemkenjw in TYPO3-Solr#4066
-  [TASK] Repair statistics chart because of CSP in Solr Info module by @sfroemkenjw in TYPO3-Solr#4068
-  [FEATURE:BP:12] Be able to disable tracking of last searches by @dkd-kaehm in TYPO3-Solr#4064
-  [TASK] Add access plugin tests by @dkd-friedrich in TYPO3-Solr#4069
-  [TASK] Update authors by @sfroemkenjw in TYPO3-Solr#4071
-  [TASK] Remove content stream usage by @dkd-friedrich in TYPO3-Solr#4073
-  [BUGFIX] Fix synonym and stop word upload by @dkd-friedrich in TYPO3-Solr#4074
-  [TASK] Call getLabelFromItemListMerged with the current row data by @3l73 in TYPO3-Solr#4081
-  [BUGFIX] numeric facet range slider sends lot of requests to server by @hvomlehn-sds in TYPO3-Solr#4084
-  [BUGFIX] Typecast $userGroup to integer by @derhansen in TYPO3-Solr#4079
-  [TASK] Remove getIsSiteManagedSite as all site are managed now by @sfroemkenjw in TYPO3-Solr#4070
-  [BUG] TYPO3-Solr#4026 treat non-overlayed mount points as valid by @derMatze82 in TYPO3-Solr#4029
-  [TASK] New Crowdin updates by @dkd-kaehm in TYPO3-Solr#4094
-  [BUGFIX] Fix range string calculation in DateRange facet by @derhansen in TYPO3-Solr#4090
-  [FIX:12] scheduler task "Optimize index of a site" is not functional by @dkd-kaehm in TYPO3-Solr#4104
-  [TASK] Apache Solr 9.6.1 compatibility by @dkd-kaehm in TYPO3-Solr#4106
-  [FIX] tests for TYPO3 13 @ 2024.07.02 by @dkd-kaehm in TYPO3-Solr#4098
-  [FIX] deprecations for Fluid viewHelpers and stack by @dkd-kaehm in TYPO3-Solr#4140
-  [FIX] Integration\Extbase\PersistenceEventListenerTest errors by @dkd-kaehm in TYPO3-Solr#4142
-  [TASK] TYPO3 13 dev-main 2024.09.13 compatibility:: Tests by @dkd-kaehm in TYPO3-Solr#4153
-  [TASK] TYPO3 13 compatibility 2024.09.19 by @dkd-kaehm in TYPO3-Solr#4159
-  [FIX] Tests for TYPO3 dev-main @2024.09.23 by @dkd-kaehm in TYPO3-Solr#4163
-  [BUGFIX] Failed to resolve module specifier '@apache-solr-for-typo3/solr//FormModal.js' by @dkd-kaehm in TYPO3-Solr#4166
-  [BUGFIX] @typo3/backend/tree/page-tree-element does not work in BE-Modules by @dkd-kaehm in TYPO3-Solr#4167
-  [FIX] access restrictions stack for TYPO3 13 by @dkd-kaehm in TYPO3-Solr#4172
-  [TASK] Adapt simulated environment for TYPO3 13 by @dkd-friedrich in TYPO3-Solr#4164

Please read the release notes:
https://github.com/TYPO3-Solr/ext-solr/releases/tag/13.0.0-alpha-1

---

How to Get Involved

There are many ways to get involved with Apache Solr for TYPO3:

* Submit bug reports and feature requests on GitHub
* Ask or help or answer questions in our Slack channel
* Provide patches through pull requests or review and comment on
existing pull requests
* Go to www.typo3-solr.com or call dkd to sponsor the ongoing
development of Apache Solr for TYPO3

Support us by becoming an EB partner:
https://shop.dkd.de/Produkte/Apache-Solr-fuer-TYPO3/

or call:
+49 (0)69 - 2475218 0
dkd-kaehm pushed a commit to dkd-friedrich/ext-solr that referenced this pull request Oct 7, 2024
This is a first alpha release for upcoming TYPO3 13 LTS

Known bugs:

- Mount pages cannot be indexed, see TYPO3-Solr#4160

All changes:

-  [TASK] Use request object to retrieve query params instead of _GET by @sfroemkenjw in TYPO3-Solr#4045
-  [TASK] Use Attributes for PHPUnit tests by @bmack in TYPO3-Solr#4048
-  [TASK] Update PHP-Stan to at least 1.11.* by @sfroemkenjw in TYPO3-Solr#4055
-  [TASK] Apply and repair rector refactorings by @sfroemkenjw in TYPO3-Solr#4049
-  [TASK] Migrate requireJS to ES6. Solr BE Modal JS by @sfroemkenjw in TYPO3-Solr#4057
-  [TASK] Apache Solr 9.6 compatibility by @dkd-friedrich in TYPO3-Solr#4056
-  [TASK] Use new template module API by @sfroemkenjw in TYPO3-Solr#4054
-  [FEATURE] Add contentObjectData to searchController by @spoonerWeb in TYPO3-Solr#4059
-  [BUGFIX] Add empty array as fallback if null by @spoonerWeb in TYPO3-Solr#4061
-  [BUGFIX] Add empty array defaults in SearchFormViewHelper by @hnadler in TYPO3-Solr#4042
-  [TASK] Integrate content of Module layout into WithPageTree by @sfroemkenjw in TYPO3-Solr#4066
-  [TASK] Repair statistics chart because of CSP in Solr Info module by @sfroemkenjw in TYPO3-Solr#4068
-  [FEATURE:BP:12] Be able to disable tracking of last searches by @dkd-kaehm in TYPO3-Solr#4064
-  [TASK] Add access plugin tests by @dkd-friedrich in TYPO3-Solr#4069
-  [TASK] Update authors by @sfroemkenjw in TYPO3-Solr#4071
-  [TASK] Remove content stream usage by @dkd-friedrich in TYPO3-Solr#4073
-  [BUGFIX] Fix synonym and stop word upload by @dkd-friedrich in TYPO3-Solr#4074
-  [TASK] Call getLabelFromItemListMerged with the current row data by @3l73 in TYPO3-Solr#4081
-  [BUGFIX] numeric facet range slider sends lot of requests to server by @hvomlehn-sds in TYPO3-Solr#4084
-  [BUGFIX] Typecast $userGroup to integer by @derhansen in TYPO3-Solr#4079
-  [TASK] Remove getIsSiteManagedSite as all site are managed now by @sfroemkenjw in TYPO3-Solr#4070
-  [BUG] TYPO3-Solr#4026 treat non-overlayed mount points as valid by @derMatze82 in TYPO3-Solr#4029
-  [TASK] New Crowdin updates by @dkd-kaehm in TYPO3-Solr#4094
-  [BUGFIX] Fix range string calculation in DateRange facet by @derhansen in TYPO3-Solr#4090
-  [FIX:12] scheduler task "Optimize index of a site" is not functional by @dkd-kaehm in TYPO3-Solr#4104
-  [TASK] Apache Solr 9.6.1 compatibility by @dkd-kaehm in TYPO3-Solr#4106
-  [FIX] tests for TYPO3 13 @ 2024.07.02 by @dkd-kaehm in TYPO3-Solr#4098
-  [FIX] deprecations for Fluid viewHelpers and stack by @dkd-kaehm in TYPO3-Solr#4140
-  [FIX] Integration\Extbase\PersistenceEventListenerTest errors by @dkd-kaehm in TYPO3-Solr#4142
-  [TASK] TYPO3 13 dev-main 2024.09.13 compatibility:: Tests by @dkd-kaehm in TYPO3-Solr#4153
-  [TASK] TYPO3 13 compatibility 2024.09.19 by @dkd-kaehm in TYPO3-Solr#4159
-  [FIX] Tests for TYPO3 dev-main @2024.09.23 by @dkd-kaehm in TYPO3-Solr#4163
-  [BUGFIX] Failed to resolve module specifier '@apache-solr-for-typo3/solr//FormModal.js' by @dkd-kaehm in TYPO3-Solr#4166
-  [BUGFIX] @typo3/backend/tree/page-tree-element does not work in BE-Modules by @dkd-kaehm in TYPO3-Solr#4167
-  [FIX] access restrictions stack for TYPO3 13 by @dkd-kaehm in TYPO3-Solr#4172
-  [TASK] Adapt simulated environment for TYPO3 13 by @dkd-friedrich in TYPO3-Solr#4164

Please read the release notes:
https://github.com/TYPO3-Solr/ext-solr/releases/tag/13.0.0-alpha-1

---

How to Get Involved

There are many ways to get involved with Apache Solr for TYPO3:

* Submit bug reports and feature requests on GitHub
* Ask or help or answer questions in our Slack channel
* Provide patches through pull requests or review and comment on
existing pull requests
* Go to www.typo3-solr.com or call dkd to sponsor the ongoing
development of Apache Solr for TYPO3

Support us by becoming an EB partner:
https://shop.dkd.de/Produkte/Apache-Solr-fuer-TYPO3/

or call:
+49 (0)69 - 2475218 0
dkd-kaehm pushed a commit to dkd-friedrich/ext-solr that referenced this pull request Oct 7, 2024
This is a first alpha release for upcoming TYPO3 13 LTS

Known bugs:

- Mount pages cannot be indexed, see TYPO3-Solr#4160

All changes:

-  [TASK] Use request object to retrieve query params instead of _GET by @sfroemkenjw in TYPO3-Solr#4045
-  [TASK] Use Attributes for PHPUnit tests by @bmack in TYPO3-Solr#4048
-  [TASK] Update PHP-Stan to at least 1.11.* by @sfroemkenjw in TYPO3-Solr#4055
-  [TASK] Apply and repair rector refactorings by @sfroemkenjw in TYPO3-Solr#4049
-  [TASK] Migrate requireJS to ES6. Solr BE Modal JS by @sfroemkenjw in TYPO3-Solr#4057
-  [TASK] Apache Solr 9.6 compatibility by @dkd-friedrich in TYPO3-Solr#4056
-  [TASK] Use new template module API by @sfroemkenjw in TYPO3-Solr#4054
-  [FEATURE] Add contentObjectData to searchController by @spoonerWeb in TYPO3-Solr#4059
-  [BUGFIX] Add empty array as fallback if null by @spoonerWeb in TYPO3-Solr#4061
-  [BUGFIX] Add empty array defaults in SearchFormViewHelper by @hnadler in TYPO3-Solr#4042
-  [TASK] Integrate content of Module layout into WithPageTree by @sfroemkenjw in TYPO3-Solr#4066
-  [TASK] Repair statistics chart because of CSP in Solr Info module by @sfroemkenjw in TYPO3-Solr#4068
-  [FEATURE:BP:12] Be able to disable tracking of last searches by @dkd-kaehm in TYPO3-Solr#4064
-  [TASK] Add access plugin tests by @dkd-friedrich in TYPO3-Solr#4069
-  [TASK] Update authors by @sfroemkenjw in TYPO3-Solr#4071
-  [TASK] Remove content stream usage by @dkd-friedrich in TYPO3-Solr#4073
-  [BUGFIX] Fix synonym and stop word upload by @dkd-friedrich in TYPO3-Solr#4074
-  [TASK] Call getLabelFromItemListMerged with the current row data by @3l73 in TYPO3-Solr#4081
-  [BUGFIX] numeric facet range slider sends lot of requests to server by @hvomlehn-sds in TYPO3-Solr#4084
-  [BUGFIX] Typecast $userGroup to integer by @derhansen in TYPO3-Solr#4079
-  [TASK] Remove getIsSiteManagedSite as all site are managed now by @sfroemkenjw in TYPO3-Solr#4070
-  [BUG] TYPO3-Solr#4026 treat non-overlayed mount points as valid by @derMatze82 in TYPO3-Solr#4029
-  [TASK] New Crowdin updates by @dkd-kaehm in TYPO3-Solr#4094
-  [BUGFIX] Fix range string calculation in DateRange facet by @derhansen in TYPO3-Solr#4090
-  [FIX:12] scheduler task "Optimize index of a site" is not functional by @dkd-kaehm in TYPO3-Solr#4104
-  [TASK] Apache Solr 9.6.1 compatibility by @dkd-kaehm in TYPO3-Solr#4106
-  [FIX] tests for TYPO3 13 @ 2024.07.02 by @dkd-kaehm in TYPO3-Solr#4098
-  [FIX] deprecations for Fluid viewHelpers and stack by @dkd-kaehm in TYPO3-Solr#4140
-  [FIX] Integration\Extbase\PersistenceEventListenerTest errors by @dkd-kaehm in TYPO3-Solr#4142
-  [TASK] TYPO3 13 dev-main 2024.09.13 compatibility:: Tests by @dkd-kaehm in TYPO3-Solr#4153
-  [TASK] TYPO3 13 compatibility 2024.09.19 by @dkd-kaehm in TYPO3-Solr#4159
-  [FIX] Tests for TYPO3 dev-main @2024.09.23 by @dkd-kaehm in TYPO3-Solr#4163
-  [BUGFIX] Failed to resolve module specifier '@apache-solr-for-typo3/solr//FormModal.js' by @dkd-kaehm in TYPO3-Solr#4166
-  [BUGFIX] @typo3/backend/tree/page-tree-element does not work in BE-Modules by @dkd-kaehm in TYPO3-Solr#4167
-  [FIX] access restrictions stack for TYPO3 13 by @dkd-kaehm in TYPO3-Solr#4172
-  [TASK] Adapt simulated environment for TYPO3 13 by @dkd-friedrich in TYPO3-Solr#4164

Please read the release notes:
https://github.com/TYPO3-Solr/ext-solr/releases/tag/13.0.0-alpha-1

---

How to Get Involved

There are many ways to get involved with Apache Solr for TYPO3:

* Submit bug reports and feature requests on GitHub
* Ask or help or answer questions in our Slack channel
* Provide patches through pull requests or review and comment on
existing pull requests
* Go to www.typo3-solr.com or call dkd to sponsor the ongoing
development of Apache Solr for TYPO3

Support us by becoming an EB partner:
https://shop.dkd.de/Produkte/Apache-Solr-fuer-TYPO3/

or call:
+49 (0)69 - 2475218 0
dkd-kaehm pushed a commit that referenced this pull request Oct 7, 2024
This is a first alpha release for upcoming TYPO3 13 LTS

Known bugs:

- Mount pages cannot be indexed, see #4160

All changes:

-  [TASK] Use request object to retrieve query params instead of _GET by @sfroemkenjw in #4045
-  [TASK] Use Attributes for PHPUnit tests by @bmack in #4048
-  [TASK] Update PHP-Stan to at least 1.11.* by @sfroemkenjw in #4055
-  [TASK] Apply and repair rector refactorings by @sfroemkenjw in #4049
-  [TASK] Migrate requireJS to ES6. Solr BE Modal JS by @sfroemkenjw in #4057
-  [TASK] Apache Solr 9.6 compatibility by @dkd-friedrich in #4056
-  [TASK] Use new template module API by @sfroemkenjw in #4054
-  [FEATURE] Add contentObjectData to searchController by @spoonerWeb in #4059
-  [BUGFIX] Add empty array as fallback if null by @spoonerWeb in #4061
-  [BUGFIX] Add empty array defaults in SearchFormViewHelper by @hnadler in #4042
-  [TASK] Integrate content of Module layout into WithPageTree by @sfroemkenjw in #4066
-  [TASK] Repair statistics chart because of CSP in Solr Info module by @sfroemkenjw in #4068
-  [FEATURE:BP:12] Be able to disable tracking of last searches by @dkd-kaehm in #4064
-  [TASK] Add access plugin tests by @dkd-friedrich in #4069
-  [TASK] Update authors by @sfroemkenjw in #4071
-  [TASK] Remove content stream usage by @dkd-friedrich in #4073
-  [BUGFIX] Fix synonym and stop word upload by @dkd-friedrich in #4074
-  [TASK] Call getLabelFromItemListMerged with the current row data by @3l73 in #4081
-  [BUGFIX] numeric facet range slider sends lot of requests to server by @hvomlehn-sds in #4084
-  [BUGFIX] Typecast $userGroup to integer by @derhansen in #4079
-  [TASK] Remove getIsSiteManagedSite as all site are managed now by @sfroemkenjw in #4070
-  [BUG] #4026 treat non-overlayed mount points as valid by @derMatze82 in #4029
-  [TASK] New Crowdin updates by @dkd-kaehm in #4094
-  [BUGFIX] Fix range string calculation in DateRange facet by @derhansen in #4090
-  [FIX:12] scheduler task "Optimize index of a site" is not functional by @dkd-kaehm in #4104
-  [TASK] Apache Solr 9.6.1 compatibility by @dkd-kaehm in #4106
-  [FIX] tests for TYPO3 13 @ 2024.07.02 by @dkd-kaehm in #4098
-  [FIX] deprecations for Fluid viewHelpers and stack by @dkd-kaehm in #4140
-  [FIX] Integration\Extbase\PersistenceEventListenerTest errors by @dkd-kaehm in #4142
-  [TASK] TYPO3 13 dev-main 2024.09.13 compatibility:: Tests by @dkd-kaehm in #4153
-  [TASK] TYPO3 13 compatibility 2024.09.19 by @dkd-kaehm in #4159
-  [FIX] Tests for TYPO3 dev-main @2024.09.23 by @dkd-kaehm in #4163
-  [BUGFIX] Failed to resolve module specifier '@apache-solr-for-typo3/solr//FormModal.js' by @dkd-kaehm in #4166
-  [BUGFIX] @typo3/backend/tree/page-tree-element does not work in BE-Modules by @dkd-kaehm in #4167
-  [FIX] access restrictions stack for TYPO3 13 by @dkd-kaehm in #4172
-  [TASK] Adapt simulated environment for TYPO3 13 by @dkd-friedrich in #4164

Please read the release notes:
https://github.com/TYPO3-Solr/ext-solr/releases/tag/13.0.0-alpha-1

---

How to Get Involved

There are many ways to get involved with Apache Solr for TYPO3:

* Submit bug reports and feature requests on GitHub
* Ask or help or answer questions in our Slack channel
* Provide patches through pull requests or review and comment on
existing pull requests
* Go to www.typo3-solr.com or call dkd to sponsor the ongoing
development of Apache Solr for TYPO3

Support us by becoming an EB partner:
https://shop.dkd.de/Produkte/Apache-Solr-fuer-TYPO3/

or call:
+49 (0)69 - 2475218 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[TASK:T13] fix access restrictions stack
1 participant