Skip to content

Commit

Permalink
Ibis 4.0.1m from VisualAge. Changes: version added, versioninfo in Co…
Browse files Browse the repository at this point in the history
…nfiguration.java and StatisticsKeeper variance calculation
  • Loading branch information
unknown committed Feb 4, 2004
0 parents commit 61f6078
Show file tree
Hide file tree
Showing 121 changed files with 15,600 additions and 0 deletions.
23 changes: 23 additions & 0 deletions .classpath
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="Java Source"/>
<classpathentry kind="var" path="JRE_LIB" rootpath="JRE_SRCROOT" sourcepath="JRE_SRC"/>
<classpathentry kind="lib" path="/IbisWar/Web Content/WEB-INF/lib/NNCoolgenJavaProxies.jar"/>
<classpathentry kind="lib" path="/IbisWar/Web Content/WEB-INF/lib/activation.jar"/>
<classpathentry kind="lib" path="/IbisWar/Web Content/WEB-INF/lib/com.ibm.mqjms.jar"/>
<classpathentry kind="lib" path="/IbisWar/Web Content/WEB-INF/lib/commons-lang-2.0.jar"/>
<classpathentry kind="lib" path="/IbisWar/Web Content/WEB-INF/lib/jaxp.jar"/>
<classpathentry kind="lib" path="/IbisWar/Web Content/WEB-INF/lib/jaxrpc.jar"/>
<classpathentry kind="lib" path="/IbisWar/Web Content/WEB-INF/lib/log4j-1.2.7.jar"/>
<classpathentry kind="lib" path="/IbisWar/Web Content/WEB-INF/lib/quartz123.jar"/>
<classpathentry kind="lib" path="/IbisWar/Web Content/WEB-INF/lib/rowset.jar"/>
<classpathentry kind="lib" path="/IbisWar/Web Content/WEB-INF/lib/soap.jar"/>
<classpathentry kind="lib" path="/IbisWar/Web Content/WEB-INF/lib/struts-11-final-Websphere.jar"/>
<classpathentry kind="lib" path="/IbisWar/Web Content/WEB-INF/lib/xalan.jar"/>
<classpathentry kind="lib" path="/IbisWar/Web Content/WEB-INF/lib/xerces.jar"/>
<classpathentry kind="lib" path="/IbisWar/Web Content/WEB-INF/lib/commons-beanutils.jar"/>
<classpathentry kind="var" path="WAS_PLUGINDIR/lib/j2ee.jar"/>
<classpathentry kind="lib" path="/IbisWar/Web Content/WEB-INF/lib/commons-digester.jar"/>
<classpathentry kind="lib" path="H:/Ios/1_OO_straat/Technologie/libraries/Apache commons/cli/cli-1.0/commons-cli-1.0.jar"/>
<classpathentry kind="output" path="bin"/>
</classpath>
22 changes: 22 additions & 0 deletions .project
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>Ibis</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>com.ibm.etools.j2ee.LibCopyBuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.jdt.core.javanature</nature>
</natures>
</projectDescription>
61 changes: 61 additions & 0 deletions JavaSource/AppConstants.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
#
# NN IOS AdapterFramework
#
# Application Constants
#

#This file will be loaded also
ADDITIONAL.PROPERTIES.FILE=DeploymentSpecifics.properties

application.name =Ibis
application.version =4.0



#
# Key under the ServletContext that the configuration is stored.
#
KEY_CONFIGURATION =config

#
#Cookie name under which the cookie for sendJmsMessage (action) is stored
#
WEB_JMSCOOKIE_NAME =sendJmsMessage

# indicates wether (with loglevel debug) the results between calling pipes have to be logged.
log.logIntermediaryResults=true

# the name of this instance of the AdapterFramework
instance.name=Ibis

# the path where the logging can be found, respectively the wildcard for log-files
logging.path=${log.dir}
logging.wildcard=*.log*

#
# Class boundaries for StatisticsKeeper. [milliseconds]

Statistics.boundaries=100,700,1000,2000


#
# Definitions for the FileViewerServlet
#

# a comma-separated list of words that will be marked
FileViewerServlet.signal=ERROR,WARN,INFO,DEBUG

FileViewerServlet.signal.ERROR.pre=<font color="red">
FileViewerServlet.signal.ERROR.post=</font>
FileViewerServlet.signal.WARN.pre=<font color="orange">
FileViewerServlet.signal.WARN.post=</font>
FileViewerServlet.signal.INFO.pre=<font color="blue">
FileViewerServlet.signal.INFO.post=</font>
FileViewerServlet.signal.DEBUG.pre=<font color="green">
FileViewerServlet.signal.DEBUG.post=</font>

# indication of stylesheet to use
FileViewerServlet.signal.css=ie4.css

# hide passwords in the configuration.xml in the webapplication
showConfiguration.resolve.variables=false
147 changes: 147 additions & 0 deletions JavaSource/nl/nn/adapterframework/cmdline/StartReceiving.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,147 @@
package nl.nn.adapterframework.cmdline;

import nl.nn.adapterframework.receivers.JmsMessageReceiver;
import nl.nn.adapterframework.jms.JmsMessageListener;

import org.apache.commons.cli.Options;
import org.apache.commons.cli.CommandLine;
import org.apache.commons.cli.GnuParser;
import org.apache.commons.cli.ParseException;
import org.apache.commons.cli.HelpFormatter;


/**
*
* Configures a queue connection and receiver and starts listening to it.
* @author Johan Verrips
* @created 14 februari 2003
*/
public class StartReceiving {
public static final String version="$Id: StartReceiving.java,v 1.1 2004-02-04 08:36:13 a1909356#db2admin Exp $";


static final String DFLT_ACKNOWLEDGEMODE = "client";
static final boolean DFLT_PERSISTENT = false;
static final String DFLT_QCFN = "QueueConnectionFactory";
static final String DFLT_TCFN = "TopicConnectionFactory";

/**
* The main program for the jms.JmsMessageReceiver class
*
* @param args The command line arguments. use -help to show options
*/
public static void main(String[] args) {

CommandLine cmdline = null;
GnuParser gp = new GnuParser();

try {
cmdline = gp.parse(makeOptions(), args);
} catch (ParseException e) {
HelpFormatter h = new HelpFormatter();
h.printHelp("this is help", makeOptions());
System.out.println(e.getMessage());
System.exit(1);
}


if (cmdline.hasOption("help")) {
// the help option has been specified, print the usage
// information
usage();
} else if (cmdline.hasOption("destination")) {

// default values
String acknowledgeMode = DFLT_ACKNOWLEDGEMODE;
boolean persistent = DFLT_PERSISTENT;
String icf = null;
String providerURL = null;


// persistent
int secs = -1;
// seconds to timeout

// see if an ack mode has been specified. If it hasn't
// then assume CLIENT_ACKNOWLEDGE mode.

if (cmdline.hasOption("ackmode")) {
acknowledgeMode=cmdline.getOptionValue("ackmode");
}

if (cmdline.hasOption("icf")) {
icf = cmdline.getOptionValue("icf");
}
String destination_name = cmdline.getOptionValue("destination");
String destination_type = cmdline.getOptionValue("desttype");

if (destination_name != null) {

if (cmdline.hasOption("url")) {
providerURL = cmdline.getOptionValue("url");
}

if (cmdline.hasOption("persistent")) {
persistent = true;
}

if (cmdline.hasOption("timeout")) {
secs = Integer.parseInt(cmdline.getOptionValue("timeout"));
}

JmsMessageReceiver receiver = new JmsMessageReceiver();
JmsMessageListener listener = (JmsMessageListener)(receiver.getListener());
listener.setAcknowledgeMode(acknowledgeMode);
listener.setDestinationName(destination_name);
listener.setDestinationType(destination_type);
if (cmdline.hasOption("qcfn"))
listener.setQueueConnectionFactoryName(cmdline.getOptionValue("qcfn"));
else
listener.setQueueConnectionFactoryName(DFLT_QCFN);
if (cmdline.hasOption("tcfn"))
listener.setTopicConnectionFactoryName(cmdline.getOptionValue("tcfn"));
else
listener.setTopicConnectionFactoryName(DFLT_TCFN);

listener.setDestinationName(destination_name);
listener.setPersistent(persistent);
//listener.setSecondsToTimeout(secs);
if (null!=providerURL) listener.setProviderURL(providerURL);
if (null!=icf) listener.setInitialContextFactoryName(icf) ;
receiver.startRunning();


} else {
// anything else print the usage message
usage();
}
}
}
/**
* Function to return and define the options valid for the Command Line Interface (CLI)
* @see org.apache.commons.cli.Options
* @return Options object
*/
static Options makeOptions() {
Options options = new Options();
options.addOption("destination", true, "destination name");
options.addOption("desttype", true, "destination type, should be QUEUE or TOPIC");
options.addOption("ackmode", true, "<auto | client | dups>, defaults to" +DFLT_ACKNOWLEDGEMODE);
options.addOption("persistent", false, "specifies persistent delivery mode, default to "+DFLT_PERSISTENT);
options.addOption("icf", true, "initial connection factory, you may also specify this by the -Djava.naming.factory.initial=<value> option ");
options.addOption("url", true, "provider url, you may also specify this by the -Djava.naming.provider.url=value option)");
options.addOption("timeout", true, "seconds to wait before exiting");
options.addOption("help", false, "display help");
options.addOption("qcfn", true, "queue connection factory name, defaults to "+DFLT_QCFN);
options.addOption("tcfn", true, "topic connection factory name, defaults to "+DFLT_TCFN);
return options;
}
/**
* Print out information on running this sevice
*/

protected static void usage() {
HelpFormatter h = new HelpFormatter();
h.printHelp("this is help", makeOptions());
}
}
Loading

0 comments on commit 61f6078

Please sign in to comment.