How to process a task asynchronously

Hi all,
I have written a FlexUI command that takes a very long time to finish. How can I do the processing asynchronously?
I found that the task queue service could do the trick, but I did not find an example.
Can anyone help?
Many thanks for your attention,
--Stefan

Hi all,
I have written a FlexUI command that takes a very long time to finish. How can I do the processing asynchronously?
I found that the task queue service could do the trick, but I did not find an example.
Can anyone help?
Many thanks for your attention,
--Stefan

Similar Messages

  • How to process other task when reading the data from a file?

    Hello,
    I met a problem. I created a GUI to control the audio data processing. When the "Start" button is pressed, a block of data is read from the audio file and processed, then loop.But other buttons or method cannot be operated in that procession until all data is processed.
    How to let the other methods work under that circumstance? Should I use multiple threads?
    The relative code:
    SourceDataLine line;
    boolean stop = false;
    // When press "Start" button, the following method is invoked:
    public void play(){
    line.start();
    int bytesRead = 0;
    byte[] dataBuf = new byte[7500];
    while (bytesRead != -1& !stop)
    try
    bytesRead = audioInputStream.read(dataBuf, 0, dataBuf.length);
    catch (IOException e)
    e.printStackTrace();
    if (bytesRead >= 0)
    int bytesWritten = line.write(dataBuf, 0, bytesRead);
    line.drain();
    // When press "stop" button, this method is invoked.
    public void stop(){
    stop = true;
    line.stop();
    // When press "***" button, the following button is invoked:
    public void ***(){
    Many thanks.Looking forward to getting your answer.

    You have to use a seperate thread :
    Wheb you press the start button, you have to make sure a seperate thread is started :
    Thread runner = new Thread(){
    public void run(){
    //Here comes your code which reads the file
    runner.start();
    KR,
    Jan

  • How can I localize the text of process names, task names and user actions within a process?

    I'm very interested in using the capabilities of Adobe LiveCycle Process Management for my project, however I have one rather large concern...   I hope someone here can tell me whether there's a way to address it.
    Since I work for the Government of Canada, I have to meet certain requirements relating to bilingualism of the user interface.  It's my understanding that the Workspace portion of LiveCycle has already has support for French.
    But what about the design of my processes?  How can I display text to a user in the language of their choice when they're interacting with my processes? ... in particular, I'm thinking about the process name, task names, and user actions.
    I hope that this is possible without too much pain.  I imagine this must be a pretty common requirement!
    Thanks in advance to all who respond.

    You can completely change the content of whole pdf by using "renderPDFForm" operation under service "FormsService". in this operation there is Template category where you can set the Locale.
    And if you need to change the other workspace options like Complete, Save as Draft , you can then import workspace ui project and then change apppropriate values.
    Thanks,
    Prashast

  • Audition how to process tasks in parallel?

    Hi,
    I've to process some feature leght 5.1 mixes via "Stretch & Pitch process..." It will take up to 3h processing time per conversion but barely utilize my CPU or IO ressources.
    So I'm asking me how to run Audition multiple times and process them in parallel?
    Audition is designed as "Single Document Interface" SDI so it should run multiple times to process multiple tasks in parallel.
    In contrast a MDI "Multiple Document Interface" Application would only run in one instance but would allow to work on multiple projects in parallel.
    Hmm - how to get my work done fast and don't waste the ressouces of my fast workstation?

    Hello,
    Thanks. I am using JSF. I did not see some class that can process the request like in Struts in JSF. I am using Jdeveloper 10.1.3.0.3.
    And I have another question. I am trying to keep the user input,such as inputText1, in the page and change or delete that value in another page. To by pass the upper issue. I have set up the managed bean to be valid in the session such as Backing.Login. How could I access/change the value of the Backing.Login bean in other page's managed bean?
    Thanks,
    James

  • How to assign a task to Reuestor in OIM 11g

    How to assign a task to a requestor (who has raised a request for other user).
    I created a Task assignment adapter and mapped variable in Process definition as
    Map To: Request Info
    Qualifier: Requester User Login
    Still it returns null and default task is assigning to System adminstrator. I am pasting the Task Assignment code here. User key value coming as Null.
    Do you have any idea what is the exact mapping required in Process definition.?? Pls note: I am using OIM version 11.1.1.5.0
    public class TaskAssignmentToUserAdapter {
         Logger logger = Logger.getLogger("COM.IDM.PROV.COMMON.ADAPTERS");
         public String getTargetType(String targetType){
              return targetType;
         public String assignTaskToUser(String userKey,tcDataProvider dataProvider ){
              System.out.println("The user key value:" +userKey);
              return userKey;
         }

    Not sure what sample code I can give you, but you need to do a query in your adapter like:
    select REQUEST_KEY from OIU where ORC_KEY='?'
    Here ORC_KEY should be mapped to the process instance key.
    Once you have the Request key, you can use RequestServcie APIs to get the requester information. http://docs.oracle.com/cd/E14571_01/apirefs.1111/e17334/oracle/iam/request/api/RequestService.html#getBasicRequestData_java_lang_String_
    Or if you don't care then get the requester key from the request table. Thus you can have the final query as:
    select USR_LOGIN from USR where USR_KEY=(select REQUESTER_KEY from REQUEST where REQUEST_KEY = (select REQUEST_KEY from OIU where ORC_KEY='?'))
    HTH,
    BB

  • How to process one message at a time on a distributed queue

    I have a situation where I need to execute/process a task of a type
              asynchronously and this should be done one at a time. To do that I am thinking of setting
              up a distributed queue (for load balancing and failover). Now I have
              this requirement that only one task should be processed at one time. So
              for example if two messages (m1 followed by m2) are sent to distributed
              queue and I have the distributed queue which points to two physical
              queues on two different instances of weblogic(wl1 and wl2), the
              distributed queue will likely send m1 to wl1 and m2 to wl2 (assuming
              distributed queue is setup with round robin policy). If m1 has started
              executing/processing in my MDB on wl1, I do not want start processing
              m2 on wl2 untill m1 has been processed by wl1. Is it possible to do
              this on weblogic 8.1 JMS?
              If this is not supported I was thinking of implementing a database
              based locking framework and each mdb will use that framework to check
              if a task of a particular type is being processed before processing a
              new task. Also in this case I will need to use max. 1 mdb for each
              queue on each weblogic server.
              --Navjeet                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

    Hello navjeet,
              I don't think there are any parameters that you can set on a distributed queue to ensure messages are handled in the sequential manner you describe so it looks like you will have to implement your own locking mechanism.
              In reposponse to your other question you can set the number of MDbeans in the free pool to 1 (or the number of queues you have) in the MDBean deployment descriptor.
              see:
              http://e-docs.bea.com/wls/docs81/ejb/message_beans.html#1120592
              Cheers,
              Hoos

  • How to change the Task title on runtime?

    Hi experts again,
    My customer is struggling with something very simple: how to customize the Task title. You can certainly create an argument in the task, use Data Associations to map the argument, and then use XPath expression to get the value from the task payload and set it to the task title. That works fine. But it only executes once, when the process instance 'enters' in the task.
    So once the Task is created, you can see the custom title in the Workspace.
    Now, can we change the Title on runtime? I thought you could get the task payload, update the title and finally update the task but this does not seem to work. Here's the code that does it.
    In this example, the priority is updated successfully but not the title.
    FacesContext context = FacesContext.getCurrentInstance();
    String tskId = (String)context.getApplication().evaluateExpressionGet(context,
    "#{pageFlowScope.bpmWorklistTaskId}", String.class);
    IWorkflowServiceClient workflowSvcClient = WorkflowService.getWorkflowServiceClient();
    ITaskService taskSvc = workflowSvcClient .getTaskService();
    ITaskQueryService wfQueryService = workflowSvcClient.getTaskQueryService();
    IWorkflowContext wfContext = WorklistUtil.getWorkflowContextForASelectedTask();
    Task myTask;
    try {
    myTask = wfQueryService.getTaskDetailsById(wfContext, tskId);
    Element payloadElem = myTask.getPayloadAsElement();
    System.out.println("****************" + myTask.getTitle());
    System.out.println("****************" + myTask.getPriority());
    myTask.setTitle("Task Title 3");
    myTask.setPriority(2);
    myTask.setPayloadAsElement(payloadElem);
    taskSvc.updateTask(wfContext, myTask);
    } catch (Exception e) {
    e.printStackTrace();
    The results which printed out in console after execute above code twice.
    ****************Task Title 1
    ****************3
    ****************Task Title 1
    ****************2

    You can use the appropriately named Window Title property. In your project you can define conditional disable symbols (right-click on the project node and select Properties) and then use a conditional disable structure in your code. However, these symbols apply to the entire project, not to a specific executable. Thus, a better route would be to use the executable name (also accessible via a property), if possible, or some other distinction between the executables. What makes the executables different?

  • How to process records in a block without navigating (forms45)

    Hi.
    I use multi-record block with check boxes to allow operator select row they want to update. How can I process this task? Do I have to use:
    First_Record;
    loop
    when../*record doesn't exist */... exit;
    If /*checkbox selected */ then process_record
    end if
    Next_Record
    end loop
    But after that I have to navigate to the row I was before and I don't know how to do it.
    Or maybe (it would be much better) there is some way to silently process all rows in a block without employing the navigation process. Any advice?
    Thanks,
    Gregor

    DECLARE
    currentRecord number := get_block_property('YourBlock', CURRENT_RECORD);
    BEGIN
    First_Record;
    loop
    when../*record doesn't exist */... exit;
    If /*checkbox selected */ then process_record
    end if
    Next_Record
    end loop
    go_record(currentRecord);
    END;

  • How to Process a picture from a Camera to Labview

    I want to try and get a picture processed through Labview from a camera. For example I want to take a picture of a cup on a table and process it through Labview so that I can write a program for a robotic arm to pick up the cup from the table. I would like someone to advice me on how to process the picture from the camera and display it on Labview. Are there any examples in Labview, or the internet that can help put me in the right direction?  

    I would recommend starting small and have clear objectives in mind.  For example clearly define what you want your robot to do.  Do you want it to pick up "a" cup or anything that looks like a cup.   Things like learning algorithms, image processing, IMAQ, 3D motion control all come to mind.  These are subjects outside the scope of Labview but may be required in addition to understanding how to program your task in Labview.  There are dozens of examples in Labview on these subjects.  Take the task one step at a time and move from there.  It may also be helpful in the forum to give people an idea of your background.   If you are new to Labview this may be a very hard first program.  SS 

  • How to process large data files in XI  ?  100 MB files ?

    Hi All
       At present we have a scenario as follows
      It is File to IDoc ....Problem is the size of the file
      We need to transfer 100mb file to SAP R/3 system ? So this huge data how to
      process ?
    Adv thanx and regards
    Rakesh

    Hi,
    In general, an extra sizing for XI memory consumption is not required. The total memory of the SAP Web Application Server should be sufficient except in the case of large messages (>1MB).
    To determine the memory consumption for processing large messages, you can use the following rules of thumb:
    Allocate 3 MB per process (for example, the number of parallel messages per second may be an indicator)
    Allocate 4 kB per 1kB of message size in the asynchronous case or 9 kB per 1kB message size in the synchronous case
    Example: asynchronous concurrent processing of 10 messages with a size of 1MB requires 70 MB of memory
    (3MB + 4 * 1MB) * 10 = 70 MB With mapping or content-based routing where an internal representation of the message payload may be necessary, the memory requirements can be much higher (possibly exceeding 20 kBytes per 1kByte
    message, depending on the type of mapping).
    The size of the largest message thus depends mainly on the size of the available main memory. On a normal 32Bit operating system, there is an upper boundary of approximately 1.5 to 2 GByte per process, limiting the respective largest message size.
    please check these links..
    /community [original link is broken]:///people/michal.krawczyk2/blog/2006/06/08/xi-timeouts-timeouts-timeouts
    Input Flat File Size Determination
    /people/shabarish.vijayakumar/blog/2006/04/03/xi-in-the-role-of-a-ftp
    data packet size  - load from flat file
    How to upload a file of very huge size on to server.
    Please let me know , your problem is solved or not..
    Regards
    Chilla..

  • Triggering Process Definition Tasks Based on Changes to Multiple Attributes

    Hi All,
    I'm in the process of creating a custom GTC connector to provision accounts to an LDAP directory. I've got more than 100 user defined fields with the user object in OIM and about 60 of them will be kept in sync with the user accounts in LDAP. When any of these 60 attributes get updated for a user, I would like OIM to update the attributes for the user in LDAP.
    I know I can add 60 "Change <field name>" tasks to the process definition. However, that would be very inefficient for what I'm trying to do due to the number of attributes I'm dealing with. Often during large reconciliations from the systems of record, multiple attributes will change for each user. So if 20 attributes change for a user in one transaction and I have separate tasks for each attribute, that would result in 20 LDAP updates rather than just one.
    So I'm wondering, is there a way to have one process definition task that will trigger when any of these 60 attributes get updated and include all the attributes and values that got updated in that transaction?
    Thanks

    Thanks for your response.
    I was actually hoping to not have to use a process form to store all the user data for the LDAP provisioning connector. I was hoping to have the "Change" tasks update LDAP directly. The GTC framework seems to want to create a process form to store the target ID, but I would like to avoid storing all the user defined fields there. My reasoning for this is simply to avoid having user data duplicated in another location, which can often lead to sync issues. However, with that being said, if the only way I can gain performance improvements is through storing all the data in the process form, I would be willing to do that. Do you have any suggestions on how I can accomplish the single LDAP modify for multiple attributes without storing all the user defined fields in a process form?
    But in any case, I've attempted your suggestion. I have created a few lookup definitions:
    Code Key | Decode
    USR_LAST_NAME | Change Multiple
    USR_FIRST_NAME | Change Multiple
    USR_LOGIN | Change Multiple
    etc....
    I've then added the "Change Multiple" task to the process definition. That task calls an adapter called adpTESTGTC_GTC. Now if I update last name and first name in the same transaction, I notice that the adpTESTGTC_GTC adapter gets called twice. So it seems like even though there's just one "Change" task, it will still get executed once for each attribute modified. So adpTESTGTC_GTC would essentially be performing the same work for each attribute (that is getting all the user data and updating the process form). Since both LDAP and the Oracle Database are external to the application server, I'm guessing X LDAP modifies is just as bad for performance as X updates to the process form, where X is the number of attributes being updated in the transaction.
    kevin.pinsky wrote:
    When the update completes, if any of the fields change, it will trigger your "Updated" task on your form for that field.I'm also not sure I understand your last sentence. Are you suggesting that I have one "Updated" task for each attribute that's being sync'ed with LDAP? If that's the case, then I'm still doing multiple LDAP modifies for one transaction, right? In the end, my goal is for a reconciliation process that updates up to 60 attributes for a user to just make one LDAP modify with the up to 60 attributes being updated rather than having a separate LDAP modify for each attribute. So if a reconciliation process updates 20 attributes for a user in OIM, I would like a single LDAP modify to update the 20 attributes for the user in LDAP rather than having 20 LDAP modifies that each update one attribute.
    Thanks for your help. I would appreciate any further comments or suggestions.

  • How is Processing time calculated in Simulation

    Hi,
    How is processing time calculated for every simulation-relevant object?
    say for example,
    i have 2 objects of person type (p1 and p1)
    4 human tasks (T1, T2, T3, T4)
    T1 assigned to p1, processing time 2hrs
    T2 assigned to p1, processing time 2hrs
    T3 assigned to p2, processing time 2hrs
    T4 assigned to p2, processing time 2hrs
    start --&gt; T1(p1) --&gt; T2(p1) --&gt; T3(p2) --&gt; T4(p2) --&gt; end
    Have not set any other simualtion parameters. now,
    * Duration for simulation is set to 6hrs,
    T1, T2, and T3 are getting processes once, but start event is getting processed twice
    # Why is start event getting processed second time?
    # Will this take any processing time..
    * Duration for simulation set to 7hrs,
    start event and T1 gets processed 2 times, T2 and T3 once..
    and the total processing time becomes *8hrs*..
    # At wht point of time does the second processing of T1 start.
    # If it is not after after the completion of one full process cycle, in this case, why not the second processing start at the end # of 2nd hour, or 4th hour.
    Thanks,
    Vishnupriya

    Hi Vishnupriya,
    "Why is start event getting processed second time?"Can you check the "Frequency" attribute of your start event? There you can specify how often the process will be triggered.
    "At wht point of time does the second processing of T1 start."You should be able to check it in the Processes (det.). It provides an overview regarding the process instances started during the simulation run. Furthermore you can check the Events (det.) category.
    Best regards,
    Danilo

  • Orchestration Process Cleanup Task schedule job getting failed

    Hi All,
    We have an out of the box scheduled job "Orchestration Process Cleanup Task". This job is getting failed with the below error.
    "Failed.oracle.iam.platformservice.exception.OrchDataCleanupException:java.sql.SQLSyntaxErrorException:ora00913:too many values"
    This recon take two parameters in which we have given values as below:
    Batch size:100
    Delete Just One Batch: No
    I am not able to find how this job is configured or how it's deleting the values.
    Please help me out and if anyone know about the links where I can get the info on this job, it will be much helpful.
    Thanks
    Ishank

    As far as the
    http://docs.oracle.com/cd/E21764_01/doc.1111/e14308/scheduler.htm#r26c1-t8
    is concerned,
    Batch Size: Use this attribute to specify the number of completed orchestration processes to be deleted in each iteration.
    Delete Just One Batch: Use this attribute to specify the value true or false. Only a single batch is deleted if the value is true. All the completed events are deleted batch at a time in a loop if the value is false.
    So, let's try:
    Batch Size: 1 (just 1)
    Delete Just One Batch: yes (radio button)

  • Can't uninstall Premier Pro.  I keep getting messages to quit the Adobe QT32 Server and the dynamiclink manager.  I have no idea how to do these tasks?

    Can't uninstall Premier Pro.  I keep getting messages to quit the Adobe QT32 Server and the dynamiclink manager.  I have no idea how to do these tasks?

    You can kill these 2 task by opening the Windows Task manager (CTRL+ALT+SUPPR)
    Then find the processes named :
    Adobe QT32 Server
    Adobe Dynamic Link Manager
    Kill theses 2 tasks (right click then END OF TASK)
    If you got many of theses tasks, kill each.
    Then uninstall Premiere. It should be OK
    good luck
    noar

  • How to remove the tasks which are not manually recoverable?

    How to remove the tasks which are not manually recoverable?
    I tried performing manual recovery for the BPEL processes but there are few tasks which cant be manually recoverable..
    Could you please tell me how to remove those tasks and also tell me which information in the console is the task_id in the database?

    This article explains how to cleanup bpel process instances, you can find task instance id by searching for data in payload using api.
    Managing a BPEL Production Environment
    http://www.oracle.com/technology/pub/articles/bpel_cookbook/blanvalet.html
    Cheers,
    Rad

Maybe you are looking for

  • Moving from a PC to a Mac, and not everything in iTunes is coming with me

    I have my itunes music on a WD Passport drive, which my brand new MacBook recognized without a problem. However, it took a while for imports to be happy. I was expecting some glitches since I know the drive is formatted for Windows, so I was OK with

  • Question on adding LUNs to disk group

    GI version :11.2.0.3.0 Platform : OEL I need to add 2TB to the following disk group. Each LUN is 100gb in size. 100gb x 20 = 2 Tera Byte. Which means I have to run 20 commands like below SQL> ALTER DISKGROUP DATA_DG1 ADD DISK '/dev/sdc1' rebalance po

  • Write an ABAP program in BW which triggers an event in R/3

    Hello People Method: I need to create a Process Chain in BW for info package loading. In the PC, after the loading occurs, I need to write an ABAP program which has the FM: RSSM_EVENT _RAISE , which triggers a pre-defined event in R/3.  This event in

  • HELP! Illustrator crashing repeatedly after Maverick upgrade

    I have looked for plugins that might cause this but found none I have inserted the crash report. If anyone can help I would really appreciate it. Process:         Adobe Illustrator [1280] Path:            /Applications/Adobe Illustrator CC/Adobe Illu

  • Safari quits when trying to open website.

    Using Safari 3, I am able to open the application. When I try to access any website, the Safari unexpectedly quits every time. I thought about reinstalling Safari, but was unsure how to go about this without disrupting the rest of my Mac programs. An