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

[TASK:T13] fix access restrictions stack #4161

Closed
1 task
Tracked by #3995
dkd-kaehm opened this issue Sep 19, 2024 · 0 comments · Fixed by #4172
Closed
1 task
Tracked by #3995

[TASK:T13] fix access restrictions stack #4161

dkd-kaehm opened this issue Sep 19, 2024 · 0 comments · Fixed by #4172

Comments

@dkd-kaehm
Copy link
Collaborator

dkd-kaehm commented Sep 19, 2024

  • PageIndexerTest::canIndexPageWithAccessProtectedContentIntoSolr
3) ApacheSolrForTypo3\Solr\Tests\Integration\IndexQueue\PageIndexerTest::canIndexPageWithAccessProtectedContentIntoSolr with data set "protected page with protected content" ('can_index_access_protected_pa...ntents', 2, ['2:1/c:0', '2:1/c:2'], ['public content of protected page', 'public content of protected p...d page'], 0, '0,1,2', 2)
Could not index documents into Solr
Failed asserting that 1 matches expected 2.

/home/runner/work/ext-solr/ext-solr/Tests/Integration/IndexQueue/PageIndexerTest.php:107

4) ApacheSolrForTypo3\Solr\Tests\Integration\IndexQueue\PageIndexerTest::canIndexPageWithAccessProtectedContentIntoSolr with data set "translation of protected page with protected content" ('can_index_access_protected_pa...ntents', 2, ['2:1/c:0', '2:1/c:2'], ['public content of protected page de', 'public content of protected p...age de'], 0, '0,1,2', 2, 'core_de')
Could not index documents into Solr
Failed asserting that 1 matches expected 2.

/home/runner/work/ext-solr/ext-solr/Tests/Integration/IndexQueue/PageIndexerTest.php:107

5) ApacheSolrForTypo3\Solr\Tests\Integration\IndexQueue\PageIndexerTest::canIndexPageWithAccessProtectedContentIntoSolr with data set "public page with protected content and global content" ('can_index_page_with_protected_content', 2, ['c:0', 'c:1'], ['public ce', 'protected cepublic ce'], 1, '0,1', 2)
Could not index documents into Solr
Failed asserting that 1 matches expected 2.

/home/runner/work/ext-solr/ext-solr/Tests/Integration/IndexQueue/PageIndexerTest.php:107

6) ApacheSolrForTypo3\Solr\Tests\Integration\IndexQueue\PageIndexerTest::canIndexPageWithAccessProtectedContentIntoSolr with data set "public page with protected and hide at login content" ('can_index_page_with_protected...ontent', 2, ['c:0', 'c:1'], ['hide at login content', 'protected ce'], 1, '0,1', 2)
Could not index documents into Solr
Failed asserting that 1 matches expected 2.

Current state:

  • The event-listeners methods registered via #[AsEventListener] are not called not only within integration tests.
    If it will not work like defined in Services.yaml within our tests, also without registering them by ListenerProvider in each test, all the #[AsEventListener] things must be duplicated in Services.yaml
    The Autowire is disabled for classes using #[AsEventListener].
dkd-kaehm added a commit to dkd-kaehm/ext-solr that referenced this issue Sep 19, 2024


The tests are skipped temporary, to be able to recognize troubles due daily builds.

The skipped tests within this commit must be fixed by issue: TYPO3-Solr#4160

Relates: TYPO3-Solr#4161, TYPO3-Solr#3995
dkd-kaehm added a commit to dkd-kaehm/ext-solr that referenced this issue Sep 19, 2024


The tests are skipped temporary, to be able to recognize troubles due daily builds.

The skipped tests within this commit must be fixed by issue: TYPO3-Solr#4160

Relates: TYPO3-Solr#4161, TYPO3-Solr#3995
dkd-kaehm added a commit that referenced this issue Sep 20, 2024
The tests are skipped temporary, to be able to recognize troubles due daily builds.

The skipped tests within this commit must be fixed by issue: #4160

Relates: #4161, #3995
dkd-kaehm added a commit to dkd-kaehm/ext-solr that referenced this issue 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: TYPO3-Solr#3995
Fixes: TYPO3-Solr#4161
dkd-kaehm added a commit that referenced this issue 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
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 a pull request may close this issue.

1 participant