phweb question specific to vms - solved
Daniel.Miller@nightfreight.co.uk
Daniel.Miller@nightfreight.co.uk
Mon, 5 Jul 2004 15:05:46 +0100
This is a multi-part message in MIME format.
------_=_NextPart_001_01C46299.2B5060BA
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
ok, i know what im thinking of now. the SERVER PROCESS TIMEOUT under =
dispatcher properties does actually wait for processes to finish but the =
CONNECTION TIMEOUT under the phwebserver properties doesnt, that =
deliberately kills off processes since they could be hung in a loop etc.
=20
So ive added a clean up at the start of each screen, ive added an extra =
CLOSE on the file and a DELETESYSTEMVAL. Appears to work ok so far, =
difficult to test the situation its needed in.
-----Original Message-----
From: powerh-l-admin@lists.sowder.com =
[mailto:powerh-l-admin@lists.sowder.com]On Behalf Of Miller, Daniel
Sent: Monday, July 05, 2004 2:41 PM
To: powerh-l@sowder.com
Subject: RE: phweb question specific to vms - solved
some answers below:
-----Original Message-----
From: Joe Boyle [mailto:joeboyle_adt@hotmail.com]
Sent: Monday, July 05, 2004 2:06 PM
To: Miller, Daniel; powerh-l@sowder.com
Subject: RE: phweb question specific to vms - solved
GREAT code :-)
but just a couple of points,
1. am really surprised that "LNM$PROCESS" worked, I seem to recall =
nearly always having to use "LNM$JOB".[Miller, Daniel] with normal ph =
ive always used job logicals, you can get in a right mess with process =
ones because they are passed to subprocesses only on creation of the =
subprocess and then you have the problem of subprocesses for RUN =
COMMAND / dcl hanging around. However with phweb all the phwebservers =
are subprocesses under the dispatcher and are part of the same job, i =
dont want the logicals getting mixed up with the wrong phwebservers.=20
2. to address's Chris's point on large directories, you might aswell go =
the whole hog and create a directory to put the file in.[Miller, Daniel] =
i have a test and live dispatcher with their own login directories =
which is currently were all these files will go, i definilty need to =
think about this some more. thanks Chris
3. I still think it would be better to pass the file string as a temp, =
and do a deletesystemval followed by a setsystemval in the postpath in =
every screen. As Bob says you could find that the PHwebwserver refresh =
has kicked in, or some other form of interruption.[Miller, Daniel] i =
will try the deletesystemval it cant do any harm, i was under the =
impression a phwebserver wouldnt get refreshed while it was busy =
processing. I guess im wrong about that, dont where i got that idea from =
anyway.=20
4. how about adding the getsystemval, you could compare it with the =
setsystemval string, and if there is not a match, error out to the =
previous/higher page.
5. to diagnose any future logical setting related problems, you could =
always put 'sho logical string* /full' in a command file, run it from =
the PHweb page and then analyse the results on the server.
many thanks for supplying the solution,
>From: <Daniel.Miller@nightfreight.co.uk>=20
>To: <powerh-l@sowder.com>=20
>Subject: RE: phweb question specific to vms - solved=20
>Date: Mon, 5 Jul 2004 11:52:18 +0100=20
>=20
>hi there,=20
>=20
>I asked the original question and it has indeed turned out to be a =
problem with CLOSE which i think is now solved. Ive been using the =
CLOSE verb rather than the file statement option, sorry didnt see that =
would probably have sorted it too.=20
>=20
>What concerned me most was that setting process level logicals in phweb =
might be a dangerous or unreliable technique but it does appear to work. =
>=20
>The problem has turned out to be my second screen which had CLOSE's in =
the EXIT procedure, which is working since i moved them to the POSTFIND =
procedure instead. The HTMLFILECLOSE didnt seem to make any difference. =
>=20
>=20
>=20
>Heres a cut down sample anyway of the two programs anyway:=20
>=20
>=20
>Page DM html application DM_APP activities ENTRY, FIND=20
>=20
>Htmlbuttons "Add" label "Search", "Reset" label "Clear"=20
>=20
>=20
>Temp T_FILE_NO num*8=20
>Temp T_PARM_NO num*8=20
>=20
>=20
>File PHWEB-PARMS-CONTROL designer=20
>=20
>File PHWEB-PARMS designer=20
>Access via PARM-NO using T_PARM_NO=20
>=20
>Temp T-COMMAND char*240=20
>=20
>=20
>=20
>;*** Temporary item fields here where user can enter part of an address =
***=20
>=20
>Field T_FILE_NO htmlhidden=20
>Field T_PARM_NO htmlhidden=20
>=20
>Nextpage DM2 after update &=20
> application DM_APP action "Search" passing T_FILE_NO, =
T_PARM_NO=20
>=20
>=20
>Procedure internal GET-PARM-NO=20
>Begin=20
> Lock PHWEB-PARMS-CONTROL=20
> Get PHWEB-PARMS-CONTROL via NF-LINK using "NF"=20
>=20
> Let T_FILE_NO =3D FILE-NO of PHWEB-PARMS-CONTROL=20
>=20
> If FILE-NO of PHWEB-PARMS-CONTROL < 99999999=20
> Then let FILE-NO of PHWEB-PARMS-CONTROL =3D &=20
> FILE-NO of PHWEB-PARMS-CONTROL =
+ 1=20
> Else let FILE-NO of PHWEB-PARMS-CONTROL =3D 1=20
>=20
> Put PHWEB-PARMS-CONTROL reset=20
> Unlock PHWEB-PARMS-CONTROL=20
> Close PHWEB-PARMS-CONTROL=20
>=20
> If not setsystemval("PHWEB-PARMS", "PHWEB-PARMS" &=20
> + ascii(T_FILE_NO,8) + ".TMP", =
LOGICAL)=20
> Then info " "=20
> Let T-COMMAND =3D "CREATE/FDL=3DNFD:PHWEB-PARMS.FDL =
PHWEB-PARMS" &=20
> + ascii(T_FILE_NO,8) + =
".TMP"=20
> Run command T-COMMAND=20
> Let T_PARM_NO =3D 1=20
>End=20
>=20
>Procedure preupdate=20
>Begin=20
> Do internal GET-PARM-NO=20
>=20
> ; extra processing to "put" to PHWEB-PARMS here:=20
> ; Passes temporary fields to an external procedure which =
returns=20
> ; a list of matching addresses, those addresses are then added =
to=20
> ; PHWEB-PARMS=20
>=20
> Close PHWEB-PARMS=20
> If not deletesystemval("PHWEB-PARMS", LOGICAL, "LNM$PROCESS")=20
> Then info " "=20
>End=20
>=20
>=20
>=20
>can clear=20
>Set Ver Err=20
>Set html buttons off=20
>=20
>Page DM2 html application DM_APP &=20
> htmltitle "Address Search Results" &=20
> htmlreceiving T_FILE_NO, T_PARM_NO &=20
> activities FIND=20
>=20
>Temp T_FILE_NO num*8=20
>Temp T_PARM_NO num*8=20
>=20
>File PHWEB-PARMS primary occurs 50=20
>Access via PARM-NO using T_PARM_NO=20
>=20
>=20
>Field T_FILE_NO htmlhidden=20
>Field T_PARM_NO htmlhidden=20
>=20
>Cluster occurs with PHWEB-PARMS=20
>=20
>; *** address data from PHWEB-PARMS is displayed here ***=20
>=20
>Cluster=20
>=20
>Procedure POSTPATH=20
>Begin=20
> If not setsystemval("PHWEB-PARMS", "PHWEB-PARMS" &=20
> + ascii(T_FILE_NO,8) + ".TMP", =
LOGICAL)=20
> Then info " "=20
>End=20
>=20
>;Procedure EXIT=20
>Procedure POSTFIND=20
>Begin=20
> Close PHWEB-PARMS=20
> If not deletesystemval("PHWEB-PARMS", LOGICAL, "LNM$PROCESS")=20
> Then info " "=20
>End=20
>=20
>=20
>=3D =3D =3D =3D =3D =3D =3D =3D =3D =3D =3D =3D =3D =3D =3D =3D =3D =3D =
=3D =3D =3D =3D =3D =3D =3D =3D =3D =3D=20
>Mailing list: powerh-l@lists.sowder.com=20
>Subscribe: "subscribe" in message body to =
powerh-l-request@lists.sowder.com=20
>Unsubscribe: "unsubscribe <password>" in message body to =
powerh-l-request@lists.sowder.com=20
>http://lists.sowder.com/mailman/listinfo/powerh-l=20
>This list is closed, thus to post to the list you must be a subscriber. =
------_=_NextPart_001_01C46299.2B5060BA
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 5.00.2314.1000" name=3DGENERATOR></HEAD>
<BODY>
<DIV><FONT color=3D#0000ff face=3DArial size=3D2><SPAN =
class=3D950505313-05072004>ok, i=20
know what im thinking of now. the SERVER PROCESS TIMEOUT under =
dispatcher=20
properties does actually wait for processes to finish but the CONNECTION =
TIMEOUT=20
under the phwebserver properties doesnt, that deliberately kills off =
processes=20
since they could be hung in a loop etc.</SPAN></FONT></DIV>
<DIV><FONT color=3D#0000ff face=3DArial size=3D2><SPAN=20
class=3D950505313-05072004></SPAN></FONT> </DIV>
<DIV><FONT color=3D#0000ff face=3DArial size=3D2><SPAN =
class=3D950505313-05072004>So ive=20
added a clean up at the start of each screen, ive added an extra CLOSE =
on the=20
file and a DELETESYSTEMVAL. Appears to work ok so far, difficult =
to test=20
the situation its needed in.</SPAN></FONT></DIV>
<BLOCKQUOTE style=3D"MARGIN-RIGHT: 0px">
<DIV align=3Dleft class=3DOutlookMessageHeader dir=3Dltr><FONT =
face=3DTahoma=20
size=3D2>-----Original Message-----<BR><B>From:</B>=20
powerh-l-admin@lists.sowder.com =
[mailto:powerh-l-admin@lists.sowder.com]<B>On=20
Behalf Of </B>Miller, Daniel<BR><B>Sent:</B> Monday, July 05, 2004 =
2:41=20
PM<BR><B>To:</B> powerh-l@sowder.com<BR><B>Subject:</B> RE: phweb =
question=20
specific to vms - solved<BR><BR></DIV></FONT>
<DIV><FONT color=3D#0000ff face=3DArial size=3D2><SPAN =
class=3D630053013-05072004>some=20
answers below:</SPAN></FONT></DIV>
<BLOCKQUOTE style=3D"MARGIN-RIGHT: 0px">
<DIV align=3Dleft class=3DOutlookMessageHeader dir=3Dltr><FONT =
face=3DTahoma=20
size=3D2>-----Original Message-----<BR><B>From:</B> Joe Boyle=20
[mailto:joeboyle_adt@hotmail.com]<BR><B>Sent:</B> Monday, July 05, =
2004 2:06=20
PM<BR><B>To:</B> Miller, Daniel; =
powerh-l@sowder.com<BR><B>Subject:</B> RE:=20
phweb question specific to vms - solved<BR><BR></DIV></FONT>
<DIV>
<DIV class=3DRTE>
<P>GREAT code :-)</P>
<P>but just a couple of points,</P>
<P>1. am really surprised that "LNM$PROCESS" worked, I =
seem to=20
recall nearly always having to use "LNM$JOB".<FONT color=3D#0000ff =
face=3DArial=20
size=3D2><SPAN class=3D630053013-05072004>[Miller, Daniel] =
with normal ph=20
ive always used job logicals, you can get in a right mess with =
process ones=20
because they are passed to subprocesses only on creation of the =
subprocess=20
and then you have the problem of subprocesses for RUN =
COMMAND /=20
dcl hanging around. However with phweb all the phwebservers =
are=20
subprocesses under the dispatcher and are part of the same job, =
i=20
dont want the logicals getting mixed up with the wrong=20
phwebservers. </SPAN></FONT></P>
<P>2. to address's Chris's point on large directories, you might =
aswell go=20
the whole hog and create a directory to put the file in.<FONT =
color=3D#0000ff=20
face=3DArial size=3D2><SPAN class=3D630053013-05072004>[Miller, =
Daniel] i=20
have a test and live dispatcher with their own login directories =
which is=20
currently were all these files will go, i definilty need to think =
about this=20
some more. thanks Chris</SPAN></FONT></P>
<P>3. I still think it would be better to pass the file =
string as=20
a temp, and do a deletesystemval followed by a setsystemval in =
the=20
postpath in every screen. As Bob says you could find that the=20
PHwebwserver refresh has kicked in, or some other form of =
interruption.<SPAN=20
class=3D630053013-05072004><FONT color=3D#0000ff face=3DArial =
size=3D2>[Miller,=20
Daniel] i will try the deletesystemval it cant do any =
harm, i=20
was under the impression a phwebserver wouldnt get refreshed =
while it=20
was busy processing. I guess im wrong about that, dont where i got =
that idea=20
from anyway. </FONT></SPAN><BR><BR>4. how about adding the=20
getsystemval, you could compare it with the setsystemval string, and =
if=20
there is not a match, error out to the previous/higher page.</P>
<P>5. to diagnose any future logical setting related problems, you =
could=20
always put 'sho logical string* /full' in a command file, run it =
from the=20
PHweb page and then analyse the results on the server.</P>
<P>many thanks for supplying the solution,</P></DIV>
<DIV></DIV>>From: <Daniel.Miller@nightfreight.co.uk>=20
<DIV></DIV>>To: <powerh-l@sowder.com>=20
<DIV></DIV>>Subject: RE: phweb question specific to vms - solved=20
<DIV></DIV>>Date: Mon, 5 Jul 2004 11:52:18 +0100=20
<DIV></DIV>>=20
<DIV></DIV>>hi there,=20
<DIV></DIV>>=20
<DIV></DIV>>I asked the original question and it has indeed =
turned out to=20
be a problem with CLOSE which i think is now solved. Ive =
been=20
using the CLOSE verb rather than the file statement option, sorry =
didnt see=20
that would probably have sorted it too.=20
<DIV></DIV>>=20
<DIV></DIV>>What concerned me most was that setting process level =
logicals in phweb might be a dangerous or unreliable technique but =
it does=20
appear to work.=20
<DIV></DIV>>=20
<DIV></DIV>>The problem has turned out to be my second screen =
which had=20
CLOSE's in the EXIT procedure, which is working since i moved them =
to the=20
POSTFIND procedure instead. The HTMLFILECLOSE didnt seem =
to make=20
any difference.=20
<DIV></DIV>>=20
<DIV></DIV>>=20
<DIV></DIV>>=20
<DIV></DIV>>Heres a cut down sample anyway of the two programs =
anyway:=20
<DIV></DIV>>=20
<DIV></DIV>>=20
<DIV></DIV>>Page DM html application DM_APP activities ENTRY, =
FIND=20
<DIV></DIV>>=20
<DIV></DIV>>Htmlbuttons "Add" label "Search", "Reset" label =
"Clear"=20
<DIV></DIV>>=20
<DIV></DIV>>=20
<DIV></DIV>>Temp T_FILE_NO num*8=20
<DIV></DIV>>Temp T_PARM_NO num*8=20
<DIV></DIV>>=20
<DIV></DIV>>=20
<DIV></DIV>>File PHWEB-PARMS-CONTROL designer=20
<DIV></DIV>>=20
<DIV></DIV>>File PHWEB-PARMS designer=20
<DIV></DIV>>Access via PARM-NO using T_PARM_NO=20
<DIV></DIV>>=20
<DIV></DIV>>Temp T-COMMAND char*240=20
<DIV></DIV>>=20
<DIV></DIV>>=20
<DIV></DIV>>=20
<DIV></DIV>>;*** Temporary item fields here where user can enter =
part of=20
an address ***=20
<DIV></DIV>>=20
<DIV></DIV>>Field=20
T_FILE_NO htmlhidden =
<DIV></DIV>>Field=20
T_PARM_NO htmlhidden =
<DIV></DIV>>=20
<DIV></DIV>>Nextpage DM2 after update &=20
<DIV></DIV>> =
application=20
DM_APP action "Search" passing T_FILE_NO, T_PARM_NO=20
<DIV></DIV>>=20
<DIV></DIV>>=20
<DIV></DIV>>Procedure internal GET-PARM-NO=20
<DIV></DIV>>Begin=20
<DIV></DIV>> Lock =
PHWEB-PARMS-CONTROL=20
<DIV></DIV>> Get=20
PHWEB-PARMS-CONTROL via NF-LINK using "NF"=20
<DIV></DIV>>=20
<DIV></DIV>> Let=20
T_FILE_NO =3D FILE-NO of PHWEB-PARMS-CONTROL=20
<DIV></DIV>>=20
<DIV></DIV>> If =
FILE-NO=20
of PHWEB-PARMS-CONTROL < 99999999=20
<DIV></DIV>> Then =
let=20
FILE-NO of PHWEB-PARMS-CONTROL =3D &=20
=
<DIV></DIV>> &nbs=
p;  =
; =
=20
FILE-NO of PHWEB-PARMS-CONTROL + 1=20
<DIV></DIV>> Else =
let=20
FILE-NO of PHWEB-PARMS-CONTROL =3D 1=20
<DIV></DIV>>=20
<DIV></DIV>> Put=20
PHWEB-PARMS-CONTROL reset=20
<DIV></DIV>> =
Unlock=20
PHWEB-PARMS-CONTROL=20
<DIV></DIV>> =
Close=20
PHWEB-PARMS-CONTROL=20
<DIV></DIV>>=20
<DIV></DIV>> If =
not=20
setsystemval("PHWEB-PARMS", "PHWEB-PARMS" &=20
=
<DIV></DIV>> &nbs=
p;  =
; =20
+ ascii(T_FILE_NO,8) + ".TMP", LOGICAL)=20
<DIV></DIV>> Then =
info "=20
"=20
<DIV></DIV>> Let=20
T-COMMAND =3D "CREATE/FDL=3DNFD:PHWEB-PARMS.FDL PHWEB-PARMS" &=20
=
<DIV></DIV>> &nbs=
p;  =
; =
&=
nbsp; =20
+ ascii(T_FILE_NO,8) + ".TMP"=20
<DIV></DIV>> Run =
command=20
T-COMMAND=20
<DIV></DIV>> Let=20
T_PARM_NO =3D 1=20
<DIV></DIV>>End=20
<DIV></DIV>>=20
<DIV></DIV>>Procedure preupdate=20
<DIV></DIV>>Begin=20
<DIV></DIV>> Do =
internal=20
GET-PARM-NO=20
<DIV></DIV>>=20
<DIV></DIV>> ; =
extra=20
processing to "put" to PHWEB-PARMS here:=20
<DIV></DIV>> ; =
Passes=20
temporary fields to an external procedure which returns=20
<DIV></DIV>> ; a =
list of=20
matching addresses, those addresses are then added to=20
<DIV></DIV>> ;=20
PHWEB-PARMS=20
<DIV></DIV>>=20
<DIV></DIV>> =
Close=20
PHWEB-PARMS=20
<DIV></DIV>> If =
not=20
deletesystemval("PHWEB-PARMS", LOGICAL, "LNM$PROCESS")=20
<DIV></DIV>> Then =
info "=20
"=20
<DIV></DIV>>End=20
<DIV></DIV>>=20
<DIV></DIV>>=20
<DIV></DIV>>=20
<DIV></DIV>>can clear=20
<DIV></DIV>>Set Ver Err=20
<DIV></DIV>>Set html buttons off=20
<DIV></DIV>>=20
<DIV></DIV>>Page DM2 html application DM_APP &=20
=
<DIV></DIV>> &nbs=
p; =20
htmltitle "Address Search Results" &=20
=
<DIV></DIV>> &nbs=
p; =20
htmlreceiving T_FILE_NO, T_PARM_NO &=20
=
<DIV></DIV>> &nbs=
p; =20
activities FIND=20
<DIV></DIV>>=20
<DIV></DIV>>Temp T_FILE_NO num*8=20
<DIV></DIV>>Temp T_PARM_NO num*8=20
<DIV></DIV>>=20
<DIV></DIV>>File PHWEB-PARMS primary occurs 50=20
<DIV></DIV>>Access via PARM-NO using T_PARM_NO=20
<DIV></DIV>>=20
<DIV></DIV>>=20
<DIV></DIV>>Field T_FILE_NO htmlhidden=20
<DIV></DIV>>Field T_PARM_NO htmlhidden=20
<DIV></DIV>>=20
<DIV></DIV>>Cluster occurs with PHWEB-PARMS=20
<DIV></DIV>>=20
<DIV></DIV>>; *** address data from PHWEB-PARMS is displayed here =
***=20
<DIV></DIV>>=20
<DIV></DIV>>Cluster=20
<DIV></DIV>>=20
<DIV></DIV>>Procedure POSTPATH=20
<DIV></DIV>>Begin=20
<DIV></DIV>> If =
not=20
setsystemval("PHWEB-PARMS", "PHWEB-PARMS" &=20
=
<DIV></DIV>> &nbs=
p;  =
; =20
+ ascii(T_FILE_NO,8) + ".TMP", LOGICAL)=20
<DIV></DIV>> Then =
info "=20
"=20
<DIV></DIV>>End=20
<DIV></DIV>>=20
<DIV></DIV>>;Procedure EXIT=20
<DIV></DIV>>Procedure POSTFIND=20
<DIV></DIV>>Begin=20
<DIV></DIV>> =
Close=20
PHWEB-PARMS=20
<DIV></DIV>> If =
not=20
deletesystemval("PHWEB-PARMS", LOGICAL, "LNM$PROCESS")=20
<DIV></DIV>> Then =
info "=20
"=20
<DIV></DIV>>End=20
<DIV></DIV>>=20
<DIV></DIV>>=20
<DIV></DIV>>=3D =3D =3D =3D =3D =3D =3D =3D =3D =3D =3D =3D =3D =
=3D =3D =3D =3D =3D =3D =3D =3D =3D =3D =3D =3D =3D =3D =3D=20
<DIV></DIV>>Mailing list: powerh-l@lists.sowder.com=20
<DIV></DIV>>Subscribe: "subscribe" in message body to=20
powerh-l-request@lists.sowder.com=20
<DIV></DIV>>Unsubscribe: "unsubscribe <password>" in =
message body=20
to powerh-l-request@lists.sowder.com=20
<DIV></DIV>>http://lists.sowder.com/mailman/listinfo/powerh-l=20
<DIV></DIV>>This list is closed, thus to post to the list you =
must be a=20
subscriber.=20
<DIV></DIV></DIV></BLOCKQUOTE></BLOCKQUOTE></BODY></HTML>
------_=_NextPart_001_01C46299.2B5060BA--