Error on - Batch file execution for Lotus Notes Web Service

I’m trying to execute a batch file wsdl2java.bat for a lotus notes web service as follows :

C:\lotus\notes\jvm\bin>wsdl2java.bat

http://localhost/EPMTaskStatusUpdation.nsf/MyWebService?wsdl

But facing error as follows :

Using WSO2WSAS_HOME: C:\lotus\notes\jvm

Using JAVA_HOME: C:\lotus\notes\jvm\

The java class is not found: org/apache/axis2/wsdl/WSDL2Java

Can anyone help me in understanding and resolving it.

The content of the .bat file is as follows :

@echo off

rem ---------------------------------------------------------------------------

rem Startup script for the WSDLJava

rem

rem Environment Variable Prequisites

rem

rem WSO2WSAS_HOME Must point at your WSO2 WSAS directory

rem

rem JAVA_HOME Must point at your Java Development Kit installation.

rem

rem JAVA_OPTS (Optional) Java runtime options

rem ---------------------------------------------------------------------------

set CURRENT_DIR=%cd%

rem Make sure prerequisite environment variables are set

if not “%JAVA_HOME%” == “” goto gotJavaHome

echo The JAVA_HOME environment variable is not defined

echo This environment variable is needed to run this program

goto end

:gotJavaHome

if not exist “%JAVA_HOME%\bin\java.exe” goto noJavaHome

goto okJavaHome

:noJavaHome

echo The JAVA_HOME environment variable is not defined correctly

echo This environment variable is needed to run this program

echo NB: JAVA_HOME should point to a JDK/JRE

goto end

:okJavaHome

rem check the WSO2WSAS_HOME environment variable

if not “%WSO2WSAS_HOME%” == “” goto gotHome

set WSO2WSAS_HOME=%CURRENT_DIR%

if exist “%WSO2WSAS_HOME%\bin\WSDL2Java.bat” goto okHome

rem guess the home. Jump one directory up to check if that is the home

cd …

set WSO2WSAS_HOME=%cd%

cd %WSO2WSAS_HOME%

:gotHome

if exist “%WSO2WSAS_HOME%\bin\WSDL2Java.bat” goto okHome

rem set WSO2WSAS_HOME=%~dp0…

if exist “%WSO2WSAS_HOME%\bin\WSDL2Java.bat” goto okHome

echo The WSO2WSAS_HOME environment variable is not defined correctly

echo This environment variable is needed to run this program

goto end

:okHome

rem set the classes

setlocal EnableDelayedExpansion

rem loop through the libs and add them to the class path

cd “%WSO2WSAS_HOME%”

set WSO2WSAS_CLASSPATH=.\conf

FOR %%C in (“%WSO2WSAS_HOME%\lib*.jar”) DO set WSO2WSAS_CLASSPATH=!WSO2WSAS_CLASSPATH!;“.\lib%%~nC%%~xC”

rem ----- Execute The Requested Command ---------------------------------------

echo Using WSO2WSAS_HOME: %WSO2WSAS_HOME%

echo Using JAVA_HOME: %JAVA_HOME%

set _RUNJAVA=“%JAVA_HOME%\bin\java”

set WSO2WSAS_CLASSPATH=.\lib\patches;%WSO2WSAS_CLASSPATH%

set JAVA_ENDORSED=“.\lib\endorsed”;“%JAVA_HOME%\jre\lib\endorsed”;“%JAVA_HOME%\lib\endorsed”

%_RUNJAVA% %JAVA_OPTS% -cp “%WSO2WSAS_CLASSPATH%” -Djava.endorsed.dirs=%JAVA_ENDORSED% org.apache.axis2.wsdl.WSDL2Java %*

endlocal

:end

Subject: Error on - Batch file execution for Lotus Notes Web Service

The error you get is: “The java class is not found: org/apache/axis2/wsdl/WSDL2Java”

This means either that the mentioned class does not exists, or it cannot be found via the specified path(s).

Subject: RE: Error on - Batch file execution for Lotus Notes Web Service

  1. In which path the java class is being expected to be kept.Is it JAVA_HOME or any other as mentioned in the original problem.

  2. Among the related .jar file and the .java file which one is being searched here.