Krzysztof Gołębiowski 1 Year Ago - Edited Great article Vitaliy, I learned some new tricks that I'm going to use soon! We also use all the new search features a lot, and the entire mechanism is much better than it used to be in the past. Especially configuring the search with different "filtering" widgets. The only trick I'd add to your list is that instead of adding the new “Custom Filter” widget for each child site, I usually add a single "Regexp" filter with all groupIds listed in a single field with the following pattern: "(groupid_1)|(groupid_2)|(groupid_3)|..." Please sign in to reply. Reply as... Cancel
Christian Hofstätter 1 Year Ago - Edited Thanks for the info and the module! We were also wondering what the hell happened after the FP2 update... Please sign in to reply. Reply as... Cancel Christian Hofstätter Christian Hofstätter 1 Year Ago - Edited We had to change the following line in LayoutCrawler.java to get it to work on our PROD servers: themeDisplay.setServerName(company.getVirtualHostname()); Since we have web.server.protocol=https set in portal-ext.properties the URLs to crawl were being generated as https://localhost/..., which was of course throwing SSL errors. We then had to add the SSL cert to the Java keystore. Don't know if there's a way to force https URLs and get this to work otherwise? Please sign in to reply. Reply as... Cancel Vitaliy Koshelenko Christian Hofstätter 1 Year Ago - Edited Hi Christian! For local development you can either setup HTTPs: https://lifedev-solutions.blogspot.com/2021/03/liferay-tomcat-ssl-configuration.html or just disable it (set web.server.protocol=http, or remove this property). You can also set the web.server.host propery to specify the host, if needed. But the main issue with layouts search is missing authorization, you can add it customized version of LayoutCrawler, see: https://github.com/liferay-apps/liferay-search-override/blob/master/src/main/java/com/liferay/apps/search/override/crawler/LayoutCrawler.java#L66 Vitaliy Please sign in to reply. Reply as... Cancel
Christian Hofstätter Christian Hofstätter 1 Year Ago - Edited We had to change the following line in LayoutCrawler.java to get it to work on our PROD servers: themeDisplay.setServerName(company.getVirtualHostname()); Since we have web.server.protocol=https set in portal-ext.properties the URLs to crawl were being generated as https://localhost/..., which was of course throwing SSL errors. We then had to add the SSL cert to the Java keystore. Don't know if there's a way to force https URLs and get this to work otherwise? Please sign in to reply. Reply as... Cancel Vitaliy Koshelenko Christian Hofstätter 1 Year Ago - Edited Hi Christian! For local development you can either setup HTTPs: https://lifedev-solutions.blogspot.com/2021/03/liferay-tomcat-ssl-configuration.html or just disable it (set web.server.protocol=http, or remove this property). You can also set the web.server.host propery to specify the host, if needed. But the main issue with layouts search is missing authorization, you can add it customized version of LayoutCrawler, see: https://github.com/liferay-apps/liferay-search-override/blob/master/src/main/java/com/liferay/apps/search/override/crawler/LayoutCrawler.java#L66 Vitaliy Please sign in to reply. Reply as... Cancel
Vitaliy Koshelenko Christian Hofstätter 1 Year Ago - Edited Hi Christian! For local development you can either setup HTTPs: https://lifedev-solutions.blogspot.com/2021/03/liferay-tomcat-ssl-configuration.html or just disable it (set web.server.protocol=http, or remove this property). You can also set the web.server.host propery to specify the host, if needed. But the main issue with layouts search is missing authorization, you can add it customized version of LayoutCrawler, see: https://github.com/liferay-apps/liferay-search-override/blob/master/src/main/java/com/liferay/apps/search/override/crawler/LayoutCrawler.java#L66 Vitaliy Please sign in to reply. Reply as... Cancel
Daniel Yee 1 Year Ago - Edited Wonderful article, Vitaliy! I was looking into how to do this for an external SSO implementation. If I understand the process correctly, I think all I need to do is replace your doLogin logic with the logic from the relevant AutoLogin implementation. For example, if SAML SSO, then modules/dxp/apps/saml/saml-impl/src/main/java/com/liferay/saml/runtime/internal/auto/login/SamlSpAutoLogin.java. Please sign in to reply. Reply as... Cancel