JNI Callback from remote process

I have an application that calls back from C to Java in multiple situations. In some, I have been successful using the technique of calling AttachCurrentThread as described, for example, in various places, e.g.,
http://java.sun.com/developer/onlineTraining/Programming/JDCBook/jniref.html#invoke
and recently in this forum
http://forum.java.sun.com/thread.jspa?threadID=763205&tstart=45`
This is an accessibility application and one of the situations I need to callback from is a global keyboard hook. In this context, I call from Java to a C DLL which sets up the keyboard hook using the standard Windows procedure SetWindowsHookEx.
      SetWindowsHookEx(    
                  WH_KEYBOARD,    // type of hook to install
                 (HOOKPROC) mykeyboardProc,    // address of hook procedure
                ( HINSTANCE__* )hDll,    // handle of application instance
                0     // identity of thread to install hook for  (all threds)      );The keyboard hook functions in Windows by being "injected" into running applications so that it runs in their process space and therein, apparently, lies the problem.
The keyboard hook gets callbacks from Windows whenever a key is pressed. This is the information I want to learn about back in Java. Our current approach is to have the keyboard hook write the key data to shared memory. Then the Java application makes polling calls into the previously mentioned C DLL which checks the shared memory and returns anything it finds. The C DLL is compiled with the current MinGW compiler.
This procedure works alright-- I can access the information using shared memory in C and polling that from Java. It is, however, a tad slow. I'd like to use a callback from C directly to eliminate the extra layer of polling. I could, of course, do the polling in the C DLL and call back to Java from there. That would eliminate a process switch every time we poll, but would still leave the polling.
In my attempts to set up a direct callback from the keyboard hook to Java, the C code uses AttachCurrentThread using the env pointer obtained from the JNI_OnLoad method. When my application has the focus and I type, I get print statements from the C DLL and the callbacks work fine. When any other application has focus, the callback does not work and there are no print statements. In fact, the keyboard hook crashes and stops responding to any key events.
Since I do not get print statements when another application has focus (or they go into the ether), I do not know directly whether the JNI_OnLoad function actually gets called each time the DLL is loaded into another application. However, the JVM pointer I cache in the JNI_OnLoad function is NULL when I get a key event callback (when another application has focus). I tested this by putting an "exit" call if the cached JVM was NULL in the keyboard procedure (mykeyboardProc above). When any application has focus and I type a key, that application exits. From this I assume that JNI_OnLoad is not getting called, but since the cached JVM is NULL, that is irrelevant.
One option I have attempted is to use JNI_GetCreatedJavaVMs to get a list of the JVMs running on the machine. From this, I hoped to somehow deduce which JVM was running my application and use its pointer. However, despite putting some of the the directories` with the jvm.dll into my library path:
   g++ -I/c/Programs/Java/JDK15~1.0_0/include
       -I/c/Programs/Java/JDK15~1.0_0/include/win32
       -L/c/Programs/Java/JDK15~1.0_0/jre/bin \
       ....I get the error:
undefined reference to `JNI_GetCreatedJavaVMs@12'
I would be grateful for any suggestions or solutions.
Rick

Thanks for the reply Jim,
I've been compiling in the Msys environment.
I created the jvm.def and generated the jvm.a as you
suggested.
This apparently required copying the jvm.dll from
/c/Programs/Java/JDK15~1.0_0/jre/bin/client
de]
to my working directory.  Before I did that I got a
message
about stripping the path components from the dll
name.
Then I tried to make the DLL in the fashion I had
been:g++ -I/c/Programs/Java/JDK15~1.0_0/include \
-I/c/Programs/Java/JDK15~1.0_0/include/win32 \
L/c/Programs/Java/JDK15~1.0_0/jre/bin/client \
-shared -o JKeyboardInterface.dll \     
jvm.a \
JKeyboardInterface_wrapper.cpp \
JKeyboardDllMain.cpp \
JKeyboardInterface.cpp \
-Wl,--out-implib,libJKeyboardInterface.a \
     -Wl,--add-stdcall-alias -mno-cygwin \
-fno-rtti -fno-exceptions -s
This resulted in this error:
Creating library file: libJKeyboardInterface.a
K:/DOCUME~1/rick/LOCALS~1/Temp/ccU1daaa.o:JKeyboardInt
erface.cpp:(.text+0xafb):
undefined reference to
`_imp__JNI_GetCreatedJavaVMs@12'
collect2: ld returned 1 exit status
Hmmmmm. What happens if you remove the '-Wl,--out-implib,libJKeyboardInterface.a'? It seems to be failing in the step creating the static lib, which may prevent the DLL from being properly created.
Since this was a different undefined reference, I
re-did the jmv.def step
using imp_JNI_GetCreatedJavaVMs@12 instead of
JNI_GetCreatedJavaVMs@12
This generated the same error.Yeah. I'm sure I never had to do anything like that.
>
Then I tried to use dllwrap with both versions of the
jvm.a generated above::
dllwrap --driver-name=c++ \
--add-stdcall-alias \
-o JKeyboardInterface.dll \
       jvm.a \
       JKeyboardInterface_wrapper.cpp \
       JKeyboardDllMain.cpp \
       JKeyboardInterface.cpp \With both versions of the jvm.a, I got the error:
K:/DOCUME~1/rick/LOCALS~1/Temp/ccSccaaa.o:JKeyboardInt
erface.cpp:(.text+0xafb):
undefined reference to `JNI_GetCreatedJavaVMs@12'
ollect2: ld returned 1 exit statusI'm not clear why the two approaches (g++ -shared and
dllwrap) yield different reference problems.
I've read that dllwrap is "deprecated" Probably.
(http://www.mingw.org/MinGWiki/index.php/dllwrap).
Do you have any other suggestions about how to do
this?Have a look at:
http://www.inonit.com/cygwin/
Msys (which is Mingw) follows cygwin pretty closely.
I'm not near a Windows machine to try this at the moment. All I can say is that I have an application using CreateJavaVM, compiled with MSYS and it works. CreateJavaVM has the same problems as GetCreatedJavaVMs that you are seeing. The root cause is that the jvm.lib shipped with the JDK for Windows is not compatible with GCC. Hence the need to create the jvm.a library.
I build my code using an ANT script. It build the objects first and then links them. Deciphering the build script, it looks like the two steps would have the following command line syntax:
Compile to object files:
gcc -D REENTRANT -I <paths to include> somefiles.cpp somefiles.c
(I have a mix of C and C++)
Link object files to create DLL:
gcc -shared -D REENTRANT --kill-at -lstdc++ somefiles.o jvm.a
Try it in two steps and see if it makes a difference.
>
Is trying to use GetCreatedJavaVMs the correct
approach here?
If more than one exists, how do I determine which one
I want to attach to and get an env pointer for?From you original post, it is difficult to understand exactly what you are trying to achieve.
It seems like you are starting with a Java app that calls into some native code to create the keyboard hook. This hook will then call a callback method in native code when a key is pressed. You want the Java code to see this and act appropriately.
In Java callbacks are usually handled with events. Just have your native code fire an event in Java and have a Listener on the Java side. I do this in some of my code. Say I have an event called FooEvent and a listener called FooListener. There is also an object called Bar which can fire FooEvents and have FooListeners attached to it. The Bar class has an addFooListener() method which is actually a native method. The native implementation sets up the callback stuff on the native side. When an event occurs on the native side, the callback function is called and it does something like this:
jclass cls;
jmethodID mid;
cls = env->GetObjectClass(javaSource);
mid = env->GetMethodID(cls, "fireSomeEvent", "()V");
env->CallVoidMethod(javaSource, mid);In the code above, the 'cls' variable would be the Bar class object and the 'javaSource' variable is a global reference ot the Bar object to which the event listener was added. The 'env' variable is acquired by calling 'AttachCurrentThread' on a cached JavaVM pointer stored in a global reference.
The Bar class has a fireSomeEvent() method, which calls the event listeners using the event generator idiom:
http://www.javaworld.com/javaworld/jw-09-1998/jw-09-techniques.html
The listener on the Java side gets notification when the event occurs and you can take the appropriate action. No polling, no shared memory.
Jim S.

Similar Messages

  • Error implementing dynamic callback from BPEL process

    Hi,
    I am trying to use dynamic callback from a BPEL process..
    Created a variable of type EndpointReference by importing the ws-addressing.xsd. in the partnerlink wsdl..
    I assigned the URL to the variable's address field ...
    <copy>
    <from expression="'http://172.31.171.123:8888/PubSubWLPOC-CallbackSvc2-context-root/EIPWFServiceCallbackPort'"/>
    <to variable="ep_var" query="/ns3:EndpointReference/ns3:Address"/>
    </copy>
    Gives no error till now...
    But when I try to assign the same variable to the partnerlink, I get an error..
    <assign name="Assign_7">
    <copy>
    <from variable="ep_var"/>
    <to partnerLink="MyWebService1"/>
    </copy>
    </assign>
    The error is like this(from the $SOA_HOME\bpel\domains\default\logs) :-
    java.lang.NullPointerException
    at com.collaxa.cube.engine.types.bpel.CXPartnerLink.copy(CXPartnerLink.java:246)
    at com.collaxa.cube.engine.ext.wmp.BPELAssignWMP.performCopyTo(BPELAssignWMP.java:1151)
    at com.collaxa.cube.engine.ext.wmp.BPELAssignWMP.__executeStatements(BPELAssignWMP.java:215)
    at com.collaxa.cube.engine.ext.wmp.BPELActivityWMP.perform(BPELActivityWMP.java:199)
    at com.collaxa.cube.engine.CubeEngine.performActivity(CubeEngine.java:3698)
    at com.collaxa.cube.engine.CubeEngine.handleWorkItem(CubeEngine.java:1655)
    at com.collaxa.cube.engine.dispatch.message.instance.PerformMessageHandler.handleLocal(PerformMessageHandler.java:75)
    at com.collaxa.cube.engine.dispatch.DispatchHelper.handleLocalMessage(DispatchHelper.java:217)
    at com.collaxa.cube.engine.dispatch.DispatchHelper.sendMemory(DispatchHelper.java:314)
    at com.collaxa.cube.engine.CubeEngine.endRequest(CubeEngine.java:5765)
    at com.collaxa.cube.engine.CubeEngine.callbackPerformer(CubeEngine.java:1885)
    at com.collaxa.cube.engine.delivery.DeliveryHelper.callbackPerformer(DeliveryHelper.java:845)
    at com.collaxa.cube.engine.delivery.DeliveryService.handleCallback(DeliveryService.java:794)
    at com.collaxa.cube.engine.ejb.impl.CubeDeliveryBean.handleCallback(CubeDeliveryBean.java:378)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    The confusing part is when I use xml fragment instead of the variable ep_var, it works fine ...
    But I cannot use the same as the callback can be made to any url(which is decided on runtime)
    Can someone pls help me with this ?
    saptarishi

    Hi,
    I have done following for dynamic call back and it works..
    <copy>
    <from>
    <_EndpointReference xmlns="http://schemas.xmlsoap.org/ws/2003/03/addressing">
    <Address/>
    </EndpointReference>
    </from>
    <to variable="EndpointUrl"/>
    </copy>
    <copy>
    In the above assignment from part is an xml fragment assigned to Endpoint Url
    <copy>
    <from expression="'http://172.31.171.123:8888/PubSubWLPOC-CallbackSvc2-context-root/EIPWFServiceCallbackPort'"/>
    <to variable="ep_var" query="/ns3:EndpointReference/ns3:Address"/>
    </copy>
    </copy>
    <copy>
    <from variable="EndpointUrl"/>
    <to partnerLink="SFDC_plt"/>
    </copy>

  • How can I put an output stream (HTML) from a remote process on my JSF page

    Hello,
    I've a question if someone could help.
    I have a jsf application that need to execute some remote stuff on a different process (it is a SAS application). This remote process produces in output an html table that I want to display in my jsf page.
    So I use a socket SAS class for setting up a server socket in a separate thread. The primary use of this class is to setup a socket listener, submit a command to a remote process (such as SAS) to generate a data stream (such as HTML or graphics) back to the listening socket, and then write the contents of the stream back to the servlet stream.
    Now the problem is that I loose my jsf page at all. I need a suggestion if some one would help, to understand how can I use this html datastream without writing on my Servlet output stream.
    Thank you in advance
    A.
    Just if you want to look at the details .....
    // Create the remote model
    com.sas.sasserver.submit.SubmitInterface si =
    (com.sas.sasserver.submit.SubmitInterface)
    rocf.newInstance(com.sas.sasserver.submit.SubmitInterface.class, connection);
    // Create a work dataset
    String stmt = "data work.foo;input field1 $ field2 $;cards;\na b\nc d\n;run;";
    si.setProgramText(stmt);
    // Setup our socket listener and get the port that it is bound to
    com.sas.servlet.util.SocketListener socket =
    new com.sas.servlet.util.SocketListener();
    int port = socket.setup();
    socket.start();
    // Get the localhost name
    String localhost = (java.net.InetAddress.getLocalHost()).getHostAddress();
    stmt = "filename sock SOCKET '" + localhost + ":" + port + "';";
    si.setProgramText(stmt);
    // Setup the ods options
    stmt = "ods html body=sock style=brick;";
    si.setProgramText(stmt);
    // Print the dataset
    stmt = "proc print data=work.foo;run;";
    si.setProgramText(stmt);
    // Close
    stmt = "ods html close;run;";
    si.setProgramText(stmt);
    // get my output stream
    context = FacesContext.getCurrentInstance();
    HttpServletResponse response = (HttpServletResponse) context.getExternalContext().getResponse();
    ServletOutputStream out = response.getOutputStream();
    // Write the data from the socket to the response
    socket.write(out);
    // Close the socket listener
    socket.close();

    The system exec function is on the Communication palette. Its for executing system commands. On my Win2K system, the help for FTP is:
    "Ftp
    Transfers files to and from a computer running an FTP server service (sometimes called a daemon). Ftp can be used interactively. Click ftp commands in the Related Topics list for a description of available ftp subcommands. This command is available only if the TCP/IP protocol has been installed. Ftp is a service, that, once started, creates a sub-environment in which you can use ftp commands, and from which you can return to the Windows 2000 command prompt by typing the quit subcommand. When the ftp sub-environment is running, it is indicated by the ftp command prompt.
    ftp [-v] [-n] [-i] [-d] [-g]
    [-s:filename] [-a] [-w:windowsize] [computer]
    Parameters
    -v
    Suppresses display of remote server responses.
    -n
    Suppresses autologin upon initial connection.
    -i
    Turns off interactive prompting during multiple file transfers.
    -d
    Enables debugging, displaying all ftp commands passed between the client and server.
    -g
    Disables file name globbing, which permits the use of wildcard characters (* and ?) in local file and path names. (See the glob command in the online Command Reference.)
    -s:filename
    Specifies a text file containing ftp commands; the commands automatically run after ftp starts. No spaces are allowed in this parameter. Use this switch instead of redirection (>).
    -a
    Use any local interface when binding data connection.
    -w:windowsize
    Overrides the default transfer buffer size of 4096.
    computer
    Specifies the computer name or IP address of the remote computer to connect to. The computer, if specified, must be the last paramete
    r on the line."
    I use tftp all of the time to transfer files in a similar manner. Test the transfer from the Windows command line and copy it into a VI. Pass the command line to system exec and wait until it's done.

  • Source System Conversion in Remote Process Chain

    Hi all!
    I' working with BI7 SP12 and facing the following problem:
    <b>There is no source system conversion for Remote Process Chains, when transporting Process Chains with Remote Process Chains from DEV to QA.</b>
    First the following warning appears:
    DEV-Destination of Remote Process Chain does not exist on QA-System.
    ==> The is correct because the DEV-Destination should have been converted to QA-Destination.
    Then the following error appears:
    Process Chain with the Remote Process Chain was not succesfully checked.
    <b>All source system conversion tables are maintained correctly!</b>
    The source system conversion works for example for InfoPackages correctly.
    But for Remote Process Chain there is neither source system conversion for the Destination nor for Callback Destination. Both should be converted.
    Do I have to do it manually??
    Or do I have to create the DEV-Destination in SM59 on the QA-System??
    ==> We want to avoid this...
    Thanks for any ideas...
    kj

    Please note:
    When I create the DEV-Destination in SM59 on the QA-System,
    the transport gets no warnings and no errors...
    But there is still no conversion of the source systems for the Destination and the Callback Destination of the Remote Process Chain to QA-Destinations...
    So, i think:
    There is no automatic source system conversion of Remote Process Chains and I have to adjust it manually in the QA-System...

  • App crash when using JNI callbacks

    Hi all,
    I have a solaris application which crashes when I try to callback the JNI methods from the native code. The description of the problem is below
    Written a native library, the library is multithreaded (i.e) I create a thread using pthread_create() in the native code which performs the operation of calling a JAVA method from the native code. The routine of calling the JAVA method works perfectly from elsewhere.
    There are two scenarios I've tested it in
    1. I created a thread (say X) from the main thread (say Y) and made the y to wait until the X is complete using the pthread_join(). The JAVA callbacks work fine when called from Y but the app crashes if done from X.
    2. Did not make the Y to wait until the X is complete, hoping that both will run paralelly and even the the App crashes.
    And to be precise the Y is the thread where the native method is called from JAVA.
    I have tested for any memory leaks or stack corruption by removing the JAVA callbacks and bulding a executable and using purify, the report doesnot hint any such occurances.
    The linker options used for building the shared library is as follows
    ${GPP} ${INC} -G ${LIB} -mt -g -lCstd -lCrun -lpthread ${OBJS} -o <lib-name>
    I wonder if we can create threads in the native code when using JAVA callbacks and even if we can whether it would be appropiate to use the callbacks with in the threads
    Looking forward for any help.
    Regards,
    Vamsi

    Guys... can't any one help me with this problem :(

  • URGENT: Error while invoking soap-based web service from BPEL process

    I am trying to invoke a soap-based web service deployed in a different OC4J container but on the same iAS middle tier install as the BPEL server. The deployment is successful. I am running 10.1.2 BPEL server.
    But invoking a process throws the following error.
    <remoteFault xmlns="http://schemas.oracle.com/bpel/extension">
    <part name="summary">
    <summary>when invoking locally the endpoint 'http://stadd53.us.oracle.com:7779/idm/ProvService/cps', ; nested exception is: ORABPEL-02052 Cannot lookup BPEL domain. The BPEL domain "ProvService" cannot be found; the domain may not have initialized properly. Please verify that the BPEL domain loader has a valid set of initialization properties in the application properties file.</summary>
    </part>
    <part name="detail">
    <detail>ORABPEL-02052 Cannot lookup BPEL domain. The BPEL domain "ProvService" cannot be found; the domain may not have initialized properly. Please verify that the BPEL domain loader has a valid set of initialization properties in the application properties file.</detail>
    </part>
    </remoteFault>
    Any ideas on what the problem might be ?

    Sandor,
    Thanks. Your suggestion of turning off optSoapShortcut worked. So does that mean that by default remote web services cannot be invoked from BPEL process by SOAP - unless this configuration change is done ?

  • Passing complex object from bpel process to web service

    I have deployed my web service on apache axis.The wsdl file looks like as follows,
    <?xml version="1.0" encoding="UTF-8" ?>
    - <wsdl:definitions targetNamespace="http://bpel.jmetro.actiontech.com" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:apachesoap="http://xml.apache.org/xml-soap" xmlns:impl="http://bpel.jmetro.actiontech.com" xmlns:intf="http://bpel.jmetro.actiontech.com" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
    - <wsdl:types>
    - <schema targetNamespace="http://bpel.jmetro.actiontech.com" xmlns="http://www.w3.org/2001/XMLSchema">
    <import namespace="http://schemas.xmlsoap.org/soap/encoding/" />
    - <complexType name="ADLevelBpelWS">
    - <sequence>
    <element name="adLevelStr" nillable="true" type="xsd:string" />
    <element name="id" type="xsd:int" />
    </sequence>
    </complexType>
    - <complexType name="TransResultWS">
    - <sequence>
    <element name="description" nillable="true" type="xsd:string" />
    <element name="id" type="xsd:long" />
    <element name="responseType" type="xsd:int" />
    <element name="status" type="xsd:boolean" />
    </sequence>
    </complexType>
    - <complexType name="NamespaceDataImplBpelWS">
    - <sequence>
    <element name="ADLevel" nillable="true" type="impl:ADLevelBpelWS" />
    <element name="appdataDef" nillable="true" type="apachesoap:Map" />
    <element name="description" nillable="true" type="xsd:string" />
    <element name="name" nillable="true" type="xsd:string" />
    </sequence>
    </complexType>
    - <complexType name="CreateSharedNamespaceBpelWS">
    - <sequence>
    <element name="actor" nillable="true" type="xsd:string" />
    <element name="comment" nillable="true" type="xsd:string" />
    <element name="from" nillable="true" type="xsd:string" />
    <element name="namespaceData" nillable="true" type="impl:NamespaceDataImplBpelWS" />
    <element name="priority" type="xsd:int" />
    <element name="processAtTime" nillable="true" type="xsd:dateTime" />
    <element name="replyTo" nillable="true" type="xsd:string" />
    <element name="responseRequired" type="xsd:boolean" />
    </sequence>
    </complexType>
    </schema>
    - <schema targetNamespace="http://xml.apache.org/xml-soap" xmlns="http://www.w3.org/2001/XMLSchema">
    <import namespace="http://schemas.xmlsoap.org/soap/encoding/" />
    - <complexType name="mapItem">
    - <sequence>
    <element name="key" nillable="true" type="xsd:string" />
    <element name="value" nillable="true" type="xsd:string" />
    </sequence>
    </complexType>
    - <complexType name="Map">
    - <sequence>
    <element maxOccurs="unbounded" minOccurs="0" name="item" type="apachesoap:mapItem" />
    </sequence>
    </complexType>
    </schema>
    </wsdl:types>
    + <wsdl:message name="createNamespaceRequest">
    <wsdl:part name="createNs" type="impl:CreateSharedNamespaceBpelWS" />
    </wsdl:message>
    - <wsdl:message name="createNamespaceResponse">
    <wsdl:part name="createNamespaceReturn" type="impl:TransResultWS" />
    </wsdl:message>
    - <wsdl:portType name="JMetroWebService">
    - <wsdl:operation name="createNamespace" parameterOrder="createNs">
    <wsdl:input message="impl:createNamespaceRequest" name="createNamespaceRequest" />
    <wsdl:output message="impl:createNamespaceResponse" name="createNamespaceResponse" />
    </wsdl:operation>
    </wsdl:portType>
    - <wsdl:binding name="NAMESPACEWITHMAPSoapBinding" type="impl:JMetroWebService">
    <wsdlsoap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http" />
    - <wsdl:operation name="createNamespace">
    <wsdlsoap:operation soapAction="" />
    - <wsdl:input name="createNamespaceRequest">
    <wsdlsoap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="http://bpel.jmetro.actiontech.com" use="encoded" />
    </wsdl:input>
    - <wsdl:output name="createNamespaceResponse">
    <wsdlsoap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="http://bpel.jmetro.actiontech.com" use="encoded" />
    </wsdl:output>
    </wsdl:operation>
    </wsdl:binding>
    - <wsdl:service name="JMetroWebServiceService">
    - <wsdl:port binding="impl:NAMESPACEWITHMAPSoapBinding" name="NAMESPACEWITHMAP">
    <wsdlsoap:address location="http://localhost:7001/axis/services/NAMESPACEWITHMAP" />
    </wsdl:port>
    </wsdl:service>
    </wsdl:definitions>
    My NamespaceDataObjectImplBpelWS object contains element appDataDef which is of type java.util.Map.My bpel wsdl file is as below,
    <?xml version="1.0"?>
    <definitions name="NsWithMap"
    targetNamespace="http://bpel.jmetro.actiontech.com"
    xmlns:tns="http://bpel.jmetro.actiontech.com"
    xmlns:plnk="http://schemas.xmlsoap.org/ws/2003/05/partner-link/"
    xmlns="http://schemas.xmlsoap.org/wsdl/"
    xmlns:apachesoap="http://xml.apache.org/xml-soap"
    >
    <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    TYPE DEFINITION - List of services participating in this BPEL process
    The default output of the BPEL designer uses strings as input and
    output to the BPEL Process. But you can define or import any XML
    Schema type and us them as part of the message types.
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
    <types>
         <schema targetNamespace="http://bpel.jmetro.actiontech.com" xmlns="http://www.w3.org/2001/XMLSchema">
         <import namespace="http://schemas.xmlsoap.org/soap/encoding/" />
              <element name="createNamespace" type="tns:CreateSharedNamespaceBpelWS"/>
              <element name="transResult" type="tns:TransResultWS"/>
              <complexType name="TransResultWS">
                   <sequence>
                        <element name="description" type="string" />
                        <element name="id" type="long" />
                        <element name="responseType" type="int" />
                        <element name="status" type="boolean" />
              </sequence>
              </complexType>
              <complexType name="ADLevelBpelWS">
                   <sequence>
                        <element name="adLevelStr" type="string" />
                        <element name="id" type="int" />
                   </sequence>
              </complexType>
              <complexType name="NamespaceDataImplBpelWS">
                   <sequence>
                        <element name="ADLevel" type="tns:ADLevelBpelWS" />
                        <element name="description" type="string" />
                        <element name="name" type="string" />
                        <element name="appdataDef" type="apachesoap:Map" />
                   </sequence>
              </complexType>
              <complexType name="CreateSharedNamespaceBpelWS">
                   <sequence>
                        <element name="namespaceData" type="tns:NamespaceDataImplBpelWS" />
              </sequence>
              </complexType>
         <element name="desc" type="string"/>
         </schema>
         <schema targetNamespace="http://xml.apache.org/xml-soap" xmlns="http://www.w3.org/2001/XMLSchema">
                   <import namespace="http://schemas.xmlsoap.org/soap/encoding/" />
                        <complexType name="mapItem">
                             <sequence>
                                  <element name="key" type="string" />
                                  <element name="value" type="string" />
                        </sequence>
                        </complexType>
                        <complexType name="Map">
                             <sequence>
                             <element maxOccurs="unbounded" minOccurs="0" name="item" type="apachesoap:mapItem" />
                             </sequence>
                        </complexType>
              </schema>
    </types>
    <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    MESSAGE TYPE DEFINITION - Definition of the message types used as
    part of the port type defintions
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
    <message name="NsWithMapRequestMessage">
    <part name="payload" element="tns:createNamespace"/>
    </message>
    <message name="NsWithMapResponseMessage">
    <part name="payload" element="tns:transResult"/>
    </message>
    <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    PORT TYPE DEFINITION - A port type groups a set of operations into
    a logical service unit.
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
    <!-- portType implemented by the NsWithMap BPEL process -->
    <portType name="NsWithMap">
    <operation name="initiate">
    <input message="tns:NsWithMapRequestMessage"/>
    </operation>
    </portType>
    <!-- portType implemented by the requester of NsWithMap BPEL process
    for asynchronous callback purposes
    -->
    <portType name="NsWithMapCallback">
    <operation name="onResult">
    <input message="tns:NsWithMapResponseMessage"/>
    </operation>
    </portType>
    <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    PARTNER LINK TYPE DEFINITION
    the NsWithMap partnerLinkType binds the provider and
    requester portType into an asynchronous conversation.
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
    <plnk:partnerLinkType name="NsWithMap">
    <plnk:role name="NsWithMapProvider">
    <plnk:portType name="tns:NsWithMap"/>
    </plnk:role>
    <plnk:role name="NsWithMapRequester">
    <plnk:portType name="tns:NsWithMapCallback"/>
    </plnk:role>
    </plnk:partnerLinkType>
    </definitions>
    I am trying to set this map data using java code ,
         HashMap procADMap1 = new HashMap(5);
                   PropertyTypeWS pType = new PropertyTypeWS();
                   pType.setTypeIndex(2);     
              AppdataDefImplWS appData1 = new AppdataDefImplWS();
              appData1.setName("Project");
              appData1.setType(pType);
              appData1.setMaxSize(400);
              appData1.setLOB(false);
         appData1.setDefaultValue("Project Default value");
              procADMap1.put(appData1.getName(), appData1);
              setVariableData("request","createNs","/createNs/namespaceData/appdataDef",procADMap1);     
    Then I am passing request object to the method which I want to invoke from bpel process.
    I am able to deploy the application but when I do post message I am getting following exception,
    NamespaceWithMap (createNamespace) (faulted)
    [2004/09/09 18:35:54] "{http://schemas.oracle.com/bpel/extension}bindingFault" has been thrown. Less
    faultName: {{http://schemas.oracle.com/bpel/extension}bindingFault}
    messageType: {{http://schemas.oracle.com/bpel/extension}RuntimeFaultMessage}
    code: {Server.userException}
    summary: {org.xml.sax.SAXException: SimpleDeserializer encountered a child element, which is NOT expected, in something it was trying to deserialize.}
    detail: {null}
    Is there any other way to handle Map type in bpel process?
    Thanks in advance,
    Sanjay

    Thanks for the quick reply.Actually the web service is already deployed on the server.What I want to do is use existing wsdl file of the deployed web service and invoke the method of the same using oracle PM.
    If I remove element which uses apachesoap:Map type it just works fine also I am getting the complex object returned by the web service method.But when I try to set appDataDef which is of type apachesoap:Map(Axis conversion for java.util.Map and it uses namespace xmlns:apachesoap="http://xml.apache.org/xml-soap") I am getting the error.
    Can you give me some direction to use this exising wsdl file to set map object or it is not possible.

  • How to inovoke a remote process

    Hi,
    I was wondering how to execute a process like 'gedit', 'ls' etc. in a remote machine by using a java program in another machine. In my case the server program will invoke the client program in different machines. The spec said:
    Runtime.getRuntime().exec("ssh " + host + " ; cd " + path + " ; java Site " + ... arguments ... );
    This is one way to start remote processes in Java. It provides very limited functionality.
    I was wondering what other elegant ways would be there.
    I would be grateful if any body give some suggestion about this.
    Thanks.

    Look up JNI and RMI

  • Test waits forever for a callback from a human task

    Hi,
    I've create a test to test a BPEL process. Now within the BPEL process there is a call to a human task service. I've emulated the task initiation message which is fine. I also tried to emulate the receive message from the human task service but during the test execution, the test waits forever to receive the callback from the human task service, even though i've specified the return message. Would appreciate help with this! I've posted my testbpel.bpel and the test case (CreditCardInvalidTest.xml) below. For both these files I've highlighted in bold the relevant bits of code that's giving me problems. Thanks
    testbpel.bpel:
    <?xml version = "1.0" encoding = "UTF-8" ?>
    <process name="testbpel" targetNamespace="http://xmlns.oracle.com/testbpel"
    xmlns="http://schemas.xmlsoap.org/ws/2003/03/business-process/"
    xmlns:wfcommon="http://xmlns.oracle.com/bpel/workflow/common"
    xmlns:bpws="http://schemas.xmlsoap.org/ws/2003/03/business-process/"
    xmlns:xp20="http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20"
    xmlns:ns4="http://www.oracle.com/XSL/Transform/java/oracle.tip.xref.xpath.XRefXPathFunctions"
    xmlns:ns7="http://xmlns.oracle.com/testbpel/creditFault"
    xmlns:ldap="http://schemas.oracle.com/xpath/extension/ldap"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:wf="http://schemas.oracle.com/bpel/extension/workflow"
    xmlns:ns5="http://oracle.com/esb/namespaces/Fufillment"
    xmlns:client="http://xmlns.oracle.com/testbpel"
    xmlns:ns6="http://www.creditcardagency.com/CreditCardService"
    xmlns:ora="http://schemas.oracle.com/xpath/extension"
    xmlns:taskservice="http://xmlns.oracle.com/bpel/workflow/taskService"
    xmlns:ns9="http://xmlns.oracle.com/testbpel/orderRejected"
    xmlns:ns1="http://xmlns.oracle.com/bpel/workflow/xpath"
    xmlns:ns3="http://www.oracle.com/XSL/Transform/java/oracle.tip.esb.server.headers.ESBHeaderFunctions"
    xmlns:ns2="http://xmlns.oracle.com/bpel/services/IdentityService/xpath"
    xmlns:bpelx="http://schemas.oracle.com/bpel/extension"
    xmlns:task="http://xmlns.oracle.com/bpel/workflow/task"
    xmlns:orcl="http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc"
    xmlns:ns8="http://xmlns.oracle.com/testbpel/genericFault">
    <!--
    PARTNERLINKS
    List of services participating in this BPEL process
    -->
    <partnerLinks>
    <!--
    The 'client' role represents the requester of this service. It is
    used for callback. The location and correlation information associated
    with the client role are automatically set using WS-Addressing.
    -->
    <partnerLink name="client" partnerLinkType="client:testbpel"
    myRole="testbpelProvider" partnerRole="testbpelRequester"/>
    <partnerLink name="ShipmentService" partnerRole="execute_pptProvider"
    partnerLinkType="ns5:execute_pptLT"/>
    <partnerLink name="CreditCardService"
    partnerRole="CreditCardServiceProvider"
    partnerLinkType="ns6:CreditCardService"/>
    <partnerLink myRole="TaskServiceCallbackListener" name="TaskService"
    partnerRole="TaskService"
    partnerLinkType="taskservice:TaskService"/>
    </partnerLinks>
    <!--
    VARIABLES
    List of messages and XML documents used within this BPEL process
    -->
    <variables>
    <!-- Reference to the message passed as input during initiation -->
    <!-- Reference to the message that will be sent back to the requester during callback -->
    <variable name="inputVariable"
    messageType="client:testbpelRequestMessage"/>
    <variable name="outputVariable"
    messageType="client:testbpelResponseMessage"/>
    <variable name="n" type="xsd:integer"/>
    <variable name="Invoke_ShipmentService_execute_InputVariable"
    messageType="ns5:orderRequest_request"/>
    <variable name="paymentFault"
    messageType="client:testbpelFaultMessage"/>
    <variable name="ApproveOrder_1_globalVariable"
    messageType="taskservice:taskMessage"/>
    <variable name="orderRejectedFault"
    messageType="client:testbpelFaultMessage"/>
    </variables>
    <faultHandlers>
    <catchAll>
    <sequence name="Sequence_6">
    <throw name="Throw_AllFaults"
    faultName="ns8:testbpelGenericFault"
    faultVariable="paymentFault"/>
    </sequence>
    </catchAll>
    </faultHandlers>
    <!--
    ORCHESTRATION LOGIC
    Set of activities coordinating the flow of messages across the
    services integrated within this business process
    -->
    <sequence name="main">
    <!-- Receive input from requestor. (Note: This maps to operation defined in testbpel.wsdl) -->
    <receive name="receiveInput" partnerLink="client"
    portType="client:testbpel" operation="initiate"
    variable="inputVariable" createInstance="yes"/>
    <!--
    Asynchronous callback to the requester. (Note: the callback location and correlation id is transparently handled using WS-addressing.)
    -->
    <scope name="CheckForApproval">
    <sequence name="Sequence_4">
    <sequence name="Sequence_5">
    <scope name="ApproveOrder_1"
    xmlns:wf="http://schemas.oracle.com/bpel/extension/workflow"
    wf:key="ApproveOrder_1_globalVariable">
    <bpelx:annotation>
    <bpelx:pattern patternName="bpelx:workflow"></bpelx:pattern>
    </bpelx:annotation>
    <variables>
    <variable name="initiateTaskInput"
    messageType="taskservice:initiateTaskMessage"/>
    <variable name="initiateTaskResponseMessage"
    messageType="taskservice:initiateTaskResponseMessage"/>
    </variables>
    <correlationSets>
    <correlationSet name="WorkflowTaskIdCor"
    properties="taskservice:taskId"/>
    </correlationSets>
    <sequence>
    <assign name="ApproveOrder_1_AssignTaskAttributes">
    <copy>
    <from expression="concat(ora:getProcessURL(), string('/ApproveOrder/ApproveOrder.task'))"/>
    <to variable="initiateTaskInput"
    part="payload"
    query="/taskservice:initiateTask/task:task/task:taskDefinitionURI"/>
    </copy>
    <copy>
    <from expression="number(3)"/>
    <to variable="initiateTaskInput"
    part="payload"
    query="/taskservice:initiateTask/task:task/task:priority"/>
    </copy>
    <copy>
    <from>
    <payload xmlns="http://xmlns.oracle.com/bpel/workflow/task"/>
    </from>
    <to variable="initiateTaskInput"
    part="payload"
    query="/taskservice:initiateTask/task:task/task:payload"/>
    </copy>
    </assign>
    <assign name="ApproveOrder_1_AssignSystemTaskAttributes">
    <copy>
    <from expression="ora:getInstanceId()"/>
    <to variable="initiateTaskInput"
    part="payload"
    query="/taskservice:initiateTask/task:task/task:processInfo/task:instanceId"/>
    </copy>
    <copy>
    <from expression="ora:getProcessId()"/>
    <to variable="initiateTaskInput"
    part="payload"
    query="/taskservice:initiateTask/task:task/task:processInfo/task:processName"/>
    </copy>
    <copy>
    <from expression="ora:getProcessId()"/>
    <to variable="initiateTaskInput"
    part="payload"
    query="/taskservice:initiateTask/task:task/task:processInfo/task:processId"/>
    </copy>
    <copy>
    <from expression="ora:getProcessVersion()"/>
    <to variable="initiateTaskInput"
    part="payload"
    query="/taskservice:initiateTask/task:task/task:processInfo/task:processVersion"/>
    </copy>
    <copy>
    <from expression="ora:getDomainId()"/>
    <to variable="initiateTaskInput"
    part="payload"
    query="/taskservice:initiateTask/task:task/task:processInfo/task:domainId"/>
    </copy>
    <copy>
    <from expression="string('BPEL')"/>
    <to variable="initiateTaskInput"
    part="payload"
    query="/taskservice:initiateTask/task:task/task:processInfo/task:processType"/>
    </copy>
    </assign>
    <invoke name="initiateTask_ApproveOrder_1"
    partnerLink="TaskService"
    portType="taskservice:TaskService"
    operation="initiateTask"
    inputVariable="initiateTaskInput"
    outputVariable="initiateTaskResponseMessage">
    <correlations>
    <correlation initiate="yes"
    set="WorkflowTaskIdCor"
    pattern="in"/>
    </correlations>
    </invoke>
    *<receive name="receiveCompletedTask_ApproveOrder_1"*
    partnerLink="TaskService"
    portType="taskservice:TaskServiceCallback"
    operation="onTaskCompleted"
    variable="ApproveOrder_1_globalVariable"
    createInstance="no">
    *<correlations>*
    *<correlation initiate="no"*
    set="WorkflowTaskIdCor"/>
    *</correlations>*
    *</receive>* </sequence>
    </scope>
    <switch name="taskSwitch">
    <case condition="bpws:getVariableData('ApproveOrder_1_globalVariable', 'payload', '/task:task/task:systemAttributes/task:state') = 'COMPLETED' and bpws:getVariableData('ApproveOrder_1_globalVariable', 'payload', '/task:task/task:systemAttributes/task:outcome') = 'REJECT'">
    <bpelx:annotation>
    <bpelx:pattern patternName="case">Task outcome is REJECT</bpelx:pattern>
    </bpelx:annotation>
    <sequence>
    <assign name="AssignOrderRejected">
    <copy>
    <from expression="string('Order rejected by manager')"/>
    <to variable="paymentFault"
    part="payload"
    query="/client:testbpelProcessFault/client:status"/>
    </copy>
    </assign>
    <throw name="ThrowOrderRejected"
    faultName="ns9:orderRejectedFault"
    faultVariable="orderRejectedFault"/>
    </sequence>
    </case>
    <case condition="bpws:getVariableData('ApproveOrder_1_globalVariable', 'payload', '/task:task/task:systemAttributes/task:state') = 'COMPLETED' and bpws:getVariableData('ApproveOrder_1_globalVariable', 'payload', '/task:task/task:systemAttributes/task:outcome') = 'APPROVE'">
    <bpelx:annotation>
    <bpelx:pattern patternName="case">Task outcome is APPROVE</bpelx:pattern>
    </bpelx:annotation>
    <sequence>
    <empty name="Empty_1"/>
    </sequence>
    </case>
    <otherwise>
    <bpelx:annotation>
    <bpelx:pattern>Task is outcome is EXPIRED, STALE, WITHDRAWN or ERRORED</bpelx:pattern>
    </bpelx:annotation>
    <sequence>
    <empty name="Empty_2"/>
    </sequence>
    </otherwise>
    </switch>
    </sequence>
    </sequence>
    </scope>
    <scope name="CheckCreditCard">
    <variables>
    <variable name="InvokeCreditCardService_process_InputVariable"
    messageType="ns6:CreditCardServiceRequestMessage"/>
    <variable name="InvokeCreditCardService_process_OutputVariable"
    messageType="ns6:CreditCardServiceResponseMessage"/>
    </variables>
    <sequence name="Sequence_2">
    <assign name="Assign_1">
    <copy>
    <from variable="inputVariable" part="payload"
    query="/client:testbpelProcessRequest/client:CreditCardNumber"/>
    <to variable="InvokeCreditCardService_process_InputVariable"
    part="payload"
    query="/ns6:CreditCardServiceProcessRequest/ns6:CreditCardNumber"/>
    </copy>
    </assign>
    <scope name="Scope_1">
    <compensationHandler>
    <sequence name="Sequence_7">
    <empty name="Empty_3"/>
    </sequence>
    </compensationHandler>
    <invoke name="InvokeCreditCardService"
    partnerLink="CreditCardService"
    portType="ns6:CreditCardService" operation="process"
    inputVariable="InvokeCreditCardService_process_InputVariable"
    outputVariable="InvokeCreditCardService_process_OutputVariable"/>
    </scope>
    <switch name="CheckCreditCardValid">
    <case condition="bpws:getVariableData('InvokeCreditCardService_process_OutputVariable','payload','/ns6:CreditCardServiceProcessResponse/ns6:result') = 'false'">
    <sequence name="Sequence_3">
    <assign name="AssignCreditFault">
    <copy>
    <from expression="string('Invalid credit card number')"/>
    <to variable="paymentFault" part="payload"
    query="/client:testbpelProcessFault/client:status"/>
    </copy>
    </assign>
    <throw name="ThrowCreditFault"
    faultName="ns7:CreditCardNumberFault"
    faultVariable="paymentFault"/>
    </sequence>
    </case>
    </switch>
    </sequence>
    </scope>
    <assign name="AssignInitial">
    <copy>
    <from expression="string('Select Manufacturer')"/>
    <to variable="outputVariable" part="payload"
    query="/client:testbpelProcessResponse/client:result"/>
    </copy>
    <copy>
    <from expression="1"/>
    <to variable="n"/>
    </copy>
    <copy>
    <from expression="0.0"/>
    <to variable="outputVariable" part="payload"
    query="/client:testbpelProcessResponse/client:price"/>
    </copy>
    </assign>
    <while name="While_1"
    condition="bpws:getVariableData('n') &lt;= count(bpws:getVariableData('inputVariable','payload','/client:testbpelProcessRequest/client:input'))">
    <sequence name="Sequence_1">
    <assign name="DoCalculation">
    <copy>
    <from expression="bpws:getVariableData('inputVariable','payload', concat('/client:testbpelProcessRequest/client:input[', bpws:getVariableData('n'), ']/client:quantity')) * bpws:getVariableData('inputVariable','payload',concat('/client:testbpelProcessRequest/client:input[', bpws:getVariableData('n'), ']/client:bookPrice')) + bpws:getVariableData('outputVariable','payload','/client:testbpelProcessResponse/client:price')"/>
    <to variable="outputVariable" part="payload"
    query="/client:testbpelProcessResponse/client:price"/>
    </copy>
    <copy>
    <from expression="bpws:getVariableData('n') + 1"/>
    <to variable="n"/>
    </copy>
    </assign>
    </sequence>
    </while>
    <assign name="Transform_2">
    <bpelx:annotation>
    <bpelx:pattern>transformation</bpelx:pattern>
    </bpelx:annotation>
    <copy>
    <from expression="ora:processXSLT('TransformOrder.xsl',bpws:getVariableData('inputVariable','payload'))"/>
    <to variable="Invoke_ShipmentService_execute_InputVariable"
    part="orderRequest"/>
    </copy>
    </assign>
    <invoke name="Invoke_ShipmentService" partnerLink="ShipmentService"
    portType="ns5:execute_ppt" operation="execute"
    inputVariable="Invoke_ShipmentService_execute_InputVariable"/>
    <invoke name="callbackClient" partnerLink="client"
    portType="client:testbpelCallback" operation="onResult"
    inputVariable="outputVariable"/>
    </sequence>
    </process>
    CreditCardInvalidTest.xml:
    <?xml version='1.0' encoding='utf-8'?>
    <BPELTest processName="testbpel"
    xmlns="http://xmlns.oracle.com/bpel/instancedriver"
    xmlns:client="http://xmlns.oracle.com/testbpel">
    <initiate operation="initiate">
    <inboundMessage>
    <part fileName="testInput.xml" name="payload"/>
    </inboundMessage>
    </initiate>
    <activityDriver name="callbackClient">
    <assertValue variableName="outputVariable" partName="payload"
    comparisonMethod="string" fatal="false" patternMatch="false">
    <message>Expected "Select Manufacturer"</message>
    <actualPath>/client:testbpelProcessResponse/client:result</actualPath>
    <expected>Select Manufacturer</expected>
    </assertValue>
    <assertValue variableName="outputVariable" partName="payload"
    comparisonMethod="string" fatal="true" patternMatch="false">
    <message>Expected price of "1"</message>
    <actualPath>/client:testbpelProcessResponse/client:price</actualPath>
    <expected>1</expected>
    </assertValue>
    </activityDriver>
    *<activityDriver name="receiveCompletedTask_ApproveOrder_1">*
    *<emulate duration="PT">*
    *<inboundMessage>*
    *<part fileName="approverResponse.xml" name="payload"/>*
    *</inboundMessage>*
    *</emulate>*
    *</activityDriver>* <activityDriver name="InvokeCreditCardService">
    <emulate duration="PT">
    <inboundMessage>
    <part fileName="creditCardServiceResponse.xml" name="payload"/>
    </inboundMessage>
    </emulate>
    </activityDriver>
    <activityDriver name="initiateTask_ApproveOrder_1">
    <emulate duration="PT">
    <inboundMessage>
    <part fileName="getApproval.xml" name="payload"/>
    </inboundMessage>
    </emulate>
    </activityDriver>
    </BPELTest>

    Hi hi, on a hunch I previewed the page in the browser, and copy pasted the faces/untitled1 portion of the URL there and pasted on the http://<server_address>:8001/BasicAPPDemo_Root therefore ending with http://<server_address>:8001/BasicAPPDemo_Root/faces/untitled1 and lo and behold I saw the little text box saying "Hello World" ;D
    So with that i escalated, switched to the application where the page from BPM was located, deployed it and did the same trick.
    But it borked it gave this error:
    JBO-29115 Unable to construct the error message due to error java.lang.NullPointerException. Use the exception stack trace and error code to investigate the root cause of this exception. Root cause error code is JBO-.
    I figured that the Default generation could be faulty so i created a new page and only recycled the data controls, created everything in read mode, just to test and deployed, when i tested, i was optimistic as the 1st tab didn't had any error (also does not have anything related to the HumanTask, even the data controls) the problem was in the other tabs as I show here.
    Many thanks sirs, and sorry for wasting thy time.

  • How do you load subReports in ReportViewer in remote processing mode using LoadReportDefinition

    We have a reportViewer control on a web page that renders reports in Remote ProcessingMode.
    However, it does not access the reports from the SSRS server, it loads them from our own repository, and sends the Stream of the RDL file to LoadReportDefinition.
    This works fine when there are no SubReports.  However, I am not sure how to handle SubReports.
    I know that in Local ProcessingMode you have to handle the events to load the SubReports manually, and that in normal Remote ProcessingMode when running a report stored on the server, it handles the SubReports for you.
    But what is the process for handling SubReports for Reports in Remote Processing mode that are rendered with LoadReportDefinition?
    Should I handle the event and load the SubReport manually somehow using LoadReportDefinition again?  Or is it simply not supported?

    Hi jth001,
    From your description, do you mean the ReportExecutionService.LoadReportDefinition method or the LocalReport.LoadReportDefinition method? If it is the former method, subreports and data source references with relative paths are not supported using this
    method. However, absolute paths to catalog items can be used. For more information, please see:
    ReportExecutionService.LoadReportDefinition Method
    If it is the latter, you need to call LoadSubreportDefinition method and provide data for any subreports. Fore more information, please refer to:
    LocalReport.LoadReportDefinition Method
    LocalReport.LoadSubreportDefinition Method
    Regards,
    Mike Yin
    TechNet Subscriber Support
    If you are TechNet Subscription user and have any feedback on our support quality, please send your feedback
    here.

  • SAP Training from Remote (Internet based)

    SAP Training from Remote (Internet based)
    Instructor – Mr. Nanda Kishore
    §     IIT engineer with 10 years of SAP specific training experience
    §     Trained hundreds of students now well placed in BIG 4 consulting firms
    §     Official trainer for companies like Infosys, Triniti, Coconut and Emcure
    §     Experienced in ABAP, BW, XI
    Upcoming Training session - SAP ABAP
    Batch starts August 13, 2007
    Highlights
    §     Rigorous curriculum
    §     Techno functional perspective to ABAP development
    §     Real time scenarios
    §     Graded assignments
    Target Audience
    §     Recent graduates seeking to start a career in SAP
    §     Programmers looking to transition to a promising career with SAP
    §     Functional consultants or Industry process experts looking to enhance their ABAP programming & debugging skills
    Testimonials
    “… Great experience being taught by an IITIAN….I think my IQ increased after getting trained by him and I had offer from two companies Accenture and Bearing Point. He prepared me so thoroughly for client interview and life afterwards that not only I got selected in my first interview but till date I could not find a better consultant than myself. I am currently working as a senior consultant in Bearing Point.” – Arshad
    “ … Excellent trainer with great depth of knowledge. His exercises and curriculum are both very challenging. The whole training was a blast and there was an exponential increase in my knowledge all throughout the course.” – Hemant, EDS employee
    “I always use to think that I will some day jump to SAP technologies but with two kids I never had the energy and the stamina to change to SAP till I met Kishore. My income jumped up in six months time. Today I am a team lead with a big pharmaceutical company. Mr. Kishore is the one who fully helped me change my career path.” – Saurav 
    For more information (fees and connectivity) contact
    Email: [email protected]
    Tel: 732-529-4188

    Hi,
    All mentioned options are possible to access SAP Business One, like:
    Static IP address for SAP B1 server
    Citrix (application or remote desktop)
    VPN (you can even setup a simple PPTP, L2TP or OpenVPN). But please be aware that VPN is not recommended by SAP way of connection to ERP systems
    There is the fourth nice alternative to avoid VPN and RDP in case you can't use both of them (because of, for instance, local network security settings that blocks you to setup a connection). You can setup HTML Clientless RDP connection at your main server of the remote network (it is even not necessary your SAP B1 server, you should do it on the main machine that has static IP):
    Guacamole - HTML5 Clientless Remote Desktop
    In this case you will get the RDP connection to your client or server machine with SAP B1 from any kind of network and any kind of device with no additional client setup. It is even work from the mobile phone, but, of course, the screen it too small
    Here is how it looks like (in my local browser):
    Kind Regards,
    Siarhei

  • Partition ERROR - 1023040 - msg from remote site : need to understand

    hi,
    I currently have a problem with the partitions between two cubes.
    Architecture:
          80 countries database (source)
          1 world database (destination)
    Process :
    - The partitions are created dynamically by maxl scripts :
    spool on to $1;
    Alter application $2 comment '**_batch_**';
    Alter application $4 comment '**_batch_**';
    Alter system load application $2;
    Alter system load application $4;
    Alter application $2 disable startup;
    Alter application $4 disable startup;
    Alter application $2 disable connects;
    Alter application $4 disable connects;
    /* Create Transparant Partition between Country cube to Mond cube */
    create or replace replicated partition $2.$3
    AREA
    '"S_R_N",
    &curr_month,
    &local_currency, "D_EURO",
    @IDESCENDANTS("P_Produit"),
    @LEVMBRS("M_Marche",1),"M_Marche",
    @IDESCENDANTS("B_Marque"),
    @IDESCENDANTS("U_Sourcing"),
    @REMOVE (@DESCENDANTS("I_Masse"), @LIST ("I_55CCOM")), @DESCENDANTS("I_Divers"),
    @IDESCENDANTS("NA_Nature"),MCX'
    to $4.$5
    AREA
    '"S_R_N",
    &curr_month,
    "D_DEV", "D_EUR",
    @IDESCENDANTS("P_Produit"),
    @LEVMBRS("M_MixClient",0),"M_MixClient",
    @IDESCENDANTS("B_Marque"),
    @IDESCENDANTS("U_Sourcing"),
    @REMOVE (@DESCENDANTS("I_Masse"), @LIST ("I_55CCOM")), @DESCENDANTS("I_Divers"),
    @IDESCENDANTS("NA_Nature"),MCX,
    &country_name'
    mapped globally ('',D_$7, "D_EURO", "M_Marche") to (W_$6,D_DEV, "D_EUR", "M_MixClient")
    refresh replicated partition $2.$3 to $4.$5 all data;
    drop replicated partition $2.$3 to $4.$5;
    Alter application $2 enable startup;
    Alter application $4 enable startup;
    Alter application $2 enable connects;
    Alter application $4 enable connects;
    Alter application $2 comment '**_enable_**';
    Alter application $4 comment '**_enable_**';
    Alter system unload application $2;
    Alter system unload application $4;
    Spool off;
    Logout;
    exit;
    - Defragmentation cubes, launch replications countries successively one by one to the world cubes sequentially .
    the order of the country is not the same from one month to another .
    Treatment is initiated each month.
    Symptoms :
    - Partition fall into error with the following message but not systematically .
    message:
    MAXL > refresh replicated partition PGC_ESP.Pgc_esp PGC_MOND.Pgc_mond to all data ;
       ERROR - 1023040 - msg from remote site [ [ Wed Nov. 29 10:21:03 2013] hprx1302/PGC_MOND/Pgc_mond/PGC_ADMIN/Error ( 1023040 ) msg from remote site [ [ Wed Nov. 29 10:21:02 2013] hprx1302 / PGC_ESP / Pgc_esp / PGC_ADMIN / Error (1023040) msg from remote site [ [ Wed Nov. 29 10:21:01 2013] hprx1302/PGC_MOND/Pgc_mond/PGC_ADMIN/Error ( 1042012 ) Network error [ 32] : Can not Send Data ]]] .
    We note that the error occurs in the following cases:
    - The errerur happens generally when the average clustering ratio is low. (cube fragmented) for cubes source and / or destination
    - When beacuoup replication were done before: in the last 10 to 15 cubic remaining replicate.
    - We mistake once on the environment recipe on the first cube with average clustering ratio to 0.96 but the server recipe is much less efficient.
    We noticed that when doing a defragmentation cubes source and destination once the error obtained treatment replication was no longer falling into error.
    Problem: defragmentation cube world take 10 hours.
    We also made the following observation:
    OK/INFO - 1051034 - Logging in user [PGC_ADMIN].
    OK/INFO - 1051035 - Last login on Friday, November 29, 2013 10:19:46 AM.
    OK/INFO - 1053012 - Object [Pgc_esp] is locked by user [PGC_ADMIN].
    OK/INFO - 1053012 - Object [Pgc_mond] is locked by user [PGC_ADMIN].
    OK/INFO - 1053012 - Object [54116855] is locked by user [PGC_ADMIN].
    OK/INFO - 1053012 - Object [39843334] is locked by user [PGC_ADMIN].
    OK/INFO - 1053013 - Object [54116855] unlocked by user [PGC_ADMIN].
    OK/INFO - 1053013 - Object [39843334] unlocked by user [PGC_ADMIN].
    WARNING - 1241137 - [Target] - Partition definition is not valid: [Cell count mismatch: [1279464568200] area for slice [1] members per dimension [63 1 2 1 6 26 7 245 1 37955 ]].
    OK/INFO - 1053012 - Object [25586652] is locked by user [PGC_ADMIN].
    OK/INFO - 1053012 - Object [11329970] is locked by user [PGC_ADMIN].
    OK/INFO - 1053013 - Object [25586652] unlocked by user [PGC_ADMIN].
    OK/INFO - 1053013 - Object [11329970] unlocked by user [PGC_ADMIN].
    WARNING - 1241137 - [Source] - Partition definition is not valid: [Cell count mismatch: [47895484140] area for slice [1] members per dimension [63 1 6 7 2173 2 17 1 245 ]].
    OK/INFO - 1053013 - Object [Pgc_esp] unlocked by user [PGC_ADMIN].
    OK/INFO - 1053013 - Object [Pgc_mond] unlocked by user [PGC_ADMIN].
    OK/INFO - 1051037 - Logging out user [PGC_ADMIN], active for 0 minutes.
    OK/INFO - 1241124 - Partition replaced.
    Following these findings we need to understand what is happening.
    We would like to understand why partitons fall errors?
    why we have the message "Partition definition is not valid" in the logs when creating the partition?
    Regards,
    Oliv.

    Hi SreekumarHariharan,
    Tx to your anwers, but we are already try all the solution proposes to Essbase FAQ.
    a)Increase the values for NETDELAY and NETRETRYCOUNT in essbase.cfg file.Restart the essbase server.
    We are changed the two value in the essbase.cfg but nothing to do. The same error appears
    b)Make sure that the all source members and target members used in partition are in sync
    All member are diferent between source and target but a mapping are defined in the partition (see the partition maxl in my below message.
    c)Validate the partition (look at the validation tab, it will give the numbers for each side of the partition ie source area and target area)
    You can see the logs of validation partition :
    WARNING - 1241137 - [Target] - Partition definition is not valid: [Cell count mismatch: [1279464568200] area for slice [1] members per dimension [63 1 2 1 6 26 7 245 1 37955 ]].
    OK/INFO - 1053012 - Object [25586652] is locked by user [PGC_ADMIN].
    OK/INFO - 1053012 - Object [11329970] is locked by user [PGC_ADMIN].
    OK/INFO - 1053013 - Object [25586652] unlocked by user [PGC_ADMIN].
    OK/INFO - 1053013 - Object [11329970] unlocked by user [PGC_ADMIN].
    WARNING - 1241137 - [Source] - Partition definition is not valid: [Cell count mismatch: [47895484140] area for slice [1] members per dimension [63 1 6 7 2173 2 17 1 245 ]].
    OK/INFO - 1053013 - Object [Pgc_esp] unlocked by user [PGC_ADMIN].
    OK/INFO - 1053013 - Object [Pgc_mond] unlocked by user [PGC_ADMIN].
    OK/INFO - 1051037 - Logging out user [PGC_ADMIN], active for 0 minutes.
    OK/INFO - 1241124 - Partition replaced.
    d)Rerun the Partition script again
    The same error appears.
    Tx to your help.
    Regards,
    Oliv.

  • Debugger unable to connect to remote process

    Hi There,
    I am running Jdev on pc and OAS 10g on an unix environment. I followed the step in the doc to set up the remote debugging. However, when I start the remote debugger from jdev, i got the following error message.
    Debugger attempting to connect to remote process at ax-portal-www6.dev.ipass.com 4000..
    Debugger unable to connect to remote process.
    Your help wuld be greatly appreciated.

    A couple things to try:
    1) Verify your jdk version and build bug 4411232
    2) Increase your Debugger preferences Connection retries to double the default (especially if multiple apps running, low memory or a slow machine)
    Without more specifics on versions, type of debugging or details not much more I can suggest.

  • 'Dataguard remote process startup failed'

    Hi
    When I try to use the Data Guard to configure my Physical Database ( Which for testing purposes, is planned to have onthe same machind as the Primary) - gives me the error
    'Dataguard remote process startup failed'
    Please help me.!
    Can anyone give me the details of how to create a physical standby from scratch.. considernig the fact that I am new to Oracle... I am donig it as per the documentation, but not able to start the standyby database which is on the same machine using the pfile...
    Thanks
    Radhika

    Are you creating standby database using data guard manager through oracle managment server? If so, have you applied patches or not?
    Here is the excerpt from metalink note : 204848.1
    ====
    Data Guard Manager reports "Data Guard remote process startup failed." Error Dialog
    Fact
    Oracle Enterprise Manager Data Guard Manager 9.2.0.1.0
    Symptom
    "Data Guard remote process startup failed" error dialog in the Oracle
    Enterprise Manager 'Create Configuration' Wizard is displayed when you
    attempt to run Data Guard Manager and your environment is not setup
    correctly.
    Fix
    Check and address the following items in the order listed.
    1) Ensure the Oracle installations for both the primary and standby Oracle
    Homes contain Perl.
    On UNIX systems, verify this by looking in each Oracle Home for the
    $ORACLE_HOME/Apache/perl/bin/perl file. On NT systems, look for the
    file $ORACLE_HOME\apache\perl\5.00503\bin\mswin32-x86\perl.
    If this file is present, Perl is installed; and proceed to step 2.
    If not, then you must install the Perl that comes with Oracle.
    Follow these steps to install Perl on both the primary and standby
    Oracle Homes:
    a. Run the Oracle Installer and choose the Oracle Home in question.
    b. Choose the "Oracle9i Database 9.2.0.1.0" option.
    c. Choose "Custom" for the installation type.
    d. Under "Oracle Enterprise Manager Products 9.2.0.1.0", choose to
    install the "Enterprise Manager Website 9.2.0.1.0" item.
    e. Complete the install.
    f. Verify that the Perl installation succeeded by checking for the
    presence of the above file. If successful, proceed to step 2.
    2) Ensure that all Data Guard Manager patches are installed in
    the OEM installation.
    These following two patches are independent of each other and must both be
    installed on all versions of 9.2.0:
    Patch Number 3409886 (supercedes Patch 2670975)
    Patch Number 2671349
    Download these patches from Oracle Support Services Website, Metalink,
    http://metalink.oracle.com. Activate the "Patches" button to get the
    patches Web page. Enter the Patch number and activate the "Submit"
    button. The patches are listed for the Windows and Solaris operating
    systems only. However, they are generic patches that will work on
    other platforms.
    After verifying that each patches are installed, proceed to step 3.
    3) Ensure the Oracle Intelligent Agent is running on both the primary and
    standby nodes.
    The Agent must be running for Data Guard to function. Check it by
    running agentctl status on the primary and standby nodes. If it is not
    running, start it by running the command agentctl start. After verifying
    that it is running on both nodes, proceed to step 4.
    4) Ensure that the user specified in the primary and standby node preferred
    credentials can successfully run an OEM job.
    Data Guard Manager requires that OEM preferred credentials are specified
    for both the primary and standby node. Furthermore, these credentials
    must specify a user(s) who has read/write permissions in the primary
    and standby Oracle Homes, respectively.
    Note well: Databases that are on Windows NT/2000 require that the
    the user(s) specified in the credentials must be granted
    the "Log on as a batch job" privilege.
    After checking that preferred node credentials are set correctly on both
    nodes, run a test OEM job to verify that jobs are functioning properly.
    Do this as follows:
    a) Select the Create Job item in the OEM Console Job menu.
    b) Give the job a name, select Node as the Target Type, select and
    add the primary node as the target.
    c) Go to the Tasks tab, select and add "Run OS Command".
    d) Go to the Parameters tab and specify a simple OS command such
    as ls on UNIX, or dir on NT.
    e) Click Submit.
    f) Once the job is finished, select the Jobs icon in the OEM Console
    tree, select the History tab, and examine the Job output.
    If it was successful, jobs are working and you can try the Data
    Guard Create Configuration wizard again.
    If the job failed, you must troubleshoot this problem and fix it
    before continuing with Data Guard Manager.
    5) If problems persist, obtain additional information and log a
    Support Request (iTAR).
    If everything in the previous steps is OK, and Data Guard Manager
    continues to fail, additional information is required to diagnose the
    problem. The following two items must be obtained and submitted to
    Oracle Support Services:
    a) OEM client tracing.
    The Create Configuration wizard must be run again in trace mode.
    This can be done by starting OEM from a command prompt (i.e., not
    the Windows NT start menu) as follows:
    oemapp trace console
    Client tracing messages will appear in the command window from
    which this command is run. Data Guard Manager should be started and
    the Create Configuration wizard should then be run up to the point
    where the error occurs. All tracing messages from Create
    Configuration wizard start-up to this point should then be captured
    and saved into a file.
    b) Data Guard job output
    The output from any failed Data Guard jobs must be captured. This
    can be done as follows:
    1) Select the Jobs icon in the OEM Console tree.
    2) Select the History tab.
    3) Double-click on the latest "DataGuardCtrlXXXX" job that has a
    Failed status.
    4) An Edit Job window will pop up; double-click on the Failed line
    to obtain the output.
    5) Put the output into a file.
    If a Data Guard Manager bug is submitted, the tracing output and the
    job output will be required.
    ====
    Jaffar

  • How to callback from a webservice to a workflow node?

    I've initiated a conversation with a webservice from a workflow. The workflow
    goes on until it gets to the point where it must stop and wait for the callback
    from the webservice. I'd like it to passively wait (not polling in a loop).
    I'm an intermediate with webservices, not an expert - I think the callback handler
    should be in the workflow somewhere and the callback method should be defined
    in the webservice - am I completely off-base? Conceptually, could someone explain
    how a webservice could callback to a specific node in a workflow?

    Hi Lisa,
    if you are speaking about Weblogic 8.1, then use Client Response nodes in
    the webservice and Control Receive nodes in the calling workflow process.
    Regards,
    Robert Varga
    "Lisa" <[email protected]> wrote in message
    news:3fcf9105$[email protected]..
    >
    I've initiated a conversation with a webservice from a workflow. Theworkflow
    goes on until it gets to the point where it must stop and wait for thecallback
    from the webservice. I'd like it to passively wait (not polling in aloop).
    I'm an intermediate with webservices, not an expert - I think the callbackhandler
    should be in the workflow somewhere and the callback method should bedefined
    in the webservice - am I completely off-base? Conceptually, could someoneexplain
    how a webservice could callback to a specific node in a workflow?

Maybe you are looking for

  • Is it possible to split the same document, Word-style?

    I don't know what else to call it. In Word, it was "split." I often edit two parts of the same document simultaneously, but in Pages 08, I haven't been able to figure this out. "Two Up" is not what I'm looking for. For example, what I would do in Wor

  • Agent Issue In Obiee 11g

    In OBIEE 11G, how to send automatically one email for different level users for having a look different data by agent? For example: One report architeture: Region--------District---------Sales Region 1------District1--------100 ------------------Dist

  • Flex Mobile Videoplayback ( GPU / CPU )

    Hi, I have problems with videoplayback on Android in an Flex Mobile app. I using the pur AS3 Strobe Media Playback with OSMF. When a play in emulator the video is ok, but on my Android device there are random lines on the Videos ( streamed or local )

  • SharePoint 2013 remove character

    Hi, I would like to remove special character  like :'!@#$%^&*()", from my field. exaple value that i can have: my favorite color: red ,blue & green can i use Sharepoint designer 2013 ? or maybe calculated field ? tnx, nikita

  • Can elements11 be installed on more than one computer

    Can elements 11 be installed on more than one computer