An error occurred while processing the template.
Java method "com.liferay.osb.www.journal.cache.util.impl.OSBJournalContentImpl.getContent(long, String, String, String)" threw an exception when invoked on com.liferay.osb.www.journal.cache.util.impl.OSBJournalContentImpl object "co[email protected]46560e21"; see cause exception in the Java stack trace.

----
FTL stack trace ("~" means nesting-related):
	- Failed at: ${journalContent.getContent(groupId?l...  [in template "ARTICLE_UTILITIES" in macro "get_journal_article_content" at line 70, column 17]
	- Reached through: @get_journal_article_content article  [in template "ARTICLE_UTILITIES" in macro "embed_journal_article" at line 61, column 17]
	- Reached through: @article_utilities.embed_journal_arti...  [in template "10155#10195#RESOURCE_RENDERER" at line 135, column 25]
----
1<#include "${templatesPath}/components"> 
2 
3<#assign asset_category_local_service = serviceLocator.findService("com.liferay.asset.kernel.service.AssetCategoryLocalService") /> 
4<#assign asset_entry_local_service = serviceLocator.findService("com.liferay.asset.kernel.service.AssetEntryLocalService") /> 
5<#assign asset_link_local_service = serviceLocator.findService("com.liferay.asset.kernel.service.AssetLinkLocalService") /> 
6<#assign asset_vocabulary_local_service = serviceLocator.findService("com.liferay.asset.kernel.service.AssetVocabularyLocalService") /> 
7<#assign dl_file_entry_local_service = serviceLocator.findService("com.liferay.document.library.kernel.service.DLFileEntryLocalService") /> 
8<#assign journal_article_local_service = serviceLocator.findService("com.liferay.journal.service.JournalArticleLocalService") /> 
9<#assign portlet_file_repository_util = objectUtil("com.liferay.portal.kernel.portletfilerepository.PortletFileRepositoryUtil") /> 
10 
11<#assign service_context = objectUtil("com.liferay.portal.kernel.service.ServiceContextThreadLocal").getServiceContext() /> 
12 
13<#assign http_servlet_request = service_context.getRequest() /> 
14 
15<#assign theme_display = service_context.getThemeDisplay() /> 
16 
17<#assign plid = theme_display["plid"]?number /> 
18 
19<#assign folder_id = paramUtil.getLong(http_servlet_request, "folderId") /> 
20<#assign resource_id = paramUtil.getLong(http_servlet_request, "resourceId") /> 
21<#assign title = paramUtil.getString(http_servlet_request, "title") /> 
22<#assign passed_gated = paramUtil.getString(http_servlet_request, "gt") /> 
23 
24<#import "${templatesPath}/article_utilities" as article_utilities> 
25<#import "${templatesPath}/language_keys" as lang> 
26 
27<#assign has_update_permissions = article_utilities.has_update_permissions() /> 
28 
29<#function get_related_links class_name class_pk> 
30	<#assign asset_entry = asset_entry_local_service.getEntry(class_name, class_pk) /> 
31 
32	<#assign asset_entry_id = asset_entry.getEntryId() /> 
33 
34	<#assign related_links = asset_link_local_service.getDirectLinks(asset_entry_id) /> 
35 
36	<#return related_links> 
37</#function> 
38 
39<#assign vocabularies = ["Industry","Resource Type","Solution","Topic"] /> 
40 
41<#function map_categories categories> 
42	<#assign categories_map = {} /> 
43 
44	<#list categories as category> 
45		<#assign category_name = category.getName() /> 
46		<#assign vocabulary_name = asset_vocabulary_local_service.getVocabulary(category.getVocabularyId()).getName() /> 
47 
48		<#if vocabularies?seq_contains(vocabulary_name)> 
49			<#if categories_map[vocabulary_name]?has_content> 
50				<#assign categories_map = categories_map + {vocabulary_name: categories_map[vocabulary_name] + [category_name]} /> 
51			<#else> 
52				<#assign categories_map = categories_map + {vocabulary_name: [category_name]} /> 
53			</#if> 
54		</#if> 
55	</#list> 
56 
57	<#return categories_map /> 
58</#function> 
59 
60<p class="standard-padding"> 
61	<style> 
62		.left-caret:hover svg { 
63			transform: translateX(-0.5em); 
64
65	</style> 
66 
67	<a class="cta left-caret small-caps" href="/resources"> 
68		<svg height="10" width="6"><use xlink:href="#leftCaret"></use></svg> 
69 
70		${languageUtil.format(locale, "back-to-x", languageUtil.get(locale, "resources"))} 
71	</a> 
72</p> 
73 
74<div class="resource-display"> 
75	<#if dl_file_entry_local_service.fetchFileEntry(groupId, folder_id, title)??> 
76		<#assign dl_file_entry = dl_file_entry_local_service.fetchFileEntry(groupId, folder_id, title) /> 
77	<#elseif dl_file_entry_local_service.fetchDLFileEntry(resource_id)??> 
78		<#assign dl_file_entry = dl_file_entry_local_service.fetchDLFileEntry(resource_id) /> 
79	</#if> 
80 
81	<#if journal_article_local_service.fetchArticleByUrlTitle(groupId, title)??> 
82		<#assign article = journal_article_local_service.fetchArticleByUrlTitle(groupId, title) /> 
83	<#elseif journal_article_local_service.fetchArticle(groupId, resource_id?string)??> 
84		<#assign article = journal_article_local_service.fetchArticle(groupId, resource_id?string) /> 
85	</#if> 
86 
87	<#assign entries = [] /> 
88	<#assign related_links = [] /> 
89 
90	<#if article??> 
91		<#assign related_links = get_related_links("com.liferay.journal.model.JournalArticle", article.getResourcePrimKey()) /> 
92 
93		<#assign default_title = article.getTitle(locale) + " | " + company.getName() /> 
94		<#assign expando_bridge = article.getExpandoBridge() /> 
95 
96		<#assign age_of_article = (.now?long - article.displayDate?long) / (1000 * 60 * 60 * 24) /> 
97		<#assign hubspot_form_article_id = "230289858" /> 
98 
99		<#assign document = saxReaderUtil.read(article.getContent()) /> 
100 
101		<#assign company_name = document.selectSingleNode("//dynamic-element[@name='company_name']/dynamic-content")! /> 
102		<#assign gated_teaser_content = document.selectSingleNode("//dynamic-element[@name='gated_teaser_content']/dynamic-content")! /> 
103		<#assign is_gated = document.selectSingleNode("//dynamic-element[@name='is_gated']/dynamic-content")! /> 
104 
105		<#if (age_of_article < 90) && ((passed_gated != "true") && ((is_gated.getData())?? && (is_gated.getData() == "true")))> 
106			<div class="block-container justify-center large-padding max-lg"> 
107				<div class="block left-block text-center title-image w30"> 
108					<@resource_icon /> 
109				</div> 
110 
111				<div class="block right-block w70"> 
112					<#if company_name.getData()?has_content> 
113						<h1 class="title"> 
114							${company_name.getData()} 
115						</h1> 
116					</#if> 
117 
118					<#if gated_teaser_content.getData()?has_content> 
119						<div class="gated-teaser-content"> 
120							${gated_teaser_content.getData()} 
121						</div> 
122					</#if> 
123 
124					<#assign custom_resource_url = "/resource/" + title + "?gt=true" /> 
125 
126					<@liferay_portlet["runtime"] 
127						defaultPreferences="" 
128						instanceId="${hubspot_form_article_id}" 
129						portletName="com_liferay_journal_content_web_portlet_JournalContentPortlet" 
130						queryString="customResourceUrl=${htmlUtil.escapeURL(custom_resource_url)}" 
131					/> 
132				</div> 
133			</div> 
134		<#else> 
135			<@article_utilities.embed_journal_article article /> 
136		</#if> 
137	<#elseif dl_file_entry??> 
138		<#assign categories = map_categories(asset_category_local_service.getCategories("com.liferay.document.library.kernel.model.DLFileEntry", dl_file_entry.getPrimaryKey())) /> 
139		<#assign default_title = dl_file_entry.getTitle() + " | " + company.getName() /> 
140		<#assign dl_file_entry_url = "/documents/" + groupId + "/" + dl_file_entry.getFolderId() + "/" + dl_file_entry.getTitle() /> 
141		<#assign expando_bridge = dl_file_entry.getExpandoBridge() /> 
142		<#assign hubspot_form_article_id = "691288" /> 
143		<#assign related_links = get_related_links("com.liferay.document.library.kernel.model.DLFileEntry", dl_file_entry.getPrimaryKey()) /> 
144 
145		<div class="block-container"> 
146			<div class="block long-form"> 
147				<#assign fieldsMap = dl_file_entry.getDDMFormValuesMap(dl_file_entry.getFileVersion().getFileVersionId()) /> 
148 
149				<#list fieldsMap?values as field> 
150					<#assign title = dl_file_entry.getTitle() /> 
151					<#assign display_title = fieldsMap["display_title"]! /> 
152 
153					<#assign cover_image = (field.getDDMFormFieldValuesMap().get("cover_image"))! /> 
154 
155					<#if display_title?has_content && display_title.getValue()?has_content> 
156						<#assign title = display_title.getValue() /> 
157					</#if> 
158				</#list> 
159 
160				<h1 class="long-form-title title w70"> 
161					${title} 
162				</h1> 
163 
164				<div class="block-container description-sidebar-wrapper flex-row-reverse no-padding"> 
165					<div class="block sidebar-info w30"> 
166						<#if categories?size gt 0> 
167							<@Sidebar title="Details"> 
168								<#list vocabularies as vocabulary> 
169									<#assign list = "" /> 
170 
171									<#if categories[vocabulary]?has_content> 
172										<#list categories[vocabulary] as category> 
173											<#if list?has_content> 
174												<#assign list = list + ", " + category /> 
175											<#else> 
176												<#assign list = category /> 
177											</#if> 
178										</#list> 
179 
180										<@InfoGroup direction="vertical" key="${vocabulary}" value="${list}" /> 
181									</#if> 
182								</#list> 
183							</@Sidebar> 
184						</#if> 
185 
186						<@SocialMediaIcons alignment="left" mode="share" title="Share this post" networks="facebook,twitter,linkedin" /> 
187					</div> 
188 
189					<div class="block regular-content w70"> 
190						<p class="description "> 
191							${dl_file_entry.getDescription()} 
192						</p> 
193 
194						<div class="block title-image" style="max-width:602px;"> 
195							<#assign version = dl_file_entry.getFileVersion()["version"] /> 
196							<#assign uuid = dl_file_entry.getUuid() /> 
197 
198							<object class="document-image-preview" data="/documents/${groupId}/${folder_id}/${title}/${uuid}/?version=${version}&previewFileIndex=1" type="image/png"> 
199								<@resource_icon /> 
200							</object> 
201						</div> 
202					</div> 
203				</div> 
204 
205				<#assign embed_asset_id = dl_file_entry.getFileEntryId() /> 
206 
207				<#assign VOID = freeMarkerPortletPreferences.setValue("articleId", hubspot_form_article_id) /> 
208 
209				<@liferay_portlet["runtime"] 
210					defaultPreferences=freeMarkerPortletPreferences.toString() 
211					instanceId="123423423" 
212					portletName="com_liferay_journal_content_web_portlet_JournalContentPortlet" 
213					queryString="assetId=${embed_asset_id}" 
214				/> 
215 
216				<div class="large-padding-vertical sharing-mobile"> 
217					<@SocialMediaIcons alignment="center" mode="share" networks="facebook,linkedin,twitter" title="" /> 
218				</div> 
219			</div> 
220		</div> 
221	<#else> 
222		<p class="standard-padding"> 
223			${lang.localize("resource_not_found", "Resource not found.")} 
224		</p> 
225	</#if> 
226 
227	<#list related_links as entry> 
228		<#if entry_index < 3> 
229			<#assign related_asset_entry_id = entry.getEntryId2() /> 
230 
231			<#assign related_asset_entry = asset_entry_local_service.getEntry(related_asset_entry_id) /> 
232 
233			<#assign entries = entries + [related_asset_entry] /> 
234		</#if> 
235	</#list> 
236 
237	<#if entries?size gt 0> 
238		<div class="related-link section-padding"> 
239			<h3 class="text-center"> 
240				${lang.localize("you_might_be_interested_in", "You might be interested in...")} 
241			</h3> 
242 
243			<div class="resource-template standard-padding-vertical"> 
244				<#include "${templatesPath}/RESOURCES" /> 
245			</div> 
246		</div> 
247	</#if> 
248 
249	<#if expando_bridge??> 
250		<@article_utilities.set_seo_from_expando_bridge expando_bridge default_title companyId /> 
251	</#if> 
252</div> 
253 
254<#macro resource_icon> 
255	<svg class="document-image-preview" viewBox="0 0 145 188" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> 
256		<path class="secondary-fill" d="M144,118l-69,69h66.1c1.6,0,2.9-1.3,2.9-2.9V118z"/> 
257		<polygon class="alt-secondary-fill" points="75,187 135.3,187 105.1,156.9 "/> 
258		<path class="primary-fill" d="M83,1l61,61V4c0-1.7-1.3-3-3-3H83z"/> 
259		<polygon class="accent-fill" points="144,62 144,25.1 125.5,43.5 "/> 
260		<path class="element-stroke transparent-fill" d="M141.5,187.5H3.5c-1.6,0-3-1.4-3-3V3.5c0-1.6,1.4-3,3-3h138c1.6,0,3,1.4,3,3v181 C144.5,186.1,143.1,187.5,141.5,187.5z"/> 
261 
262		<svg viewBox="-.25 0 270 90" width="80%" x="10%"> 
263			<use xlink:href="#liferayLogo"></use> 
264		</svg> 
265	</svg> 
266</#macro> 
267 
268<style> 
269	.resource-display ul { 
270		margin-left: 1.75rem; 
271
272 
273	.resource-display .document-image-preview { 
274		margin-bottom: 3rem; 
275		max-width: 100%; 
276
277 
278	.resource-display .regular-content { 
279		padding-right: 3em; 
280
281 
282	.resource-display .sharing-mobile { 
283		display: none; 
284
285 
286	.resource-display .title-image { 
287		max-width: 600px; 
288		width: 100%; 
289
290 
291	@media all and (max-width: 768px) { 
292		.resource-display .regular-content { 
293			padding-right: initial; 
294
295 
296		.resource-display .sharing-mobile { 
297			display: block; 
298
299 
300		.resource-display .sidebar-info .social-media-icons { 
301			display: none; 
302
303
304</style>