Skip to content

Commit

Permalink
Removal of unused code when I was searching why imq broker stops too …
Browse files Browse the repository at this point in the history
…late

Signed-off-by: David Matějček <david.matejcek@omnifish.ee>
  • Loading branch information
dmatej committed Dec 11, 2022
1 parent 968b4ca commit 83e5907
Show file tree
Hide file tree
Showing 7 changed files with 1 addition and 114 deletions.
12 changes: 0 additions & 12 deletions appserver/tests/appserv-tests/config/common.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1488,18 +1488,6 @@ AS_ADMIN_MASTERPASSWORD=${master.password}
<property file="${env.APS_HOME}/config/pointbase.properties" />
</target>

<!-- setup IMQ for RI Build -->
<target name="setup-mq-common" depends="init-common">
<echo message="Executing Datastore setup for S1MQ. Required only for RI" level="verbose" />
<echo
message="${IMQDBMGR} -javahome ${java.home}
-b ${admin.domain}_${appserver.instance.name} create all"
level="verbose" />
<exec executable="${IMQDBMGR}" failonerror="true">
<arg line="-javahome ${java.home} -b ${admin.domain}_${appserver.instance.name} create all" />
</exec>
</target>

<target name="import-wsdl" depends="init-common">
<mkdir dir="${build.classes.dir}" />
<exec executable="${WSCOMPILE}">
Expand Down
2 changes: 0 additions & 2 deletions appserver/tests/appserv-tests/config/properties.xml
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,6 @@ AS_ADMIN_MASTERPASSWORD=${master.password}</echo>
<property name="WSIMPORT" value="${env.S1AS_HOME}/bin/wsimport.bat" />
<property name="pb.start.server" value="${env.S1AS_HOME}/pointbase/server/StartServer.bat" />
<property name="pb.start.server1" value="${env.S1AS_HOME}/pointbase/server/StartServer1.bat" />
<property name="IMQDBMGR" value="${env.S1AS_HOME}/imq/bin/imqdbmgr.bat" />
<property name="ld.library.path" location="${env.S1AS_HOME}/lib;${env.S1AS_HOME}/bin" />
</target>

Expand All @@ -201,7 +200,6 @@ AS_ADMIN_MASTERPASSWORD=${master.password}</echo>
<property name="WSIMPORT" value="${env.S1AS_HOME}/bin/wsimport" />
<property name="pb.start.server" value="${env.S1AS_HOME}/pointbase/server/StartServer" />
<property name="pb.start.server1" value="${env.S1AS_HOME}/pointbase/server/StartServer1" />
<property name="IMQDBMGR" value="${env.S1AS_HOME}/imq/bin/imqdbmgr" />
<property name="ld.library.path" location="${env.S1AS_HOME}/lib:${env.S1AS_HOME}/bin" />
</target>

Expand Down
12 changes: 0 additions & 12 deletions appserver/tests/appserv-tests/devtests/cdi/osgi-cdi/common.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1571,18 +1571,6 @@ AS_ADMIN_MASTERPASSWORD=${master.password}
<property file="${env.APS_HOME}/config/pointbase.properties"/>
</target>

<!-- setup IMQ for RI Build -->
<target name="setup-mq-common" depends="init-common">
<echo message="Executing Datastore setup for S1MQ. Required only for RI"
level="verbose"/>
<echo message="${IMQDBMGR} -javahome ${java.home}
-b ${admin.domain}_${appserver.instance.name} create all"
level="verbose"/>
<exec executable="${IMQDBMGR}" failonerror="true">
<arg line="-javahome ${java.home} -b ${admin.domain}_${appserver.instance.name} create all" />
</exec>
</target>

<target name="import-wsdl" depends="init-common">
<mkdir dir="${build.classes.dir}"/>
<exec executable="${WSCOMPILE}">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1571,18 +1571,6 @@ AS_ADMIN_MASTERPASSWORD=${master.password}
<property file="${env.APS_HOME}/config/pointbase.properties"/>
</target>

<!-- setup IMQ for RI Build -->
<target name="setup-mq-common" depends="init-common">
<echo message="Executing Datastore setup for S1MQ. Required only for RI"
level="verbose"/>
<echo message="${IMQDBMGR} -javahome ${java.home}
-b ${admin.domain}_${appserver.instance.name} create all"
level="verbose"/>
<exec executable="${IMQDBMGR}" failonerror="true">
<arg line="-javahome ${java.home} -b ${admin.domain}_${appserver.instance.name} create all" />
</exec>
</target>

<target name="import-wsdl" depends="init-common">
<mkdir dir="${build.classes.dir}"/>
<exec executable="${WSCOMPILE}">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -200,42 +200,6 @@ includes="*.jar"/>
</condition>
</target>

<target name="setToolWin" if="isWindows">
<property name="APPCLIENT" value="${env.S1AS_HOME}/bin/appclient.bat"/>
<property name="ASADMIN" value="${env.S1AS_HOME}/bin/asadmin.bat"/>
<property name="IMQCMD" value="${env.S1AS_HOME}/imq/bin/imqcmd.exe"/>
<property name="IMQBROKERD" value="${env.S1AS_HOME}/imq/bin/imqbrokerd.exe"/>
<property name="ASANT" value="${env.S1AS_HOME}/bin/asant.bat"/>
<property name="CAPTURESCHEMA" value="${env.S1AS_HOME}/bin/capture-schema.bat"/>
<property name="CHECKPATCH" value="${env.S1AS_HOME}/bin/checkpatch.bat"/>
<property name="INSTALLPATCH" value="${env.S1AS_HOME}/bin/installpatch.bat"/>
<property name="JSPC" value="${env.S1AS_HOME}/bin/jspc.bat"/>
<property name="LISTPATCH" value="${env.S1AS_HOME}/bin/listpatch.bat"/>
<property name="PACKAGE-APPCLIENT" value="${env.S1AS_HOME}/bin/package-appclient.bat"/>
<property name="VERIFIER" value="${env.S1AS_HOME}/bin/verifier.bat"/>
<property name="RMIC" value="${env.S1AS_HOME}/jdk/bin/rmic.exe"/>
<property name="TNAMESERV" value="${env.S1AS_HOME}/jdk/bin/tnameserv.exe"/>
<property name="WSCOMPILE" value="${env.S1AS_HOME}/bin/wscompile.bat"/>
</target>

<target name="setToolUnix" if="isUnix">
<property name="APPCLIENT" value="${env.S1AS_HOME}/bin/appclient"/>
<property name="ASADMIN" value="${env.S1AS_HOME}/bin/asadmin"/>
<property name="IMQCMD" value="${env.S1AS_HOME}/imq/bin/imqcmd"/>
<property name="IMQBROKERD" value="${env.S1AS_HOME}/imq/bin/imqbrokerd"/>
<property name="ASANT" value="${env.S1AS_HOME}/bin/asant"/>
<property name="CAPTURESCHEMA" value="${env.S1AS_HOME}/bin/capture-schema"/>
<property name="CHECKPATCH" value="${env.S1AS_HOME}/bin/checkpatch"/>
<property name="INSTALLPATCH" value="${env.S1AS_HOME}/bin/installpatch"/>
<property name="JSPC" value="${env.S1AS_HOME}/bin/jspc"/>
<property name="LISTPATCH" value="${env.S1AS_HOME}/bin/listpatch"/>
<property name="PACKAGE-APPCLIENT" value="${env.S1AS_HOME}/bin/package-appclient"/>
<property name="VERIFIER" value="${env.S1AS_HOME}/bin/verifier"/>
<property name="RMIC" value="${env.S1AS_HOME}/jdk/bin/rmic"/>
<property name="TNAMESERV" value="${env.S1AS_HOME}/jdk/bin/tnameserv"/>
<property name="WSCOMPILE" value="${env.S1AS_HOME}/bin/wscompile"/>
</target>

<target name="fixFiles" depends="setOSConditions" >
<antcall target="convUnix" />
<antcall target="convWin" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
import com.sun.enterprise.admin.util.TokenValueSet;
import com.sun.enterprise.security.store.PasswordAdapter;
import com.sun.enterprise.util.OS;
import com.sun.enterprise.util.ProcessExecutor;


//import javax.management.remote.JMXAuthenticator;
//import com.sun.enterprise.admin.server.core.jmx.auth.ASJMXAuthenticator;
Expand All @@ -46,9 +46,7 @@
import java.io.File;
import java.io.FilenameFilter;
import java.io.IOException;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
Expand Down Expand Up @@ -608,35 +606,6 @@ public void createWSDLSLInstallRoot(PEFileLayout layout) throws Exception {

}

/**
* Create MQ instance.
*/
protected void createMQInstance(RepositoryConfig config) throws RepositoryException {
final PEFileLayout layout = getFileLayout(config);
final File broker = layout.getImqBrokerExecutable();
final File mqVarHome = layout.getImqVarHome();
try {
FileUtils.mkdirsMaybe(mqVarHome);
final List<String> cmdInput = new ArrayList<>();
cmdInput.add(broker.getAbsolutePath());
cmdInput.add("-init");
cmdInput.add("-varhome");
cmdInput.add(mqVarHome.getAbsolutePath());
ProcessExecutor pe = new ProcessExecutor(cmdInput.toArray(new String[cmdInput.size()]));
pe.execute(false, false);
} catch (Exception ioe) {
/*
* Dont do anything. * IMQ instance is created just to make sure
* that Off line IMQ commands can be executed, even before starting
* the broker. A typical scenario is while on-demand startup is off,
* user might try to do imqusermgr. Here broker may not have
* started.
*
* Failure in creating the instance doesnt need to abort domain
* creation.
*/
}
}

/**
* Create the timer database wal file.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -454,14 +454,6 @@ public File getDomainXmlTemplate(String templateName) {
}
}

public static final String IMQBROKERD_UNIX = "imqbrokerd";
public static final String IMQBROKERD_WIN = "imqbrokerd.exe";
public static final String IMQBROKERD = isWindows() ? IMQBROKERD_WIN : IMQBROKERD_UNIX;

public File getImqBrokerExecutable() {
return new File(getImqBinDir(), IMQBROKERD);
}

public static final String START_SERV_UNIX = "startserv";
public static final String START_SERV_WIN = "startserv.bat";
public static final String START_SERV_OS = isWindows() ? START_SERV_WIN : START_SERV_UNIX;
Expand Down

0 comments on commit 83e5907

Please sign in to comment.