[MGNLCT-358] Root node is not created for content types defined on classpath Created: 18/Jan/23 Updated: 10/Feb/23 Resolved: 09/Feb/23 |
|
| Status: | Closed |
| Project: | Content Types |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.0.0 |
| Type: | Bug | Priority: | Neutral |
| Reporter: | Jaroslav Simak | Assignee: | Oanh Thai Hoang |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Σ Remaining Estimate: | Not Specified | Remaining Estimate: | Not Specified |
| Σ Time Spent: | 3h | Time Spent: | 3h |
| Σ Original Estimate: | Not Specified | Original Estimate: | Not Specified |
| Attachments: |
|
|||||||||||||||||||||||||
| Issue Links: |
|
|||||||||||||||||||||||||
| Sub-Tasks: |
|
|||||||||||||||||||||||||
| Template: | ||||||||||||||||||||||||||
| Acceptance criteria: |
Empty
|
|||||||||||||||||||||||||
| Task DoD: |
[X]*
Doc/release notes changes? Comment present?
[X]*
Downstream builds green?
[X]*
Solution information and context easily available?
[X]*
Tests
[X]*
FixVersion filled and not yet released
[ ] 
Architecture Decision Record (ADR)
|
|||||||||||||||||||||||||
| Bug DoR: |
[ ]*
Steps to reproduce, expected, and actual results filled
[ ]*
Affected version filled
|
|||||||||||||||||||||||||
| Date of First Response: | ||||||||||||||||||||||||||
| Epic Link: | SaaS TPR - DevX Bugs | |||||||||||||||||||||||||
| Sprint: | DevX 29, DevX 30 | |||||||||||||||||||||||||
| Story Points: | 1 | |||||||||||||||||||||||||
| Team: | ||||||||||||||||||||||||||
| Work Started: | ||||||||||||||||||||||||||
| Description |
Steps to reproduce
Expected resultsThe website node is created. Actual resultsThe website not is not created. WorkaroundPush content type definition to git. Development notes |
| Comments |
| Comment by Jaroslav Simak [ 18/Jan/23 ] |
DiscoveryNorsuContentTypeInitializer is not run unless a content type definition is registered via git push. Because intializer does not run on module startup, the already existing definitions coming from classpath are not processed. Proposed solutionRun NorsuContentTypeInitializer on module startup, after registry is bound to configuration source. |
| Comment by Jaroslav Simak [ 20/Jan/23 ] |
|
The proposed solution in the discovery does not work due to the fact that no environment is configured.
|
| Comment by Oanh Thai Hoang [ 01/Feb/23 ] |
|
No config any git env will cause trouble for norsu-asset as well. Event norsu asset won't use content type for provisioning root path.
Step to reproduce:
Here is log: t5snmsdmturgjmfh.log
Caused by: java.lang.RuntimeException: No default environment found for subscription at info.magnolia.norsu.environment.CurrentEnvironmentContextProvider.lambda$getDefaultConfigurationEnvironment$0(CurrentEnvironmentContextProvider.java:116) ~[magnolia-norsu-1.0.0-SNAPSHOT.jar:?] at java.util.Optional.orElseThrow(Optional.java:408) ~[?:?] at info.magnolia.norsu.environment.CurrentEnvironmentContextProvider.getDefaultConfigurationEnvironment(CurrentEnvironmentContextProvider.java:116) ~[magnolia-norsu-1.0.0-SNAPSHOT.jar:?] at info.magnolia.norsu.environment.CurrentEnvironmentContextProvider.isDefaultConfigurationEnvironment(CurrentEnvironmentContextProvider.java:109) ~[magnolia-norsu-1.0.0-SNAPSHOT.jar:?] at info.magnolia.norsu.environment.CurrentEnvironmentContextProvider.inferContentEnvironmentFromConfigurationEnvironment(CurrentEnvironmentContextProvider.java:102) ~[magnolia-norsu-1.0.0-SNAPSHOT.jar:?] at info.magnolia.norsu.environment.CurrentEnvironmentContextProvider.get(CurrentEnvironmentContextProvider.java:89) ~[magnolia-norsu-1.0.0-SNAPSHOT.jar:?] at info.magnolia.norsu.NodeApiProvider.get(NodeApiProvider.java:59) ~[magnolia-norsu-1.0.0-SNAPSHOT.jar:?] at info.magnolia.norsu.NodeApiProvider.get(NodeApiProvider.java:46) ~[magnolia-norsu-1.0.0-SNAPSHOT.jar:?] at com.google.inject.internal.ProviderInternalFactory.provision(ProviderInternalFactory.java:86) ~[guice-5.1.0.jar:?] at com.google.inject.internal.BoundProviderFactory.provision(BoundProviderFactory.java:72) ~[guice-5.1.0.jar:?] at com.google.inject.internal.ProviderInternalFactory.circularGet(ProviderInternalFactory.java:60) ~[guice-5.1.0.jar:?] at com.google.inject.internal.BoundProviderFactory.get(BoundProviderFactory.java:59) ~[guice-5.1.0.jar:?] at com.google.inject.internal.InjectorImpl$1.get(InjectorImpl.java:1101) ~[guice-5.1.0.jar:?] ... 121 more |
| Comment by Oanh Thai Hoang [ 09/Feb/23 ] |
|
QA has been done. |