<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <title>How to add a dependency in core jsp fragment?</title>
  <link rel="self" href="https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=108877367" />
  <subtitle>How to add a dependency in core jsp fragment?</subtitle>
  <id>https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=108877367</id>
  <updated>2026-04-04T22:14:43Z</updated>
  <dc:date>2026-04-04T22:14:43Z</dc:date>
  <entry>
    <title>RE: How to add a dependency in core jsp fragment?</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=110875052" />
    <author>
      <name>Olaf Kock</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=110875052</id>
    <updated>2018-09-04T10:20:26Z</updated>
    <published>2018-09-04T10:20:26Z</published>
    <summary type="html">&lt;blockquote&gt;
  &lt;div class="quote-title"&gt;Tomas Polesovsky:&lt;/div&gt;
  &lt;div class="quote"&gt;
    &lt;div class="quote-content"&gt;
      &lt;p&gt;portal-web is not OSGi bundle, it's not possible to use OSGi
        fragments. If you need to modify Core JSP you should write a new
        module with a DynamicInclude&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/blockquote&gt;
&lt;p&gt;Amazing how persistently I've read over the &amp;quot;core&amp;quot; part of
  the question. Thanks, Tom, for paying close attention.&lt;/p&gt;
&lt;p&gt;If nothing else, you could deploy a core jsp change through an old
  hook, but limit the introduced difference to a new dynamic include,
  then provide a module to implement this DI.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt; &lt;/p&gt;</summary>
    <dc:creator>Olaf Kock</dc:creator>
    <dc:date>2018-09-04T10:20:26Z</dc:date>
  </entry>
  <entry>
    <title>RE: How to add a dependency in core jsp fragment?</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=110872485" />
    <author>
      <name>Tomáš Polešovský</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=110872485</id>
    <updated>2018-09-04T07:49:37Z</updated>
    <published>2018-09-04T07:49:37Z</published>
    <summary type="html">&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;portal-web is not OSGi bundle, it's not possible to use OSGi
  fragments. If you need to modify Core JSP you should write a new
  module with a DynamicInclude. The use is limited but at least it
  allows referencing classes from other OSGi bundles. Dynamic Includes
  use RequestDispatcher so the JSP is loaded with your module's class
  loader that can see what's imported by your module.&lt;/p&gt;
&lt;p&gt;Another way is to use old JSP Hooks but it's not possible to
  reference JournalArticle that is inside OSGi bundle. Core JSPs
  are loaded using Tomcat's webapp class loader that doesn't inherit
  from OSGi framework class loaders. The same is with the EXT.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;HTH.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;-- tom +&lt;/p&gt;</summary>
    <dc:creator>Tomáš Polešovský</dc:creator>
    <dc:date>2018-09-04T07:49:37Z</dc:date>
  </entry>
  <entry>
    <title>RE: How to add a dependency in core jsp fragment?</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=110872151" />
    <author>
      <name>Olaf Kock</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=110872151</id>
    <updated>2018-09-04T07:39:58Z</updated>
    <published>2018-09-04T07:39:58Z</published>
    <summary type="html">&lt;blockquote&gt;
  &lt;div class="quote-title"&gt;Milind Jain:&lt;/div&gt;
  &lt;div class="quote"&gt;
    &lt;div class="quote-content"&gt;
      &lt;p&gt;I am also facing same issue. Please help.&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/blockquote&gt;
&lt;p&gt;Please give us some hints. David's Blog article answers the question
  well. And if you can't make it work, just stating that it doesn't work
  won't give anyone the opportunity to &amp;quot;check line 42&amp;quot; in your
  code, where you missed a declaration.&lt;/p&gt;
&lt;p&gt;Provide a minimal working (well, non-working in this case)
  implementation, that can be inspected and used to figure out what you
  did. Just with this statement, I'd just point you back to David's
  article. If there's something that you don't understand, just ask
  about a specific item. Or, better, post code. Simple, minimal,
  inspectable code.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt; &lt;/p&gt;</summary>
    <dc:creator>Olaf Kock</dc:creator>
    <dc:date>2018-09-04T07:39:58Z</dc:date>
  </entry>
  <entry>
    <title>RE: How to add a dependency in core jsp fragment?</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=110871469" />
    <author>
      <name>Milind Jain</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=110871469</id>
    <updated>2018-09-04T06:40:40Z</updated>
    <published>2018-09-04T06:40:40Z</published>
    <summary type="html">&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;I am also facing same issue. Please help.&lt;/p&gt;
&lt;p&gt;Thanks&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;</summary>
    <dc:creator>Milind Jain</dc:creator>
    <dc:date>2018-09-04T06:40:40Z</dc:date>
  </entry>
  <entry>
    <title>RE: How to add a dependency in core jsp fragment?</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=108878097" />
    <author>
      <name>Abhishek Jain</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=108878097</id>
    <updated>2018-05-25T11:03:32Z</updated>
    <published>2018-05-25T11:03:32Z</published>
    <summary type="html">Thanks Rayappa for your reply, &lt;br /&gt;&lt;br /&gt;I have already checked this link but could not get the answer...</summary>
    <dc:creator>Abhishek Jain</dc:creator>
    <dc:date>2018-05-25T11:03:32Z</dc:date>
  </entry>
  <entry>
    <title>RE: How to add a dependency in core jsp fragment?</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=108878289" />
    <author>
      <name>Rayappa Hattarwat</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=108878289</id>
    <updated>2018-05-25T10:38:38Z</updated>
    <published>2018-05-25T10:38:38Z</published>
    <summary type="html">Hello  Abhishek ,&lt;br /&gt;&lt;br /&gt;Check this &lt;br /&gt;https://web.liferay.com/web/user.26526/blog/-/blogs/adding-dependencies-to-jsp-fragment-bundles</summary>
    <dc:creator>Rayappa Hattarwat</dc:creator>
    <dc:date>2018-05-25T10:38:38Z</dc:date>
  </entry>
  <entry>
    <title>How to add a dependency in core jsp fragment?</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=108877366" />
    <author>
      <name>Abhishek Jain</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=108877366</id>
    <updated>2018-05-25T10:12:58Z</updated>
    <published>2018-05-25T10:12:58Z</published>
    <summary type="html">I need to make a core jsp fragment to override portal-web&amp;#39;s jsp file. In that I want to use JournalArticle class. I added dependency of journal api to resolve this but I got an exception that &lt;strong&gt;&lt;strong&gt;&lt;/strong&gt;JournalArticle cannot be resolved to a type&lt;/strong&gt;. I want to ask how to add a dependency to the portal-web fragment module. Any help would be appreciated.</summary>
    <dc:creator>Abhishek Jain</dc:creator>
    <dc:date>2018-05-25T10:12:58Z</dc:date>
  </entry>
</feed>
