Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#24970 Externalizing AbstractContainerLifecycleListener to a public c…
…lass.
- Loading branch information
daniel.colina
committed
Jun 26, 2023
1 parent
12e986f
commit fa31c77
Showing
4 changed files
with
286 additions
and
132 deletions.
There are no files selected for viewing
39 changes: 39 additions & 0 deletions
39
dotCMS/src/main/java/com/dotcms/listeners/ReloadListener.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
package com.dotcms.listeners; | ||
|
||
import com.dotcms.rest.config.DotRestApplication; | ||
import com.dotcms.util.MimeTypeUtils; | ||
import com.dotmarketing.util.Logger; | ||
import org.glassfish.jersey.server.spi.AbstractContainerLifecycleListener; | ||
import org.glassfish.jersey.server.spi.Container; | ||
|
||
import java.util.concurrent.atomic.AtomicReference; | ||
|
||
public class ReloadListener extends AbstractContainerLifecycleListener { | ||
|
||
AtomicReference<Container> container = new AtomicReference<>(); | ||
|
||
// public void reload() { | ||
// Container container = this.container.get(); | ||
// if (container!=null) { | ||
// container.reload(DotRestApplication.setClasses()); | ||
// } | ||
// } | ||
|
||
@Override | ||
public void onReload(Container container) { | ||
Logger.info(this.getClass(),":::: ReloadListener.onReload() ::::"); | ||
// reload(); | ||
} | ||
|
||
@Override | ||
public void onShutdown(Container container) { | ||
Logger.info(this.getClass(),":::: ReloadListener.onShutdown() ::::"); | ||
} | ||
|
||
@Override | ||
public void onStartup(Container container) { | ||
Logger.info(this.getClass(),":::: ReloadListener.onStartup() ::::"); | ||
// this.container.set(container); | ||
} | ||
|
||
} |
Oops, something went wrong.