I am trying to intall DBPrism for Tomcat.
The installation instruction says 

build dpls.ear, executing $PRISM_HOME/applications/build_dpls.sh (or .bat on
windows) 
extract dpls.war, unziping dpls.ear file generated into $PRISM_HOME/bin.
Move to the directory $TOMCAT_HOME/webapps and execute jar xvf
$PRISM_HOME/bin/dpls.ear dpls.war 
Copy classes12.jar, from $ORACLE_HOME/jdbc/lib to $TOMCAT_HOME/common/lib 
start Tomcat, excecuting bin/catalina.sh run 
enjoy DBPrism, loading the demo page at
http://localhost:8080/dpls/sample/demo.startup 

I have an ORANT installation but I cannot locate classes12.jar, from
$ORACLE_HOME/jdbc/lib instead I find 
classes102.zip and classes111.zip
Can somebody tell me where to locate classes12.jar.

Thanks are regards.
Riyaz


-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Wednesday, March 12, 2003 10:29 AM
To: [EMAIL PROTECTED]
Subject: cvs commit:
jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core
StandardHost.java


costin      2003/03/11 22:28:55

  Modified:    catalina/src/share/org/apache/catalina/core
                        StandardHost.java
  Log:
  - remove unused imports
  - switch to commons-logging
  - lazy creation of the deployer. I did it because of some class loader
problems ( but
  the problem was elsewere ) - however it is good because we may use a
different mechanism.
  The "deployment" should be done using JMX - registering / unregistering
mbeans
  with JSR77 names should be enough.
  
  - moved the extra JMX getters from the wrapper in mbeans/
  - when the host mbean is created directly by JMX, register with the engine
  
  Revision  Changes    Path
  1.4       +80 -35
jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core/Standard
Host.java
  
  Index: StandardHost.java
  ===================================================================
  RCS file:
/home/cvs/jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/cor
e/StandardHost.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- StandardHost.java 15 Jan 2003 03:40:42 -0000      1.3
  +++ StandardHost.java 12 Mar 2003 06:28:55 -0000      1.4
  @@ -1,8 +1,4 @@
   /*
  - * $Header$
  - * $Revision$
  - * $Date$
  - *
    * ====================================================================
    *
    * The Apache Software License, Version 1.1
  @@ -66,26 +62,18 @@
   
   
   import java.io.IOException;
  -import java.net.JarURLConnection;
   import java.net.URL;
  -import javax.servlet.ServletContext;
  -import javax.servlet.ServletException;
  -import javax.servlet.http.HttpServletRequest;
  -import javax.servlet.http.HttpServletResponse;
  +import javax.management.ObjectName;
  +import javax.management.MBeanServer;
   import org.apache.catalina.Container;
   import org.apache.catalina.Context;
   import org.apache.catalina.DefaultContext;
   import org.apache.catalina.Deployer;
  -import org.apache.catalina.Globals;
  -import org.apache.catalina.HttpRequest;
   import org.apache.catalina.Host;
  -import org.apache.catalina.Lifecycle;
   import org.apache.catalina.LifecycleException;
  -import org.apache.catalina.LifecycleListener;
  -import org.apache.catalina.Request;
  -import org.apache.catalina.Response;
   import org.apache.catalina.Valve;
   import org.apache.catalina.valves.ErrorDispatcherValve;
  +import org.apache.catalina.valves.ValveBase;
   
   
   /**
  @@ -160,7 +148,7 @@
        * The <code>Deployer</code> to whom we delegate application
        * deployment requests.
        */
  -    private Deployer deployer = new StandardHostDeployer(this);
  +    private Deployer deployer = null;
   
   
       /**
  @@ -176,7 +164,6 @@
       private String errorReportValveClass =
           "org.apache.catalina.valves.ErrorReportValve";
   
  -
       /**
        * The descriptive information string for this implementation.
        */
  @@ -336,7 +323,6 @@
           return (this.defaultContext);
       }
   
  -
       /**
        * Return the Java class name of the Context implementation class
        * for new web applications.
  @@ -665,14 +651,14 @@
        */
       public Context map(String uri) {
   
  -        if (debug > 0)
  -            log("Mapping request URI '" + uri + "'");
  +        if (log.isDebugEnabled())
  +            log.debug("Mapping request URI '" + uri + "'");
           if (uri == null)
               return (null);
   
           // Match on the longest possible context path prefix
  -        if (debug > 1)
  -            log("  Trying the longest context path prefix");
  +        if (log.isTraceEnabled())
  +            log.trace("  Trying the longest context path prefix");
           Context context = null;
           String mapuri = uri;
           while (true) {
  @@ -687,8 +673,8 @@
   
           // If no Context matches, select the default Context
           if (context == null) {
  -            if (debug > 1)
  -                log("  Trying the default context");
  +            if (log.isTraceEnabled())
  +                log.trace("  Trying the default context");
               context = (Context) findChild("");
           }
   
  @@ -699,8 +685,8 @@
           }
   
           // Return the mapped Context (if any)
  -        if (debug > 0)
  -            log(" Mapped to context '" + context.getPath() + "'");
  +        if (log.isDebugEnabled())
  +            log.debug(" Mapped to context '" + context.getPath() + "'");
           return (context);
   
       }
  @@ -822,7 +808,7 @@
        */
       public void install(String contextPath, URL war) throws IOException {
   
  -        deployer.install(contextPath, war);
  +        getDelegateDeployer().install(contextPath, war);
   
       }
   
  @@ -853,7 +839,7 @@
        */
       public synchronized void install(URL config, URL war) throws
IOException {
   
  -        deployer.install(config, war);
  +        getDelegateDeployer().install(config, war);
   
       }
   
  @@ -867,7 +853,7 @@
        */
       public Context findDeployedApp(String contextPath) {
   
  -        return (deployer.findDeployedApp(contextPath));
  +        return (getDelegateDeployer().findDeployedApp(contextPath));
   
       }
   
  @@ -879,7 +865,7 @@
        */
       public String[] findDeployedApps() {
   
  -        return (deployer.findDeployedApps());
  +        return (getDelegateDeployer().findDeployedApps());
   
       }
   
  @@ -902,7 +888,7 @@
        */
       public void remove(String contextPath) throws IOException {
   
  -        deployer.remove(contextPath);
  +        getDelegateDeployer().remove(contextPath);
   
       }
   
  @@ -927,7 +913,7 @@
        */
       public void remove(String contextPath, boolean undeploy) throws
IOException {
   
  -        deployer.remove(contextPath,undeploy);
  +        getDelegateDeployer().remove(contextPath,undeploy);
   
       }
   
  @@ -947,7 +933,7 @@
        */
       public void start(String contextPath) throws IOException {
   
  -        deployer.start(contextPath);
  +        getDelegateDeployer().start(contextPath);
   
       }
   
  @@ -967,7 +953,7 @@
        */
       public void stop(String contextPath) throws IOException {
   
  -        deployer.stop(contextPath);
  +        getDelegateDeployer().stop(contextPath);
   
       }
   
  @@ -987,5 +973,64 @@
   
       }
   
  +    private Deployer getDelegateDeployer() {
  +        if( deployer!= null )
  +            return deployer;
  +        deployer=new StandardHostDeployer(this);
  +        return deployer;
  +    }
  +
  +    // -------------------- JMX  --------------------
  +    /**
  +      * Return the MBean Names of the Valves assoicated with this Host
  +      *
  +      * @exception Exception if an MBean cannot be created or registered
  +      */
  +     public String [] getValveNames()
  +         throws Exception
  +    {
  +         Valve [] valves = this.getValves();
  +         String [] mbeanNames = new String[valves.length];
  +         for (int i = 0; i < valves.length; i++) {
  +             if( valves[i] == null ) continue;
  +             if( ((ValveBase)valves[i]).getObjectName() == null )
continue;
  +             mbeanNames[i] =
((ValveBase)valves[i]).getObjectName().toString();
  +         }
  +
  +         return mbeanNames;
  +
  +     }
  +
  +    public ObjectName[] getValveObjectNames()
  +        throws Exception
  +    {
  +        Valve [] valves = this.getValves();
  +        ObjectName [] mbeanNames = new ObjectName[valves.length];
  +        for (int i = 0; i < valves.length; i++) {
  +            mbeanNames[i] = ((ValveBase)valves[i]).getObjectName();
  +        }
   
  +        return mbeanNames;
  +    }
  +
  +    public String[] getAliases() {
  +        return aliases;
  +    }
  +
  +    public void init() throws Exception {
  +        if( getParent() != null ) return;
  +
  +        ObjectName serviceName=new ObjectName(domain +
  +                ":type=Engine,name=Tomcat-Standalone");
  +        if( mserver.isRegistered( serviceName )) {
  +            log.info("Registering with the Engine");
  +            try {
  +                mserver.invoke( serviceName, "addChild",
  +                        new Object[] { this },
  +                    new String[] { "org.apache.catalina.Container" } );
  +            } catch( Exception ex ) {
  +                ex.printStackTrace();
  +            }
  +        }
  +    }
   }
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to