12 Replies Latest reply: Dec 12, 2009 10:09 PM by Jay SenSharma MiddlewareMagic RSS

    URGENT*** Test Client testpoint not generated in WebLogic 10.3.0.0

    509360
      Hi,

      I have created very basic "Java EE 1.5 with support for jax-ws Annotations" web service and deploying in to web logic server 10.3.0.0. I am using Jdeveloper 11g for convert my java file to web service and deploying the same in to WLS directly from Jdev IDE.

      Problem is, I cant able to see "Test Client" testPoint in order to test my webservice. When I access my web service via WLS admin console can able to see only "?WSDL" test point at TESTING tab and WSDL is accessible. But Test client is not getting generated.

      Please help me, what am I missing here, why the WLServer not generating the test client. Am I missing any setting at server side. Please help me. Below is my web service code.


      package edu.ws;

      import javax.jws.WebService;

      *@WebService(serviceName = "demoWS", portName = "demoWSSoapHttpPort")*
      public class demoWS
      *{*
      public demoWS()
      *{*
      *}*

      public String fullName(String fn, String ln)
      *{*
      String fullName = fn + ln;
      return fullName;
      *}*
      *}*


      WSDL file:

      *<!--*
      Published by JAX-WS RI at http://jax-ws.dev.java.net. RI's version is Oracle JAX-WS 2.1.3-07/10/2008 08:41 PM(bt).
      -->

      *<!--*
      Generated by JAX-WS RI at http://jax-ws.dev.java.net. RI's version is Oracle JAX-WS 2.1.3-07/10/2008 08:41 PM(bt).
      -->

      *<definitions targetNamespace="http://ws.syu.edu/" name="demoWS">*

      *<types>*

      *<xsd:schema>*
      *<xsd:import namespace="http://ws.syu.edu/" schemaLocation="http://192.168.88.131:7001/DemoWebService-DemoWS-context-root/demoWSSoapHttpPort?xsd=1"/>*
      *</xsd:schema>*
      *</types>*

      *<message name="fullName">*
      *<part name="parameters" element="tns:fullName"/>*
      *</message>*

      *<message name="fullNameResponse">*
      *<part name="parameters" element="tns:fullNameResponse"/>*
      *</message>*

      *<portType name="demoWS">*

      *<operation name="fullName">*
      *<input message="tns:fullName"/>*
      *<output message="tns:fullNameResponse"/>*
      *</operation>*
      *</portType>*

      *<binding name="demoWSSoapHttpPortBinding" type="tns:demoWS">*
      *<soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/>*

      *<operation name="fullName">*
      *<soap:operation soapAction=""/>*

      *<input>*
      *<soap:body use="literal"/>*
      *</input>*

      *<output>*
      *<soap:body use="literal"/>*
      *</output>*
      *</operation>*
      *</binding>*

      *<service name="demoWS">*

      *<port name="demoWSSoapHttpPort" binding="tns:demoWSSoapHttpPortBinding">*
      *<soap:address location="http://192.168.88.131:7001/DemoWebService-DemoWS-context-root/demoWSSoapHttpPort"/>*
      *</port>*
      *</service>*
      *</definitions>*


      Thanks
      klogube
        • 1. Re: URGENT*** Test Client testpoint not generated in WebLogic 10.3.0.0
          Ravi Jegga
          Hi
          If you just want to test your wsdl (if not from weblogic console but from anywhere else), then you can try this:

          Start the domain where you have this WebService Deployed and make sure it is running and your webservice is deployed.

          Open a new browser and type this url: http://yourhost:yourport/wls_utc. This open a out of box utility page to test any WebService. In the top text field, enter the full WSDL for your webservice (http://host:port/..../../../xxx?wsdl) and click on Test button. It will list out all the Operations and Services from your WSDL. For each operation, it will dynamically generate the fields also to enter. And you can enter and hit a button named with your operation name.

          wls_utc is out of box servlet (that calls pageflow based code) to test any Web Service.

          Goud
          • 2. Re: URGENT*** Test Client testpoint not generated in WebLogic 10.3.0.0
            509360
            Hi Goud,

            thanks for the alternate way to test my WS. I can able to open only my WLS console not wls_cls.

            Cant able to open http://yourhost:yourport/wls_utc. Getting "Error 404--Not Found". Do I need to do any setting to access wls_utc?

            Thanks
            klogube
            • 3. Re: URGENT*** Test Client testpoint not generated in WebLogic 10.3.0.0
              Ravi Jegga
              Hi
              No, there is nothing to load or install. This wls_utc is out of box stuff and it does exist for 10.3 that I am currently using.

              Just curious, did you replace the word yourhost with actual your host like localhost and yourport word with actual port like 7001 etc.

              The URL Pattern is: http://host:port/wls_utc where host is where your weblogic domain is running and port is the port of this domain.
              EX: http://localhost:7001/wls_utc

              This should work, I am pretty confident.

              Goud
              • 4. Re: URGENT*** Test Client testpoint not generated in WebLogic 10.3.0.0
                509360
                Hi,

                yes i replaced all.. http://localhost:7001/wls_utc

                ofcourse http://localhost:7001/console is working fine but not http://localhost:7001/wls_utc. Getting Error 404. So I am confused what else I am missing.
                • 5. Re: URGENT*** Test Client testpoint not generated in WebLogic 10.3.0.0
                  509360
                  Actually I have another machine where I got WLS + OIM installed and Jdev 11g.

                  I could able to deploy same my web service to that WLS and could able to get the Test Client testpoint over there without any code change. But if I take the same WAR file and deploy in my current machine's WLS it is getting deployed but not showing the test Client testpoint. Only getting ?WSDL. Not sure what I am missing. I have compared both the WLS settings but cant able to identify.

                  thanks
                  klogube
                  • 6. Re: URGENT*** Test Client testpoint not generated in WebLogic 10.3.0.0
                    648859
                    klogube wrote:
                    Hi,

                    yes i replaced all.. http://localhost:7001/wls_utc

                    ofcourse http://localhost:7001/console is working fine but not http://localhost:7001/wls_utc. Getting Error 404. So I am confused what else I am missing.
                    Which mode your weblogic server instance config? IIRC, testclient only be enabled under development mode. So try switch to development mode and try again. In case you don't know how to config weblogic server mode, see this link.
                    • 7. Re: URGENT*** Test Client testpoint not generated in WebLogic 10.3.0.0
                      509360
                      Hi,

                      My WLS running at production mode. Now I set PRODUCTION_MODE = false and restarting the server. I guess now my WLS will restart with development mode and I may get test Client testpoint for my WS. Will confirm the same.

                      thanks
                      klogube
                      • 8. Re: URGENT*** Test Client testpoint not generated in WebLogic 10.3.0.0
                        509360
                        Hi LJ,

                        I did the same. I configured my WLS for development mode by making production_mode = false. But still I cant able to open http://localhost:7001/wls_utc window and so far cant able to test my WS :(


                        Please check my config file and let me know where else I suppose to make the production mode false!!



                        #!/bin/sh

                        # WARNING: This file is created by the Configuration Wizard.
                        # Any changes to this script may be lost when adding extensions to this configuration.

                        # --- Start Functions ---

                        BP=100
                        SP=$BP

                        pushd()
                        {
                             if [ -z "$1" ]
                             then
                                  return
                             fi

                             SP=`expr $SP - 1`
                             eval _stack$SP=`pwd`
                             cd $1
                             return
                        }

                        popd()
                        {
                             if [ $SP -eq $BP ]
                             then
                                  return
                             fi
                             eval cd \${_stack$SP}
                             SP=`expr $SP + 1`
                             return
                        }


                        # --- End Functions ---

                        # *************************************************************************
                        # This script is used to setup the needed environment to be able to start Weblogic Server in this domain.
                        #
                        # This script initializes the following variables before calling commEnv to set other variables:
                        #
                        # WL_HOME - The BEA home directory of your WebLogic installation.
                        # JAVA_VM - The desired Java VM to use. You can set this environment variable before calling
                        # this script to switch between Sun or BEA or just have the default be set.
                        # JAVA_HOME - Location of the version of Java used to start WebLogic
                        # Server. Depends directly on which JAVA_VM value is set by default or by the environment.
                        # USER_MEM_ARGS - The variable to override the standard memory arguments
                        # passed to java.
                        # PRODUCTION_MODE - The variable that determines whether Weblogic Server is started in production mode.
                        # DOMAIN_PRODUCTION_MODE
                        # - The variable that determines whether the workshop related settings like the debugger,
                        # testconsole or iterativedev should be enabled. ONLY settable using the
                        # command-line parameter named production
                        # NOTE: Specifying the production command-line param will force
                        # the server to start in production mode.
                        #
                        # Other variables used in this script include:
                        # SERVER_NAME - Name of the weblogic server.
                        # JAVA_OPTIONS - Java command-line options for running the server. (These
                        # will be tagged on to the end of the JAVA_VM and
                        # MEM_ARGS)
                        #
                        # For additional information, refer to the WebLogic Server Administration
                        # Console Online Help(http://e-docs.bea.com/wls/docs103/ConsoleHelp/startstop.html).
                        # *************************************************************************

                        ORACLE_HOME="/opt/oracle/middleware/jdeveloper"
                        export ORACLE_HOME


                        WL_HOME="/opt/oracle/middleware/wlserver_10.3"
                        export WL_HOME

                        BEA_JAVA_HOME="/opt/oracle/middleware/jrockit_160_05"
                        export BEA_JAVA_HOME

                        SUN_JAVA_HOME=""
                        export SUN_JAVA_HOME

                        if [ "${JAVA_VENDOR}" = "BEA" ] ; then
                             JAVA_HOME="${BEA_JAVA_HOME}"
                             export JAVA_HOME
                        else
                             if [ "${JAVA_VENDOR}" = "Sun" ] ; then
                                  JAVA_HOME="${SUN_JAVA_HOME}"
                                  export JAVA_HOME
                             else
                                  JAVA_VENDOR="BEA"
                                  export JAVA_VENDOR
                                  JAVA_HOME="/opt/oracle/middleware/jrockit_160_05"
                                  export JAVA_HOME
                             fi
                        fi

                        # We need to reset the value of JAVA_HOME to get it shortened AND
                        # we can not shorten it above because immediate variable expansion will blank it

                        JAVA_HOME="${JAVA_HOME}"
                        export JAVA_HOME

                        SAMPLES_HOME="${WL_HOME}/samples"
                        export SAMPLES_HOME

                        DOMAIN_HOME="/opt/oracle/middleware/user_projects/domains/base_domain"
                        export DOMAIN_HOME

                        LONG_DOMAIN_HOME="/opt/oracle/middleware/user_projects/domains/base_domain"
                        export LONG_DOMAIN_HOME

                        if [ "${DEBUG_PORT}" = "" ] ; then
                             DEBUG_PORT="8453"
                             export DEBUG_PORT
                        fi

                        if [ "${SERVER_NAME}" = "" ] ; then
                             SERVER_NAME="AdminServer"
                             export SERVER_NAME
                        fi

                        POINTBASE_FLAG="false"
                        export POINTBASE_FLAG

                        enableHotswapFlag=""
                        export enableHotswapFlag

                        PRODUCTION_MODE="false"
                        export PRODUCTION_MODE

                        doExitFlag="false"
                        export doExitFlag
                        verboseLoggingFlag="false"
                        export verboseLoggingFlag
                        while [ $# -gt 0 ]
                        do
                             case $1 in
                             nodebug)
                                  debugFlag="false"
                                  export debugFlag
                                  ;;
                             production)
                                  DOMAIN_PRODUCTION_MODE="true"
                                  export DOMAIN_PRODUCTION_MODE
                                  ;;
                             notestconsole)
                                  testConsoleFlag="false"
                                  export testConsoleFlag
                                  ;;
                             noiterativedev)
                                  iterativeDevFlag="false"
                                  export iterativeDevFlag
                                  ;;
                             noLogErrorsToConsole)
                                  logErrorsToConsoleFlag="false"
                                  export logErrorsToConsoleFlag
                                  ;;
                             nopointbase)
                                  POINTBASE_FLAG="false"
                                  export POINTBASE_FLAG
                                  ;;
                             doExit)
                                  doExitFlag="true"
                                  export doExitFlag
                                  ;;
                             noExit)
                                  doExitFlag="false"
                                  export doExitFlag
                                  ;;
                             verbose)
                                  verboseLoggingFlag="true"
                                  export verboseLoggingFlag
                                  ;;
                             enableHotswap)
                                  enableHotswapFlag="-javaagent:${WL_HOME}/server/lib/diagnostics-agent.jar"
                                  export enableHotswapFlag
                                  ;;
                             *)
                                  PROXY_SETTINGS="${PROXY_SETTINGS} $1"
                                  export PROXY_SETTINGS
                                  ;;
                             esac
                             shift
                        done


                        MEM_DEV_ARGS=""
                        export MEM_DEV_ARGS

                        if [ "${DOMAIN_PRODUCTION_MODE}" = "true" ] ; then
                             PRODUCTION_MODE="${DOMAIN_PRODUCTION_MODE}"
                             export PRODUCTION_MODE
                        fi

                        if [ "${PRODUCTION_MODE}" = "true" ] ; then
                             debugFlag="false"
                             export debugFlag
                             testConsoleFlag="false"
                             export testConsoleFlag
                             iterativeDevFlag="false"
                             export iterativeDevFlag
                        fi

                        # If you want to override the default Patch Classpath, Library Path and Path for this domain,
                        # Please uncomment the following lines and add a valid value for the environment variables
                        # set PATCH_CLASSPATH=[myPatchClasspath] (windows)
                        # set PATCH_LIBPATH=[myPatchLibpath] (windows)
                        # set PATCH_PATH=[myPatchPath] (windows)
                        # PATCH_CLASSPATH=[myPatchClasspath] (unix)
                        # PATCH_LIBPATH=[myPatchLibpath] (unix)
                        # PATCH_PATH=[myPatchPath] (unix)

                        . ${WL_HOME}/common/bin/commEnv.sh

                        WLS_HOME="${WL_HOME}/server"
                        export WLS_HOME

                        MEM_ARGS="-Xms256m -Xmx512m"
                        export MEM_ARGS

                        MEM_PERM_SIZE="-XX:PermSize=48m"
                        export MEM_PERM_SIZE

                        MEM_MAX_PERM_SIZE="-XX:MaxPermSize=192m"
                        export MEM_MAX_PERM_SIZE

                        if [ "${JAVA_VENDOR}" = "Sun" ] ; then
                             if [ "${PRODUCTION_MODE}" = "" ] ; then
                                  MEM_DEV_ARGS="-XX:CompileThreshold=8000 ${MEM_PERM_SIZE} "
                                  export MEM_DEV_ARGS
                             fi
                        fi

                        # Had to have a separate test here BECAUSE of immediate variable expansion on windows

                        if [ "${JAVA_VENDOR}" = "Sun" ] ; then
                             MEM_ARGS="${MEM_ARGS} ${MEM_DEV_ARGS} ${MEM_MAX_PERM_SIZE}"
                             export MEM_ARGS
                        fi

                        if [ "${JAVA_VENDOR}" = "HP" ] ; then
                             MEM_ARGS="${MEM_ARGS} ${MEM_MAX_PERM_SIZE}"
                             export MEM_ARGS
                        fi

                        # IF USER_MEM_ARGS the environment variable is set, use it to override ALL MEM_ARGS values

                        if [ "${USER_MEM_ARGS}" != "" ] ; then
                             MEM_ARGS="${USER_MEM_ARGS}"
                             export MEM_ARGS
                        fi

                        JAVA_PROPERTIES="-Dplatform.home=${WL_HOME} -Dwls.home=${WLS_HOME} -Dweblogic.home=${WLS_HOME} "
                        export JAVA_PROPERTIES

                        # To use Java Authorization Contract for Containers (JACC) in this domain,
                        # please uncomment the following section. If there are multiple machines in
                        # your domain, be sure to edit the setDomainEnv in the associated domain on
                        # each machine.
                        #
                        # -Djava.security.manager
                        # -Djava.security.policy=location of weblogic.policy
                        # -Djavax.security.jacc.policy.provider=weblogic.security.jacc.simpleprovider.SimpleJACCPolicy
                        # -Djavax.security.jacc.PolicyConfigurationFactory.provider=weblogic.security.jacc.simpleprovider.PolicyConfigurationFactoryImpl
                        # -Dweblogic.security.jacc.RoleMapperFactory.provider=weblogic.security.jacc.simpleprovider.RoleMapperFactoryImpl

                        EXTRA_JAVA_PROPERTIES="-Ddomain.home=${DOMAIN_HOME} -Doracle.home=${ORACLE_HOME} -Doracle.security.jps.config=${DOMAIN_HOME}/config/oracle/jps-config.xml -Doracle.dms.context=OFF -Djava.protocol.handler.pkgs=oracle.mds.net.protocol ${EXTRA_JAVA_PROPERTIES}"
                        export EXTRA_JAVA_PROPERTIES

                        JAVA_PROPERTIES="${JAVA_PROPERTIES} ${EXTRA_JAVA_PROPERTIES}"
                        export JAVA_PROPERTIES

                        ARDIR="${WL_HOME}/server/lib"
                        export ARDIR

                        pushd ${LONG_DOMAIN_HOME}

                        # Clustering support (edit for your cluster!)

                        if [ "${ADMIN_URL}" = "" ] ; then
                             # The then part of this block is telling us we are either starting an admin server OR we are non-clustered
                             CLUSTER_PROPERTIES="-Dweblogic.management.discover=true"
                             export CLUSTER_PROPERTIES
                        else
                             CLUSTER_PROPERTIES="-Dweblogic.management.discover=false -Dweblogic.management.server=${ADMIN_URL}"
                             export CLUSTER_PROPERTIES
                        fi

                        if [ "${LOG4J_CONFIG_FILE}" != "" ] ; then
                             JAVA_PROPERTIES="${JAVA_PROPERTIES} -Dlog4j.configuration=file:${LOG4J_CONFIG_FILE}"
                             export JAVA_PROPERTIES
                        fi

                        JAVA_PROPERTIES="${JAVA_PROPERTIES} ${CLUSTER_PROPERTIES}"
                        export JAVA_PROPERTIES

                        # Clear the pre_classpath here in case an application template wants to set it before the larger pre_classpath is invoked below

                        PRE_CLASSPATH=""
                        export PRE_CLASSPATH

                        JAVA_DEBUG=""
                        export JAVA_DEBUG

                        if [ "${debugFlag}" = "true" ] ; then
                             JAVA_DEBUG="-Xdebug -Xnoagent -Xrunjdwp:transport=dt_socket,address=${DEBUG_PORT},server=y,suspend=n -Djava.compiler=NONE"
                             export JAVA_DEBUG
                             JAVA_OPTIONS="${JAVA_OPTIONS} ${enableHotswapFlag} -ea -da:com.bea... -da:javelin... -da:weblogic... -ea:com.bea.wli... -ea:com.bea.broker... -ea:com.bea.sbconsole..."
                             export JAVA_OPTIONS
                        else
                             JAVA_OPTIONS="${JAVA_OPTIONS} ${enableHotswapFlag} -da"
                             export JAVA_OPTIONS
                        fi

                        if [ ! -d ${JAVA_HOME}/lib ] ; then
                             echo "The JRE was not found in directory ${JAVA_HOME}. (JAVA_HOME)"
                             echo "Please edit your environment and set the JAVA_HOME"
                             echo "variable to point to the root directory of your Java installation."
                             popd
                             read _val
                             exit
                        fi

                        if [ "${POINTBASE_FLAG}" = "true" ] ; then
                             DATABASE_CLASSPATH="${POINTBASE_CLASSPATH}"
                             export DATABASE_CLASSPATH
                        else
                             DATABASE_CLASSPATH="${POINTBASE_CLIENT_CLASSPATH}"
                             export DATABASE_CLASSPATH
                        fi

                        POST_CLASSPATH=""
                        export POST_CLASSPATH

                        POST_CLASSPATH="${ORACLE_HOME}/modules/features/adf.share_11.1.1.jar${CLASSPATHSEP}${POST_CLASSPATH}"
                        export POST_CLASSPATH

                        POST_CLASSPATH="${POST_CLASSPATH}${CLASSPATHSEP}${DATABASE_CLASSPATH}${CLASSPATHSEP}${ARDIR}/xqrl.jar"
                        export POST_CLASSPATH

                        # PROFILING SUPPORT

                        JAVA_PROFILE=""
                        export JAVA_PROFILE

                        SERVER_CLASS="weblogic.Server"
                        export SERVER_CLASS

                        JAVA_PROPERTIES="${JAVA_PROPERTIES} ${WLP_JAVA_PROPERTIES}"
                        export JAVA_PROPERTIES

                        JAVA_OPTIONS="${JAVA_OPTIONS} ${JAVA_PROPERTIES} -Dwlw.iterativeDev=${iterativeDevFlag} -Dwlw.testConsole=${testConsoleFlag} -Dwlw.logErrorsToConsole=${logErrorsToConsoleFlag}"
                        export JAVA_OPTIONS

                        # -- Setup properties so that we can save stdout and stderr to files

                        if [ "${WLS_STDOUT_LOG}" != "" ] ; then
                             echo "Logging WLS stdout to ${WLS_STDOUT_LOG}"
                             JAVA_OPTIONS="${JAVA_OPTIONS} -Dweblogic.Stdout=${WLS_STDOUT_LOG}"
                             export JAVA_OPTIONS
                        fi

                        if [ "${WLS_STDERR_LOG}" != "" ] ; then
                             echo "Logging WLS stderr to ${WLS_STDERR_LOG}"
                             JAVA_OPTIONS="${JAVA_OPTIONS} -Dweblogic.Stderr=${WLS_STDERR_LOG}"
                             export JAVA_OPTIONS
                        fi

                        # ADD EXTENSIONS TO CLASSPATHS

                        if [ "${EXT_PRE_CLASSPATH}" != "" ] ; then
                             PRE_CLASSPATH="${EXT_PRE_CLASSPATH}${CLASSPATHSEP}${PRE_CLASSPATH}"
                             export PRE_CLASSPATH
                        fi

                        if [ "${EXT_POST_CLASSPATH}" != "" ] ; then
                             POST_CLASSPATH="${POST_CLASSPATH}${CLASSPATHSEP}${EXT_POST_CLASSPATH}"
                             export POST_CLASSPATH
                        fi

                        if [ "${WEBLOGIC_EXTENSION_DIRS}" != "" ] ; then
                             JAVA_OPTIONS="${JAVA_OPTIONS} -Dweblogic.ext.dirs=${WEBLOGIC_EXTENSION_DIRS}"
                             export JAVA_OPTIONS
                        fi

                        JAVA_OPTIONS="${JAVA_OPTIONS}"
                        export JAVA_OPTIONS

                        # SET THE CLASSPATH

                        CLASSPATH="${PRE_CLASSPATH}${CLASSPATHSEP}${WEBLOGIC_CLASSPATH}${CLASSPATHSEP}${POST_CLASSPATH}${CLASSPATHSEP}${WLP_POST_CLASSPATH}"
                        export CLASSPATH

                        JAVA_VM="${JAVA_VM} ${JAVA_DEBUG} ${JAVA_PROFILE}"
                        export JAVA_VM

                        Edited by: klogube on Oct 23, 2009 10:58 AM
                        • 9. Re: URGENT*** Test Client testpoint not generated in WebLogic 10.3.0.0
                          509360
                          Goud,

                          I tired that too.. but no luck!!! :( ..

                          not getting how to open wls_utc and where to configure for that
                          • 10. Re: URGENT*** Test Client testpoint not generated in WebLogic 10.3.0.0
                            user12030933
                            I found that the webservice test client is auto deployed in the admin server when weblogic is in (Development Mode)
                            If you change to Production Mode, the test client will not be deployed.

                            Workaround:
                            1. create a new domain in (development mode)
                            2. search for webapp.war (this is the test client war file)
                            3. deploy the webapp.war to the production mode server manually.
                            4. the default context will change to http://server:port/webapp/

                            Hope can help!
                            • 11. Re: URGENT*** Test Client testpoint not generated in WebLogic 10.3.0.0
                              Betino
                              Great user12030933, that works.
                              • 12. Re: URGENT*** Test Client testpoint not generated in WebLogic 10.3.0.0
                                Jay SenSharma MiddlewareMagic
                                Hi,

                                Still if you are facing any issue while opening http://localhost:7001/wls_utc
                                then Just deploy the "*wlstestclient.ear*" in your WebLogic server First... This is a TestClient provided by WLS to test our WebServices:
                                The EAR Location is :

                                "C:\bea103\wlserver_10.3\server\lib\wlstestclient.ear"

                                This Technique we use Specially in case of Clustered and Production Env.


                                Thanks
                                Jay SenSharma

                                http://jaysensharma.wordpress.com
                                -----------------------