Focal Point Banner


As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.

Join the TIBCO Community
TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.

  • From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
  • Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
  • Request access to the private WebFOCUS User Group (login required) to network with fellow members.

Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.


Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [CLOSED] Running fex program parallely, Running two or more program together

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED] Running fex program parallely, Running two or more program together
 Login/Join
 
Gold member
posted
Is it POssible to run two or more fex program together, in any possible manner.

I have a main program main.fex in which i need to call 3 child program and i would like to excute these child program simultaneously so that it reduces the total time need for the whole report to complete. In usual manner we use -INCLUDE to include the child in main program, but this wouldn't run the program in parallel.

This message has been edited. Last edited by: Kerry,


WebFocus 5.2.5
HP-UX(UNIX)
EXCEL, HTML, PDF and OLAP
 
Posts: 50 | Registered: August 04, 2009Report This Post
Expert
posted Hide Post
By default you will not be able to run parts of the fex concurrently.

You will also be limited in what you can do with V5.2.5.

Why do you need these to be run concurrently ?, How long does it run ?

Is each part long running ?

Keep in mind, that if you are able to run multiple processes, there will need to be avaiable agents on the server.

Also do the three fexs supply data to the main.fex for later processing ?


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

 
Posts: 6347 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Report This Post
Gold member
posted Hide Post
The data size is huge more than 50K, and i suspect that the report will take huge time to complete. So to avoid that, it will be better if the report is run parallely for 10K each.


WebFocus 5.2.5
HP-UX(UNIX)
EXCEL, HTML, PDF and OLAP
 
Posts: 50 | Registered: August 04, 2009Report This Post
Expert
posted Hide Post
quote:
The data size is huge more than 50K


50,000 records ?


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

 
Posts: 6347 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Report This Post
Gold member
posted Hide Post
yes


WebFocus 5.2.5
HP-UX(UNIX)
EXCEL, HTML, PDF and OLAP
 
Posts: 50 | Registered: August 04, 2009Report This Post
Expert
posted Hide Post
50,000 isn't very large, and I would expect WebFOCUS on HP-UX would handle it quite easily.

Are you doing any complex joins with the data ?


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

 
Posts: 6347 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Report This Post
Guru
posted Hide Post
Run them simultaineously on Report Caster in different jobs. If they are long running, that is probably better anyway.


(Prod: WebFOCUS 7.7.03: Win 2008 & AIX hub/Servlet Mode; sub: AS/400 JDE; mostly Self Serve; DBs: Oracle, JDE, SQLServer; various output formats)
 
Posts: 391 | Location: California | Registered: April 14, 2003Report This Post
Expert
posted Hide Post
I've just spotted a function called SPAWN, that may do what you want.

Syntax is SPAWN(inlength, command, outcode)

Check it out in the documentation.

The call will be difficult, if 5.2.5 has it, as you will have to call edastart with either -f {script} or -x {focus command}.


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

 
Posts: 6347 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Report This Post
Master
posted Hide Post
Yes its possible using HTMLFORM and iframes. But in Internet explorer there is a limitation of 2 parallel execution, which can be modified in registry. http://support.microsoft.com/kb/282402
 
Posts: 542 | Location: Dearborn, MI | Registered: June 03, 2009Report This Post
<JG>
posted
The problem with SPAWN is that it can only be called from a DEFINE or COMPUTE
so it's not going help MKS's problem.

What MKS does not say if the 3 called procedures are generating 3 outputs
or if they are processing to supply data for the "whole report"

If it’s the 1st then it’s not possible as an edastart session cannot return output to a browser.

The major issue with parallel running is that you must wait for all to complete before you can finalize
The output.
This means that they need to be executed with a loop that checks for completion of each
Component.

The only real way to do this is via an edastart –f passing it a script or edastart –x passing it a command
And you must remember that these will not generate output to the browser they can only generate hold files.

What’s more there are a number of issues that you need to take into account.

1. edastart -f/-x do not execute any profiles e.g. site.wfs, edasprof.prf etc.

2. They will use the directory from where the edastart is called as the ‘edatemp’ directory
so you must ensure that unique names are used for any hold files.

3. They will not know any variables that have been set in the parent procedure;
they must be passed via the calling process if you want to use them.

As Waz says 50K rows is peanuts from a WebFOCUS perspective, unless you are using ridiculous
Cross platform JOINs.

My advice is, the pain and aggravation associated with trying to do this is so great don’t bother trying.
 
Report This Post
Virtuoso
posted Hide Post
"Is it possible to run two or more fex program together, in any possible manner."

Is this to run online (with the eventual output directed to the browser) -- or batch (scheduled in Reportcaster)?

For an online report, here is a method I used several years ago.

Have the "parent" fex return an initial html page, which on load submits N forms, one for each of the "child" fexes, to run them in parallel. That allows them to run in parallel, on individual "agents" in WFRS. Each of those N forms directs its output to a separate iframe in the initial page, which (on load) runs a function located in the parent document. That function bumps a counter, and if the counter has reached N submits a request to run the final report fex, which utilizes the outputs of the child processes and produces the final output (replacing the initial html page)

Essentially, the initial html page is acting as a controller (which is why this method cannot work in batch), initiating all the parallel processes, and allowing the last one in to turn on the lights.

The child proceeses have to be designed so that
(a) their output remains accessible to the final report exec;
(b) they operate independently of each other; and
(c) multiple users can exercise this structure without interfering with each other.
-- but that is true in any event.

This message has been edited. Last edited by: j.gross,


- Jack Gross
WF through 8.1.05
 
Posts: 1925 | Location: NYC | In FOCUS since 1983 | Registered: January 11, 2005Report This Post
<JG>
posted
quote:
But in Internet explorer there is a limitation of 2 parallel execution


Ram, "That's not entirely correct" (Sorry just re-watched Independance Day).

The limit is on the number of parallel downloads to the browser, not the requests to generate the downloads.
If you have multiple iFrames requesting data it will take the first 2 or 6 as default for download
then automatically download the next 2 or 6 (browser version dependant).

Jack, Hidden iFrame approach + script counter. Never thought of that.
Now that Foccache is available, That's got to be much more viable and easy.
 
Report This Post
Virtuoso
posted Hide Post
In development I kept the frames small but visible, which allowed access to the echo of each child process fex.

It's still subject to the browser's timeout limits; but at least you can identify which horse never finished.
 
Posts: 1925 | Location: NYC | In FOCUS since 1983 | Registered: January 11, 2005Report This Post
Gold member
posted Hide Post
This is not a online report, reports are generated in hold files. and each of the program creates different output with different hold file name.

JG's suggestion on using edastart -f looks promising. Can you please explain a little more on it?


WebFocus 5.2.5
HP-UX(UNIX)
EXCEL, HTML, PDF and OLAP
 
Posts: 50 | Registered: August 04, 2009Report This Post
Gold member
posted Hide Post
Used "nohup" to run several edastart in background, by creating separate fex program for each edastart running in background.


WebFocus 5.2.5
HP-UX(UNIX)
EXCEL, HTML, PDF and OLAP
 
Posts: 50 | Registered: August 04, 2009Report This Post
Guru
posted Hide Post
Going for two ReportCaster scheduler Jobs, will be one quite easy option I guess...

Or You can write a Batch or Shell or any OS Native script to run two or more procs at single point in time.


Thanks,

Ramkumar.
WebFOCUS/Tableau
Webfocus 8 / 7.7.02
Unix, Windows
HTML/PDF/EXCEL/AHTML/XML/HTML5
 
Posts: 394 | Location: Chennai | Registered: December 02, 2009Report This Post
Gold member
posted Hide Post
I have now new trouble with this. Since using TABLE FILE, I am getting some error as below

04/21/2011 07:42:10 u=abcd, pid=8544: errmes: "baserr: ERROR page number 1, hfoc_flags = 0, flags = 1"
04/21/2011 07:42:10 u=abcd, pid=8544: errmes: "ERRNO code = 2 No such file or directory"
04/21/2011 07:42:10 u=abcd, pid=8544: errmes: " 6010784768 bytes free "
04/21/2011 07:42:10 u=abcd, pid=8544: errmes: "error in basrd: read error: FOCSORT "
04/21/2011 07:42:21 u=abcd, pid=8546: errmes: "Error accessing FOCUS file /abcd/wf_temp/test/conf1/focsort.foc, FOCUS name FOC
SORT "
04/21/2011 07:42:21 u=abcd, pid=8546: errmes: "baserr: ERROR page number 1, hfoc_flags = 0, flags = 1"
04/21/2011 07:42:21 u=abcd, pid=8546: errmes: "ERRNO code = 2 No such file or directory"
04/21/2011 07:42:21 u=abcd, pid=8546: errmes: " 6010784768 bytes free "
04/21/2011 07:42:21 u=abcd, pid=8546: errmes: "error in basrd: read error: FOCSORT "

It Looks like the FOCSORT file is getting rewritten for each parallel process.


WebFocus 5.2.5
HP-UX(UNIX)
EXCEL, HTML, PDF and OLAP
 
Posts: 50 | Registered: August 04, 2009Report This Post
<JG>
posted
quote:
It Looks like the FOCSORT file is getting rewritten for each parallel process.
Quite correct.
If you are starting multiple processes then you must make sure that each one has it's own workspace (edatemp).
 
Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [CLOSED] Running fex program parallely, Running two or more program together

Copyright © 1996-2020 Information Builders