<-----Google Analytics Code Start----> <-----Google Analytics Code Close---->
Skip to content

Green

color

Default screen resolution  Wide screen resolution  Increase font size  Decrease font size  Default font size  Skip to content Default color Pink color Green color Green color
Home arrow Home arrow MWA Setup, Testing, Error Logging and Debugging
This website has now moved to http://apps2fusion.com





MWA Setup, Testing, Error Logging and Debugging | Print |  E-mail
Written by Senthilkumar Shanmugam   
Saturday, 09 February 2008
MWA Setup

This article will explain to you                                                            Image      
    a. Where the Mobile Web Apps config files are located
    b. MWA Startup and Shutdown Scripts and how those are used
    c. Directory Structure for MWA in both 11i and R12
    d. How to develop and test your pages
    e. Where the log files are created, and tips to debug MWA Applications


 

Configuration Files

  • mwa.cfg: This file has information about the DBC file location, Log Dir Location, Telnet Port no Location, Error Logging Level etc.
    This info will be used by Mobile Applications on runtime.

  • default_key.ini: This file is used to map the keys of the mobile device to some specific functionality.
    Use the default file if you don’t want to customize anything.

  • deviceIP.ini: This file maps the configuration files and host name with the mobile device



MWA server start-up and shutdown:

  • mwactl.sh: This file is used to start/stop the MWA listener on specific port.
    Basically, if you develop and deploy a Mobile page into the instance, you have to bounce the MWA server by
    stopping and starting the Listener at your port to see your changes.


Start/stopping Listener

Start:
mwactl.sh start <port no>


Stop :
mwactl.sh -login <userid/pwd> stop_force <port no>




File Location

Directory Structure in R11
$MWA_TOP/bin
$MWA_TOP/secure


Directory structure in R12
$INST_TOP/admin/scripts
$INST_TOP/admin/install



(eg)In R12, INST_TOP may look like:
/u01/appldev/DEV/inst/apps/DEV_w-oraap01


 

MWA GUI Client Setup

In order to simulate the Mobile Device on your PC, you have to do the following setup:

Step 1:
Create 2 directories say C:\MWA\lib and C:\MWA\log
Extract the files from the patch 4205328 into C:\MWA\lib


Step 2:
Download jdk1.1.8 from java.sun.com and place it in C:


Step 3:
Create a batch file say Start_MWA.bat with the following contents
set MWA_GUI_TOP=C:\MWA\
set JAVA_TOP=c:\jdk1.1.8

%JAVA_TOP%\bin\java -classpath %JAVA_TOP%\lib\classes.zip;%MWA_GUI_TOP%\lib\j4205328.zip oracle.apps.mwa.awt.client.StartGUI


Step 4:
Whenever you run this batch file, you must be able to see the GUI client for MWA



Development and Deployment:

The development of Mobile Applications can be done using any IDE like JDeveloper, Eclipse etc. After that in order to
test the application, we have to deploy it in the Apps instance say in a directory like $JAVA_TOP/xxx/custom/server.


In order to test it, we should have our own function in AOL. This function should refer to the Function Java Class
name of the Mobile Application

(eg) xxx.custom.server.CustomTestFunction

Image



After doing so, we have to attach this function to submenu and then to the Mobile Navigation Menu

Image


After doing so, your menu entry will come into your mobile application and you can test your new pages

Image


 

MWA Error Logging and Debugging:

When you develop and test mobile applications, you may need to write some logging information which will be useful in debugging.
There are different levels of Logging that can be set for obtaining more debug information.

The different Log level from highest to lowest is as follows:

    • fatal

    • error

    • warning

    • debug

    • trace


This logging information can be set using the “mwa.LogLevel” variable in mwa.cfg file.



How to write logging information?
While we code, we can call the APIs to log the information. The methods used for logging can be found in the following Java helper class.

oracle.apps.inv.utilities.server.UtilFns


For example, we can use the following code snippets and based on the log level set, we can find this information from the log files.

UtilFns.trace("#########Trace Level Logs#########");
UtilFns.log("#########Log level logs#########");
UtilFns.error("#####Error Level logs#########");


There are lot of other utility APIs available in this helper class (UtilFns.java) which can be used for various other aspects.


Example code snippet for error logging:

public void fieldEntered(MWAEvent mwaevent)

{

UtilFns.trace("Inside Field Entered");

ses = mwaevent.getSession();

String s = UtilFns.fieldEnterSource(ses);

// Prints the Current Bean's ID

UtilFns.trace("CustomFListener:fieldEntered:fldName = " + s);

}


In the above snippet, we print a message “Inside Field Entered” when the user enters any field in the Mobile Application

Also, we print the name of the field using the line

    UtilFns.trace("CustomFListener:fieldEntered:fldName = " + s);

Please note that, the above log messages can be found only when the log level is set to “trace” in mwa.cfg file.



Where to look for log information?

The log files are located under $INST_TOP/logs (in R12).



Mainly we will be using the following log files to see our log files.

All the log files start with Telnet_port_no as a prefix.


Example log files for port no 10240:

[appldev@w-oraap01 logs]$ pwd

/u01/appldev/DEV/inst/apps/DEV_w-oraap01/logs

[appldev@w-oraap01 logs]$ ls -al 10240*

-rw-r--r-- 1 appldev dba 255626 Feb 8 13:28 10240.INV.log

-rw-r--r-- 1 appldev dba 83 Feb 8 13:26 10240.sta

-rw-r--r-- 1 appldev dba 154063 Feb 8 13:50 10240.system.log

-rw-r--r-- 1 appldev dba 3296 Feb 4 11:11 10240.WMS.log

[appldev@w-oraap01 logs]$



All the log information written using the “UtilFns” will be located under <port_no>.INV.log

All the system level log like page names, parameter passed to PLSQL APIs, LOVs etc can be found under <port_no>.system.log



Easiest way to look at log files:

Since the volume of information written in the log file is huge, it is tough to go through the entire file.

A simpler way which I used to find the log information is to run the command

tail -f 10240.INV.log


By doing so, you can see the updated log information as and when you click on the fields on mobile application.

Image


Comments (12)add
FileSystemLogger
written by mmitraa , February 27, 2008
FileLogger.getSystemLogger().trace can also be used for tracing purpose....What is the basic difference between Utilfns.trace and FileLogger.getSystemLogger().trace. Pls explain...
Oracle Apps HRMS Functional
written by Raghava Chaitanya , February 27, 2008
Hi Anil
I am a recruiter
I am very much interested in Oracle Apps HRMS FUnctional Module
I did apps learning course from a private institute for Core HR and iRecruitment and OLM
I could get a relative idea on these modules. But when comming to realtime scenario I am feeling it very different
I want to be frank that I am planning to start entering into a consultant level as a fresher
but I dont have those opportunities
Atleast make me thorrow in Oracle Apps with any of the modules Focusing COre HR and Payroll
with real time examples
I have gone through your site and i appreciate that you share your knowledge with others too
And that made me dare to ask your help as I need it
please keep me updated posted to my email id for the first time atleast with a positive response
I will keep in touch
Thanks
Raghav
...
written by Raghava Chaitanya , February 27, 2008
RE: What is date tracking, how it is used in HRMS ?
--------------------------------------------------------------------------------

Hi,

Well date tracking isa feature in Oracle HRMS esp with all tables whose name send with _F eg:per_all_people_f .Now what happens here is we cannont purge a record what we can do is endate a record and if we need to create an extension eg: of an assignment then we end-date the assignment and on a new record that is appended to the table we create a new record with starting date after the eend date and can restate the assignment, used in cases of Re-hire after end of assignment or in the extension of assignment beyond the end date. It helps Oracle maintain historical data and hence the tables are data trackable

...
written by SenthilKumar , February 27, 2008
Hi mmitraa,

Thanks a lot for bringing this up.

oracle.apps.inv.utilities.server.UtilFns is a helper class which acts as a helper class for Mobile Application Utility APIs. It has Java wrappers for most of the common functionalities like LPN Generation, getting Lot Qty etc. What I mean here is has lot of other APIs apart from Error Logging

On the other hand,

java.lang.Object
|
--java.io.Writer
|
--java.io.PrintWriter
|
--oracle.apps.mwa.container.Logger
|
--oracle.apps.mwa.container.FileLogger

FileLogger is dedicated Class for Error Logging.

Am not sure about the place it writes the log messages.It would be great if you provide some information about this.This would definitely give an better idea between the two types of logging.

Thanks and Regards,
Senthil

FileLogger
written by mmitraa , February 28, 2008

Basically i don't have much knowledge what UtilFns does. Can you publish any doc related to this ? if you have any doc pls fwd it to me on my email id mmitraa@gmail.com

Where as FileLogger is concerned it will log the error messaged into port.system.log file. you can user methods like .trace/ .error etc
...
written by SenthilKumar , February 28, 2008
UtilFns writes log information on port.INV.log

I am in process of writing a documentation for this. I will publish this in near future.

Thanks and Regards,
Senthil
...
written by mmitraa , February 28, 2008
is there any other option needs to be setup other than setting log option to trace.....in mwa.cfg file. ???????

because i used UtilFns toooo but never seen it logging anything in INV.log file....
...
written by SenthilKumar , February 28, 2008
Have u restarted your telnet listener after editing the mwa.cfg file?
...
written by mmitraa , February 28, 2008
yes.....is there any other option that i need to set ? i'm in 11.5.10
...
written by mmitraa , February 28, 2008
another thing i wanted to know ....what are the possible values and meaning for MWA: Debug Level ?
...
written by SenthilKumar , February 28, 2008
No other setup is required. BTW, how about your port.system.log? Are you getting entries into that file?

Can you paste the various variables and their values in mwa.cfg file?

Regarding the profile options MWA: Debug Trace and MWA: Debug Level, I havent used them. May be they are reserved for future. If I get any useful info, I will update you.
Oracle Mobile Supply Chain Technical - Is anyone interested........
written by jabastion , March 14, 2008
Title: Oracle Mobile Supply Chain Technical
Location: FL
Duration: 3-6 months

Job description:
Our company is handling the global implementation of Oracle Applications for a multi-billion dollar European conglomerate. Their Application Systems are managed and we are in need for an Oracle Technical expert to assist in the Installation and Configuration of Oracle Mobile Supply Chain Applications.
This resource should be highly technical with extensive knowledge of the various server, labeling, printer, RF equipment, etc. Start date will be Mid-March and will continue for 3-6 months, possibly more. Some brief, occasional international travel, with expenses paid, may be required from time to time throughout the course of the project. Should be able to set up and configure both the software and the devices used.


Thanks and regards,
Jabastion
630 928 1800 X 509
You must be logged in to a comment. Please register if you do not have an account yet.

busy