× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



I played around with the API's listed at:
http://doc.notes.net/AS400/5.0.9/readas4.nsf/1bce3bc9bebd3a848525619e00767b22/adcb8583366e199c86256ae9007919ea?OpenDocument

a couple examples can be found at:
http://www.ibm.com/servers/eserver/iseries/domino/devtools/dominoapi/dominoapi.htm


Not being a real big fan of using CL to access API's I rewrote it in RPGLE.
Well, actually my skeleton doesn't do what some of the examples do, such as
shutting down the servers, verifying they're down, etc.  But it does get
the offsets right and all that.  Using the logic from their examples is
simple after that.

DSPSRVPGM QNOTES/QNNINLDS
shows
Procedure Name
QnninListDominoServers
QnninRtvDominoServerI
QnninRtvDominoServerAttr
QnninUpdateServerType

I read the documentation for, and use:
QnninListDominoServers
QnninRtvDominoServerI

I wonder what the other two do.

Here is my sample, it produces no useful output, except in debug.

     H Bnddir('ROUTINES/SRVPGM':'QC2LE':'ROUTINES/DOMSYNC')
     H ActGrp('QILE')
     H DftActGrp(*NO)
     H Datfmt(*USA)
     H Copyright('(C) Copyright Group Dekko Services, LLC')
     H ExprOpts(*RESDECPOS)


***************************************************************************
      * Program:
*
      *
*
      *
*
      * Modification log:
*
      * mm/dd/00 by R.Berendt, CCP    Group Dekko Services, LLC
*
      *          Created.
*
      *
*
      * Compilation instructions:
*
      *   (no special instructions this time.)
*
      *
*

***************************************************************************


      /DEFINE DSpec
     D ListDomSvrs     PR                  extproc
('QnninListDominoServers')
     D  RecVar                             like(LDS)
     D  RecVarLen                    10i 0 CONST
     D  FormatName                    8a   CONST
     D  ErrorCode                          LIKE(ERRC0100)

     D RtvDomSvr       PR                  extproc('QnninRtvDominoServerI')
     D  RecVar                             like(RDS)
     D  RecVarLen                    10i 0 CONST
     D  ServerNm                           like(ServerName) CONST
     D  ServerNmL                    10i 0 CONST
     D  ErrorCode                          LIKE(ERRC0100)

      * LDS=Data Structure for QnninListDominoServers
     D LDS             DS          9999    qualified
     D  BytesRet                     10i 0
     D  BytesAvl                     10i 0
     D  SvrOff                       10i 0
     D  NbrSvr                       10i 0
     D  LenSvr                       10i 0

     D CurSvrOff       s             10i 0
     D ServerName      s            255a

      * RDS=Data Structure for QnninRtvDominoServerI
     D RDS             DS          9999    qualified
     D  BytesRet                     10i 0
     D  BytesAvl                     10i 0
     D  PriDom                       10i 0
     D*  0 - Unknown Domino server type
     D*  1 - Domino server
     D*  2 - Stand alone QuickPlace server
     D*  3 - Stand alone SameTime server
     D  SecDom                       10i 0
     D*  0 - No additional capabilities.
     D*  1 - Also a QuickPlace server
     D*  2 - Also a SameTime server
     D*  3 - Also a QuickPlace AND SameTime server
     D  SbsJobs                      10i 0
     D  DataOff                      10i 0
     D  DataLen                      10i 0
     D  ExeOff                       10i 0
     D  ExeLen                       10i 0
     D  SbsDesc                      20a
     D  LibName                      10a

     D DataDir         s           1000a
     D ExeDir          s           1000a

     D x               s             10i 0

      /COPY ROUTINES/QRPGLESRC,SRVPGMCPY
      /UNDEFINE DSpec

      /free
       callp ListDomSvrs(lds:%len(lds):'DSRV0100':ERRC0100);
       CurSvrOff=lds.SvrOff + 1;

       For x=1 to lds.NbrSvr;
        ServerName=%subst(LDS:CurSvrOff:lds.LenSvr);
        callp
RtvDomSvr(rds:%len(rds):ServerName:%len(ServerName):ERRC0100);
        DataDir=%subst(rds:rds.DataOff+1:rds.DataLen);
        ExeDir=%subst(rds:rds.ExeOff+1:rds.ExeLen);
        CurSvrOff=CurSvrOff+lds.LenSvr;
       EndFor;
       *inlr=*on;
       return;
      /end-free

Rob Berendt
--
"They that can give up essential liberty to obtain a little temporary
safety deserve neither liberty nor safety."
Benjamin Franklin




As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.