Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

JCR-5020: jackrabbit-webapp: deprecate RMI support "for removal" #155

Merged
merged 3 commits into from
Jan 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ You can build Jackrabbit like this:

mvn clean install

You need Maven 3 (or higher) with Java 8 (or higher) for the
You need Maven 3 (or higher) with Java 11 (or higher) for the
build. For more instructions, please see the documentation at:

http://jackrabbit.apache.org/building-jackrabbit.html
Expand Down
34 changes: 10 additions & 24 deletions jackrabbit-parent/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,13 @@
<slf4j.api.version>1.7.36</slf4j.api.version>
<slf4j.version>1.7.36</slf4j.version> <!-- sync with logback version -->
<logback.version>1.2.11</logback.version>
<java.version>1.8</java.version>
<java.version.signature>java18</java.version.signature>

<!-- determines the bytecode version (i.e. the minimum JRE required to run the build artifact) -->
<javaTargetVersion>11</javaTargetVersion>
<maven.compiler.release>${javaTargetVersion}</maven.compiler.release>
<maven.compiler.target>${javaTargetVersion}</maven.compiler.target>
<minimalJavaBuildVersion>${javaTargetVersion}</minimalJavaBuildVersion>

<skip.coverage>true</skip.coverage>
<minimum.line.coverage>0.0</minimum.line.coverage>
<minimum.branch.coverage>0.0</minimum.branch.coverage>
Expand Down Expand Up @@ -204,29 +209,10 @@
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<target>${java.version}</target>
<source>${java.version}</source>
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>animal-sniffer-maven-plugin</artifactId>
<version>1.23</version>
<configuration>
<signature>
<groupId>org.codehaus.mojo.signature</groupId>
<artifactId>${java.version.signature}</artifactId>
<version>1.0</version>
</signature>
<compilerArgs>
<arg>-Xpkginfo:always</arg>
</compilerArgs>
</configuration>
<executions>
<execution>
<phase>compile</phase>
<goals>
<goal>check</goal>
</goals>
</execution>
</executions>
</plugin>
<!-- Generate aggregate Javadocs -->
<plugin>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public class BootstrapConfig extends AbstractConfig {

private JNDIConfig jndiConfig = new JNDIConfig(this);

@Deprecated private RMIConfig rmiConfig = new RMIConfig(this);
@Deprecated(forRemoval = true) private RMIConfig rmiConfig = new RMIConfig(this);

public void init(Properties props) throws ServletException {
String property = props.getProperty("repository.home");;
Expand Down Expand Up @@ -110,14 +110,14 @@ public void setRepositoryName(String repositoryName) {
/**
* @deprecated RMI support is deprecated and will be removed in a future version of Jackrabbit; see <a href=https://issues.apache.org/jira/browse/JCR-4972 target=_blank>Jira ticket JCR-4972</a> for more information.
*/
@Deprecated public JNDIConfig getJndiConfig() {
@Deprecated(forRemoval = true) public JNDIConfig getJndiConfig() {
return jndiConfig;
}

/**
* @deprecated RMI support is deprecated and will be removed in a future version of Jackrabbit; see <a href=https://issues.apache.org/jira/browse/JCR-4972 target=_blank>Jira ticket JCR-4972</a> for more information.
*/
@Deprecated public RMIConfig getRmiConfig() {
@Deprecated(forRemoval = true) public RMIConfig getRmiConfig() {
return rmiConfig;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
* +-------------------+--------------------+
* </pre>
*/
@Deprecated public class RMIConfig extends AbstractConfig {
@Deprecated(forRemoval = true) public class RMIConfig extends AbstractConfig {

/**
* default logger
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ private Repository getRepositoryByJNDI() throws ServletException {
* @return the repository or <code>null</code>
* @throws ServletException if this servlet is not properly configured.
*/
@Deprecated private Repository getRepositoryByRMI() throws ServletException {
@Deprecated(forRemoval = true) private Repository getRepositoryByRMI() throws ServletException {
BootstrapConfig config = getConfig();
if (!config.getRmiConfig().isValid() || !config.getRmiConfig().enabled()) {
return null;
Expand Down Expand Up @@ -345,7 +345,7 @@ public BootstrapConfig getBootstrapConfig() {
* <p>
* optional class for RMI, will only be used, if RMI client is present
*/
@Deprecated protected static abstract class ClientFactoryDelegater {
@Deprecated(forRemoval = true) protected static abstract class ClientFactoryDelegater {

public abstract Repository getRepository(String uri)
throws RemoteException, MalformedURLException, NotBoundException;
Expand All @@ -356,7 +356,7 @@ public abstract Repository getRepository(String uri)
* <p>
* optional class for RMI, will only be used, if RMI server is present
*/
@Deprecated protected static class RMIClientFactoryDelegater extends ClientFactoryDelegater {
@Deprecated(forRemoval = true) protected static class RMIClientFactoryDelegater extends ClientFactoryDelegater {

// only used to enforce linking upon Class.forName()
static String FactoryClassName = ClientRepositoryFactory.class.getName();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ public class RepositoryStartupServlet extends AbstractRepositoryServlet {
*/
private InitialContext jndiContext;

@Deprecated private Registry rmiRegistry = null;
@Deprecated(forRemoval = true) private Registry rmiRegistry = null;

/**
* @deprecated RMI support is deprecated and will be removed in a future version of Jackrabbit; see <a href=https://issues.apache.org/jira/browse/JCR-4972 target=_blank>Jira ticket JCR-4972</a> for more information.
Expand All @@ -192,7 +192,7 @@ public class RepositoryStartupServlet extends AbstractRepositoryServlet {
* @see #registerRMI()
* @see #unregisterRMI()
*/
@Deprecated private Remote rmiRepository;
@Deprecated(forRemoval = true) private Remote rmiRepository;

/**
* the file to the bootstrap config
Expand Down Expand Up @@ -498,7 +498,7 @@ private void unregisterJNDI() {
* the repository with an RMI registry.
* @throws ServletException if an error occurs.
*/
@Deprecated private void registerRMI() {
@Deprecated(forRemoval = true) private void registerRMI() {
RMIConfig rc = config.getRmiConfig();
if (!rc.isValid() || !rc.enabled()) {
return;
Expand Down Expand Up @@ -597,7 +597,7 @@ private void unregisterJNDI() {
* Unregisters the repository from the RMI registry, if it has previously
* been registered.
*/
@Deprecated private void unregisterRMI() {
@Deprecated(forRemoval = true) private void unregisterRMI() {
if (rmiRepository != null) {
// Forcibly unexport the repository;
try {
Expand Down Expand Up @@ -668,7 +668,7 @@ protected String getRemoteFactoryDelegaterClass() {
* creating <code>java.net.ServerSocket</code> instances bound to
* the <code>rmiHost</code>.
*/
@Deprecated protected RMIServerSocketFactory getRMIServerSocketFactory(
@Deprecated(forRemoval = true) protected RMIServerSocketFactory getRMIServerSocketFactory(
final InetAddress hostAddress) {
return new RMIServerSocketFactory() {
public ServerSocket createServerSocket(int port) throws IOException {
Expand All @@ -682,7 +682,7 @@ public ServerSocket createServerSocket(int port) throws IOException {
* <p>
* optional class for RMI, will only be used, if RMI server is present
*/
@Deprecated protected static abstract class RemoteFactoryDelegater {
@Deprecated(forRemoval = true) protected static abstract class RemoteFactoryDelegater {

public abstract Remote createRemoteRepository(Repository repository)
throws RemoteException;
Expand All @@ -693,7 +693,7 @@ public abstract Remote createRemoteRepository(Repository repository)
* <p>
* optional class for RMI, will only be used, if RMI server is present
*/
@Deprecated protected static class RMIRemoteFactoryDelegater extends RemoteFactoryDelegater {
@Deprecated(forRemoval = true) protected static class RMIRemoteFactoryDelegater extends RemoteFactoryDelegater {

private static final RemoteAdapterFactory FACTORY =
new ServerAdapterFactory();
Expand Down