<?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>Changes to ServiceBuilder not visible after redeploy with Developer Studio</title>
  <link rel="self" href="https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=121138303" />
  <subtitle>Changes to ServiceBuilder not visible after redeploy with Developer Studio</subtitle>
  <id>https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=121138303</id>
  <updated>2026-05-29T15:52:54Z</updated>
  <dc:date>2026-05-29T15:52:54Z</dc:date>
  <entry>
    <title>RE: RE: Changes to ServiceBuilder not visible after redeploy with Developer</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=121306468" />
    <author>
      <name>Scarletake Bwi</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=121306468</id>
    <updated>2021-12-23T07:20:15Z</updated>
    <published>2021-12-23T07:20:14Z</published>
    <summary type="html">&lt;p&gt;in my experience&lt;/p&gt;
&lt;p&gt;sometime, even you use @Reference, it won't update.&lt;/p&gt;
&lt;p&gt;i will delete all in temp of tomcat, and delete all module of osgi,
  and restart with clean(if you use studio to start server)&lt;/p&gt;
&lt;p&gt;i do believe it not good practice, but it work on me.&lt;/p&gt;</summary>
    <dc:creator>Scarletake Bwi</dc:creator>
    <dc:date>2021-12-23T07:20:14Z</dc:date>
  </entry>
  <entry>
    <title>RE: Changes to ServiceBuilder not visible after redeploy with Developer Stu</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=121138364" />
    <author>
      <name>Marc-Andre Gauthier</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=121138364</id>
    <updated>2021-09-10T13:33:32Z</updated>
    <published>2021-09-10T13:33:31Z</published>
    <summary type="html">&lt;p&gt;Hi Olaf. Thanks for your time.&lt;/p&gt;
&lt;p&gt;I mainly do simple stuff like: &lt;/p&gt;
&lt;ol&gt;
  &lt;li&gt;Create a ResourceCommand class&lt;/li&gt;
  &lt;li&gt;Declare @Reference to MyServiceBuilder in the resource command.
    eg:  &lt;ol&gt;
      &lt;li&gt;@Reference&lt;/li&gt;
      &lt;li&gt;private volatile MyLocalService myLocalService&lt;/li&gt;&lt;/ol&gt;&lt;/li&gt;
  &lt;li&gt;Call a method  &lt;ol&gt;
      &lt;li&gt;myLocalService.dosomething();&lt;/li&gt;&lt;/ol&gt;&lt;/li&gt;&lt;/ol&gt;
&lt;p&gt;Only thing out of the ordinary is that I have declared a class inside
  the servicebuilder project that i use in the other projects. eg:&lt;/p&gt;
&lt;ol&gt;
  &lt;li&gt;CustomClassDefinedInServiceBuilder something = myLocalService.doSomething();&lt;/li&gt;&lt;/ol&gt;
&lt;p&gt;Don't know if this could cause the problem. I also get errors for
  things that are not related to that custom class. I also get a
  nosuchmethod exception on myLocalService.doSomething() if I change the
  signature of doSomething() for example. &lt;/p&gt;
&lt;p&gt;Anyway this is not a blocking problem. Just takes a takes a bit more
  time waiting for the server to restart. &lt;/p&gt;
&lt;p&gt;Thanks again.&lt;/p&gt;</summary>
    <dc:creator>Marc-Andre Gauthier</dc:creator>
    <dc:date>2021-09-10T13:33:31Z</dc:date>
  </entry>
  <entry>
    <title>RE: Changes to ServiceBuilder not visible after redeploy with Developer Stu</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=121138448" />
    <author>
      <name>Olaf Kock</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=121138448</id>
    <updated>2021-09-10T13:13:19Z</updated>
    <published>2021-09-10T13:13:19Z</published>
    <summary type="html">&lt;p&gt;Do you store any of the services or objects outside of the service
  projects? This way the classes couldn't be unloaded and you'd see
  unexpected results with stale old class code in random locations.&lt;/p&gt;
&lt;p&gt;If you stick with @Reference and forget about those objects after
  you've used them in a request, nothing bad should happen. But if you
  hold them any longer (including the model objects), you might see
  weird behavior - especially if you're calling methods on them while
  two of the class's definitions are around.&lt;/p&gt;</summary>
    <dc:creator>Olaf Kock</dc:creator>
    <dc:date>2021-09-10T13:13:19Z</dc:date>
  </entry>
  <entry>
    <title>Changes to ServiceBuilder not visible after redeploy with Developer Studio</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=121138302" />
    <author>
      <name>Marc-Andre Gauthier</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=121138302</id>
    <updated>2021-09-10T13:00:23Z</updated>
    <published>2021-09-10T13:00:23Z</published>
    <summary type="html">&lt;p&gt;I'm developing with Dev Studio 3.9.4.&lt;/p&gt;
&lt;p&gt;Localhost server is Liferay CE 7.4.2 GA3&lt;/p&gt;
&lt;ol&gt;
  &lt;li&gt;Start localhost server from Dev Studio&lt;/li&gt;
  &lt;li&gt;Change the interface of my ServiceBuilder project (new method,
    method signature change etc.)&lt;/li&gt;
  &lt;li&gt;Rebuild my service (BuildService Gradle task)&lt;/li&gt;
  &lt;li&gt;Build is successful. Console shows &amp;quot;myservice stopped&amp;quot;
    &amp;quot;myservice started&amp;quot;&lt;/li&gt;
  &lt;li&gt;In eclipse, intellisense detects with my new code (method or
    method signature)&lt;/li&gt;
  &lt;li&gt;I get runtime errors (eg: nosuchmethod exceptions etc.)&lt;/li&gt;
  &lt;li&gt;I have to restart my local server and then runtime errors are gone
    and everything is ok&lt;/li&gt;&lt;/ol&gt;
&lt;p&gt;Is there a way to avoid from restarting the server? I don't have this
  problem for other projects (eg: portlet). Changes for these projects
  are immediately available. &lt;/p&gt;
&lt;p&gt;Am I missing something for ServiceBuilder?&lt;/p&gt;
&lt;p&gt;Thanks in advance.&lt;/p&gt;</summary>
    <dc:creator>Marc-Andre Gauthier</dc:creator>
    <dc:date>2021-09-10T13:00:23Z</dc:date>
  </entry>
</feed>
