OdiStartScen in async mode: variables lost in execution queue
I have the following case:
- a scenario must be called for each row in a database table
- this scenario has a variable, declared in the scenario parent package: variable values are read from the table
- rows are more than the "maximum number of sessions" for the agent
- execution of the scenarios should run in parallel
So I made a procedure, with only one step. The source command is something like "SELECT col1 alias1 FROM MyTable". The target command, on Sunopsis API, is OdiStartScen -SCEN_NAME=MyScenario "-GLOBAL.VAR1=#alias1"
When the procedure is executed by the agent, I have the following outcomes:
- if OdiStartScen is run synchronously (-SYNC_MODE=1): OK, no problem
- if OdiStartScen is run asynchronously (-SYNC_MODE=2) AND the number of rows in MyTable is less than the "Maximum number of sessions" set in Topology Manager for the executing agent: OK, no problem
- if OdiStartScen is run in async mode, and the number of rows in MyTable is greater then the maximum number of sessions, then the execution is OK only for the first rows of the table. Successive executions get enqueued, but when it's time for the agent to run them, Operator reports the followin error: "Variable has no value".
So it seems to me that variable values don't get enqueued, is it correct?
OK, my suggestion is:
It will be necessary add a new procedure at the process.
Create a new procedure and:
1) at 1º step:
Target Tab
Technology: javascript
code:
<@String vSS="";@>
2) 2º step
Source Tab:
Exact the same query, technology and Logical Schema as where the problem happens.
Target tab
Technology: javascript
code:
<@vSS+=" select 'OdiStartScen -SCEN_NAME=TESTPARALLEL -SCEN_VERSION=001 -SYNC_MODE=2 -GLOBAL.HOST=#p_host -GLOBAL.LAST_DATE=#p_last_date' as vComm from dual union";@>
*** VERY IMPORTANT: do not let any return carriage at the above command... probably it will appear into two lines at you screen but be sure that there is no return carriage character. I mean, the 2 lines are just because it can not be showed at just one.
3) 3º step
Target tab
Technology: javascript
code:
<@vSS=vSS.substring(0,vSS.length()-5);@>
4) now, a small change at your original procedure...
at the step where the select was done change the code to:
Source tab --> keep all but the code:
New code:
<@=vSS@>
Target tab --> keep all but the code:
New code:
#vComm
I believe that will solve the problem... I converted the parameters to strings then they do not need to exist as parameter at a new agent (balance)
obs.: Must be done in 2 procedures, because a javascript limitation.
Make any sense?
Please, try it and let me now... As I wrote the code with no ODI maybe could have some typed mistake, if you get any error let me now. (You can address me by my email at profile)
Edited by: Cezar Santos on 04/12/2008 16:52
Similar Messages
-
Diffrence b/w sync & async mode in bdc.
hi all,
wat is the diffrence b/w sync & async mode in bdc? plz explain interview point of view.
regards
deepakA Asynchronous updating. In this mode, the called transaction does not wait for any updates it produces to be completed. It simply passes the updates to the SAP update service. Asynchronous processing therefore usually results in faster execution of your data transfer program.
S Synchronous updating. In this mode, the called transaction waits for any updates that it produces to be completed. Execution is slower than with asynchronous updating because called transactions wait for updating to be completed. However, the called transaction is able to return any update error message that occurs to your program. It is much easier for you to analyze and recover from errors
one simple example : You are creating sales order from file and also you want to update header text of sales order.
when you want to update sales order header text,you need to use save_text function module ,here you need to pass sales order number.
when you use call transaction update 'A', data will update transaction level and it goes to the next record,here it will not wait for database .
when you use call transaction update 'S',data will update transaction level and it will update database then it goes next record.
if you want to update header text,then you need to use sync update
database commit -
comitt work - it will update data in database sucessfully
roll back - it will not update in database.
Thanks
Seshu -
I lost my iPhone 4 in Brussels last week. It was in airplane mode when lost. I also had a code to unlock the phone. The phone was off when lost. My question is: Can a person access my personal data on the phone? Can they take the chip out and place it into another iPhone and access the personal info on the chip or is the personal data on the phone itself and could they put a new chip in and access the data?
I have Find my iPhone App, but it says that it is offine.
I've checked all week and it is offline.
I clicked on erase iphone when phone accesses the internet on the Find my iPhone App.
I just want to know how safe is my personal information that I have on that iPhone? -
JUnit Test Debug: Static variable lost value!!!
Hi, I am writing JUnit code.
env: JDeveloper + JUnit Plugin + Selenium RC
While I am debugging, I found the static variable lost between 2 different test, I mean a test is a @Test, do somebody know why??
Thank you very much!!1.) The File you initialize in the method is not the same as the instance file variable that you initially initialized to null. You declared a new File in that method.
2.) Read about layout managers. The behavior you are seeing is because of the default layout manager's behavior. -
Always On - async mode - Failover and failback check list
Hi All,
Our production is configured with Always On in Async mode with DR.
We are planning to do a failover and failback on the Availability Groups in weekend.
Apart from the time consuming to do a failover and failback, does anyone having complete checklist on what all has to be checked at the time of failover and failback?
Thanks in advance!Hi MvKalyan,
In AlwaysOn Avaliability Groups, when availability replicas are configured for asynchronous-commit mode, it supports only the manual failover mode. For more details, please review this article:
Failover and Failover Modes (AlwaysOn Availability Groups).
Before performing a failover of SQL Server AlwaysOn Avaliability Group, there are several things should be considering, such as data loss, connectivity problems and so on. For more information, you can review this online blog:
Before You Fail Over a SQL Server AlwaysOn Availability Group.
Thanks,
Lydia Zhang -
Did 8.1 upgrade on iphone 4S, phone went to recovery mode and lost all data
Today October 26th I was prompted for 8.1 upgrade to fix minor bugs. Did 8.1 upgrade on my iphone 4S, phone went to recovery mode and lost all data. I see an itunes icon with a charger pointing to it on the screen. I plugged the pphone to the laptop and get is itunes detected iPhone in recovery mode, you must restart the phone before you update ...and the download is taking 5 hours and i have 320 mbps download speed
Apple thinks i have an older phone and need to throw it and buy their new iphone 6. if thats the case, here is my middle finger... am going with some other OSApple doesn't care if you buy a newer phone or not. Apple doesn't need your new iPhone purchase. There are millions of people that have properly working older iPhones that voluntarily upgrade.
Your device crashed, and it could have been caused by any number of root causes, many of them not controlled by Apple. Third party app, interruption of internet connection, interruption of power, etc.
If you came here to give the middle finger to Apple (childish behavior by the way), you're in the wrong place. Go to www.apple.com/feedback. -
How to reconnect to a database if connection is lost during execution
How to reconnect to a database if connection is lost during execution of the program.
Please help me.
thanks in advance.First close the old connection with "connection.close();" Catch all exceptions in case close() fails. Then open a new connection just like you opened the original one.
-
Design Pattern for execution queue
Anyone know of any good design patterns for using a JMS Queue and MDB's
as async
execution queue which maintains execution order by some key
Enforced ordering on redelivery will be supported in the
next release, but only if the application clamps the pipe-line
size down to its minimum and the MDB pool size down to one.
I don't think enforced ordering is supported in the current release.
We are looking at least partially addressing the general design
pattern below in the release after next. I don't think I can
get away with being more specific. (Sorry.) Currently, I
think something along the line of Larry's solution is the only way to
accomplish it. Interestingly, the recent thread started
by "[email protected]" on correlating requests and responses
seems to be somewhat related.
Tom, BEA
Larry Presswood wrote:
> Well you are both correct however we have something which works
> however it does involve some threading primitives which generally is not
> a good idea
> inside wlas but seems to work.
>
>
> Generally have a singleton on the server which has slots for each key
> with message
> numbering for each message and force a wait if message for key is out of
> order
> during fifo processing rules. IE do what things you can do in parallel
> but gate for
> the last step.
>
> I think there is a general remote execution pattern out there.
>
> The general problem to solve is this:
>
> In a messaging system you want to process messages for each key/session
> in order however
> with a large number of sessions its possible to parallel messages for
> different sessions
>
> Otherewise you can either create custom queues or a topic with a
> selector and then
> create custom consumers which does not behave as well from a resource
> perspective
> as MDB's do.
>
>
>
>
>
>
>
> Nick Minutello wrote:
>
>>I may be completely wrong - but I think that Larry is referring to the inherant
>>out-of-order message consumption that you get when using MDB pools to consume
>>from a Queue.
>>
>>In short, the only design pattern here is to deploy the MDB to only one machine
>>in the cluster - and set the pool size to 1.
>>
>>In-order execution is incompatible with the parallel execution that MDB's give
>>you.
>>
>>-Nick
>>
>>
>>
>>Tom Barnes <[email protected]> wrote:
>>
>>
>>>Hi Larry,
>>>
>>>Generally, I think it is best to have a seperate queue per key if the
>>>
>>>number of keys is small. This prevents starvation of a particular
>>>message. For example when handling message-priority, low priority gets
>>>
>>>an MDB pool of size 1, high priority gets and MDB pool of size 10.
>>>
>>>Note that WebLogic JMS allows a queue to specify a sort-order keys based
>>>on arbitrary message fields. Note that the in-flight message pipe-line
>>>
>>>between server and asynchronous clients is unsorted.
>>>
>>>Tom, BEA
>>>
>>>Larry Presswood wrote:
>>>
>>>
>>>>Anyone know of any good design patterns for using a JMS Queue and MDB's
>>>>
>>>>
>>>>as async
>>>>execution queue which maintains execution order by some key
>>>>
>>>>
>>>>
>>
>>
>>
>
-
Is it possible configuring an execution queue for a set of webservices?
Hi,
we have developed some webservices, writing normal methods and using servicegen to generate the webservices.
We expected there would be a generated web.xml with some servlets to receive the calls for the webservices. So we could configure the excecution queue in it, but there are no servlets. It's almost empty.
Is it possible configuring an execution queue for a webservice generated in this way?
Best regards.
Paco.Hi,
we have developed some webservices, writing normal methods and using servicegen to generate the webservices.
We expected there would be a generated web.xml with some servlets to receive the calls for the webservices. So we could configure the excecution queue in it, but there are no servlets. It's almost empty.
Is it possible configuring an execution queue for a webservice generated in this way?
Best regards.
Paco. -
SQL query with Bind variable with slower execution plan
I have a 'normal' sql select-insert statement (not using bind variable) and it yields the following execution plan:-
Execution Plan
0 INSERT STATEMENT Optimizer=CHOOSE (Cost=7 Card=1 Bytes=148)
1 0 HASH JOIN (Cost=7 Card=1 Bytes=148)
2 1 TABLE ACCESS (BY INDEX ROWID) OF 'TABLEA' (Cost=4 Card=1 Bytes=100)
3 2 INDEX (RANGE SCAN) OF 'TABLEA_IDX_2' (NON-UNIQUE) (Cost=3 Card=1)
4 1 INDEX (FAST FULL SCAN) OF 'TABLEB_IDX_003' (NON-UNIQUE)
(Cost=2 Card=135 Bytes=6480)
Statistics
0 recursive calls
18 db block gets
15558 consistent gets
47 physical reads
9896 redo size
423 bytes sent via SQL*Net to client
1095 bytes received via SQL*Net from client
3 SQL*Net roundtrips to/from client
1 sorts (memory)
0 sorts (disk)
55 rows processed
I have the same query but instead running using bind variable (I test it with both oracle form and SQL*plus), it takes considerably longer with a different execution plan:-
Execution Plan
0 INSERT STATEMENT Optimizer=CHOOSE (Cost=407 Card=1 Bytes=148)
1 0 TABLE ACCESS (BY INDEX ROWID) OF 'TABLEA' (Cost=3 Card=1 Bytes=100)
2 1 NESTED LOOPS (Cost=407 Card=1 Bytes=148)
3 2 INDEX (FAST FULL SCAN) OF TABLEB_IDX_003' (NON-UNIQUE) (Cost=2 Card=135 Bytes=6480)
4 2 INDEX (RANGE SCAN) OF 'TABLEA_IDX_2' (NON-UNIQUE) (Cost=2 Card=1)
Statistics
0 recursive calls
12 db block gets
3003199 consistent gets
54 physical reads
9448 redo size
423 bytes sent via SQL*Net to client
1258 bytes received via SQL*Net from client
3 SQL*Net roundtrips to/from client
1 sorts (memory)
0 sorts (disk)
55 rows processed
TABLEA has around 3million record while TABLEB has 300 records. Is there anyway I can improve the speed of the sql query with bind variable? I have DBA Access to the database
Regards
IvanMany thanks for your reply.
I have run the statistic already for the both tableA and tableB as well all the indexes associated with both table (using dbms_stats, I am on 9i db ) but not the indexed columns.
for table I use:-
begin
dbms_stats.gather_table_stats(ownname=> 'IVAN', tabname=> 'TABLEA', partname=> NULL);
end;
for index I use:-
begin
dbms_stats.gather_index_stats(ownname=> 'IVAN', indname=> 'TABLEB_IDX_003', partname=> NULL);
end;
Is it possible to show me a sample of how to collect statisc for INDEX columns stats?
regards
Ivan -
Hi can anyone please help. My I Phone is in recovery mode. I have loads of pics and vids including my little girl counting to ten for the first time.
Can I recover these files or have I lost them? I lost the phone last week and it was returned working but with an update to install I did this and it shut down.
If anyone can please help I would be eternally in your debt I have loads of sentimental pctures in here but cant get to them.Sorry, but if it's in recovery mode, anything on the phone is already gone. If you had PhotoStream turned on, hopefully the photos will still be out there.
You have no choice at this point but to restore from your last backup. -
How to connect computer and itunes locked mode is lost at the same time
when I have enough information and icloud
Lê Đức Anh wrote:
how to reboot when locked and in lost mode
If you put it into lost mode log in to https://icloud.com/find and erase the phone. If someone else put it into lost mode with their Apple ID and you do not know the passcode for their Apple ID account the phone is useless to you. -
Customer exit variables: order of execution
Hi,
I am using multiple customer exit variables. What determines the order the coding in ZXRSRU01 for these variables is executed ?
When I debug, the program always starts with the coding for one particular variable first, but can I depend on it that it stays this way ?
Regards,
GuidoHi Wodn,
Suppose I have 2 variables, both are called in I_STEP = 2. You write:
'the order of execution is based on the order of the variable which is being called'
Can you elaborate ? What exactely determines this ? Is it the order of the variables being used in the query (KF1 first, the KF2) ? I cannot find logic here.
Thanks for your reply.
Guido -
Changes to UEFI variables lost on reboot
I have a Toshiba L855-S5155 laptop which came with Windows 8 preinstalled in UEFI / Secure Boot mode.
I have since successfully installed Ubuntu 13.10.
My problem is that when I change the UEFI boot variables (such as to delete boot entries or change the boot order), they revert back to their previous values after the system reboots.
Methods:
Attempted to delete extra ubuntu entry in EFI variables.
#sudo efibootmbr -b 4 -B
Result:
#sudo efibootmbr
(No Boot0004 entry listed)
Problem
(Reboot system)
#sudo efibootmbr
(Boot0004 entry has returned)
Miscellaneous:
I have also attempted to use EasyBCD from within Windows 8 to delete this value with similar results.
Solved!
Go to Solution.I have since found out that the UEFI NVRAM is updated automatically on boot. I was able to resolve this problem by deleting the ubuntu folder on my efi partition and then putting it back.
I had a similar problem when transitioning to a new hard drive and the drive copy software didn't set the right flags on the new partitions. After changing the flags the system still wouldn't detect the operating systems until I manually updated the NVRAM using efibootmgr from a Live Linux USB. After that the bios automatically started recognizing entries in the EFI partitions. However, I had to boot into a Windows recovery shell and use bcdedit to fix the Windows boot loader. -
What happens if Local Mode LAP lost connection to Controller?
Hey,
I wonder what happens to the wireless client and LAP running in local mode if connection to wireless lan controller is down OR the controller itself is down? I do not think LAP will reboot by itself but will wireless client lost wifi connection and internet connection via the LAP?H-REAP/FlexConnect is different and it can keep clients connected depending on authentication methods. This will explain it better:
http://www.cisco.com/en/US/docs/wireless/controller/7.2/configuration/guide/cg_flexconnect.html#wp1224777
Sent from Cisco Technical Support iPhone App
Maybe you are looking for
-
Taking long time to load from the planning area to the cube since cvc big?
Hi all, We have a huge number of cvc for various countries, while we are planning to load the data from the planning area to the cube using those cvc it consuming 40 hours. I happneed to check the cvc are more than 15,000 that is one reason. But i st
-
I installed FireFox so I could take advantage of the TV-Fox add-on which is supposed to provide free television, so I can cancel my cable. But, as stated above, I got the following when I tried: TV-Fox could not be installed because it is not compati
-
Looking for a good database program
I have used Filemaker Pro in the past and have really liked using that program. Is there something out there but maybe a bit less pricey?
-
Urgent ( Case about USER EXIT)
I need to place a Botton in CN20J (Project Builder). How can I proceed, Can there are User Exit for this , If It is there Plz Try to Add a button to aopen an URL, I got aprocedure for URL. I need to place a button............ If possible Plz send the
-
How can I turn off Firefox remembering what I previously typed in a text box?
While using Firefox for Android, I have been noticing on Facebook, when I click a box to begin typing, it will bring up another box with past type entries I had typed out. It brings up a big clunky box full of tons of things I have said, and I want i