<?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>Override SocialActivitiesQueryHelper</title>
  <link rel="self" href="https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=121510823" />
  <subtitle>Override SocialActivitiesQueryHelper</subtitle>
  <id>https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=121510823</id>
  <updated>2026-04-06T02:07:02Z</updated>
  <dc:date>2026-04-06T02:07:02Z</dc:date>
  <entry>
    <title>Override SocialActivitiesQueryHelper</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=121510822" />
    <author>
      <name>boveri asea</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=121510822</id>
    <updated>2022-09-09T14:20:21Z</updated>
    <published>2022-09-09T09:38:57Z</published>
    <summary type="html">&lt;pre&gt;
I am trying to override SocialActivitiesQueryHelper service from com.liferay.social.activities.web.internal.util package.

A new module is created and the service ranking is set so that my new service overrides the default one.
@Component(
    immediate = true,
    property = {
        &amp;quot;service.ranking:Integer=100&amp;quot;
    },
    service = SocialActivitiesQueryHelper.class)&lt;/pre&gt;
&lt;p&gt;public class MyCustomQueryHelper extends SocialActivitiesQueryHelper {&lt;/p&gt;
&lt;p&gt;     @Override &lt;/p&gt;
&lt;p&gt;    public List&amp;lt;SocialActivitySet&amp;gt; getSocialActivitySets(args){&lt;/p&gt;
&lt;p&gt;    // Do my changes here&lt;/p&gt;
&lt;p&gt;    }&lt;/p&gt;
&lt;p&gt;I then deploy my new module. Somehow, the getSocialActivitySets()
  from MyCustomQueryHelper service is not being triggered/called.&lt;/p&gt;
&lt;p&gt;Is this the correct approach? I would be grateful, if anyone can
  point out what I am doing wrong. Or I am open to suggestions, if there
  is a better way. Thanks a lot in advance.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;</summary>
    <dc:creator>boveri asea</dc:creator>
    <dc:date>2022-09-09T09:38:57Z</dc:date>
  </entry>
</feed>
