I'm new to the builder enviroment. Trying to figure out how to add a call to web service after adding a new file to the system or after making a chnage in some file / folder.
my meaning is How can I automatically run a script or call a webservice when a user adds or modifies content within our Livelink system.
Look in the lliapi package area for NodeCallbacks.Most nodes and version will allow your module to orphan it and you can write custom code (oscript) to fire while it may be easier to call oscript livelink webservices by the same token I am not sure how easy it will be to consume a public webservice that is not part of the livelink code block.Simply put callbacks are pieces of code that gets fired on certain pre-defined events.For e.g addition of a node goes through a slew of processing commands
This is a smaple of callbacks you can use form documentation
ifdef DOC Description: Provides set system of callbacks for all LLNode objects. Each Registered Callback can specify a set of LLNode types that it wishes to be called for. The actions are specified below. Fields: fSubTypes - A list of subtypes that this callback should be used. If this value is undefined then the object will respond to all classes. The default value is {}. (specific nodes by subtype) fApplTypes - A list of application types and subtypes that this callback should respond to. (any node by application type) Methods: CBAddVersionPre - Called before a version is added to a node. CBAddVersionPost - Called after a version is added to a node.
Appu Nair, thanks you very much for the information.
I just need to understand few more things -
How can I orphan the DAPINodeCallback and override the CBUpdate & CBAddVersionPost functions ?
Do I have to create a new module for this and copy these functions with my changes to it ?
I have a client that allready made a call to an external webservice by creating ATTRAPI & WSClient Moduls, I just don't know exactly what he did over there, I can send you these moduls, maybe you'll be able to understand what he did there.
Your code changes will be in your own module.Have you done any builder stuff before?If you are willing to learn a lot of good people in this area will help you.I learned most of the stuff by experimenting myself and looking at work done by OpenText people.Consuming a websvcs meaning livelink Oscript has to call a websvc is not very easy as the only way I know it could be done is by
The oscript to java call is fairly starightforward as I remember posting a document when I suceeded in doing so.It was orginally written by another person with a different implementation method.
I can show you a simple call of a nodecall back if you would like to see one in a module as time permits.
I remember posting a user callback in this area for another user a while back.If budgets allow consider getting a freelancer or a good oscripter to do it for you as well baecuse this dev is fairly rusty for me as well.
Hi,
Thank you again for your support.
By now, I'm just trying to change to node callbacks, by changing the CBUpdate or CBCreate methods to print to a file (or do anything else which will give me any kind of indication) right after a new node was created or updated.
my questions are -
Do I need to create a new Ospace for it, and Orphan the CBUpdate and CPCreate methods to it ?
I read somewhere that I need to change the __Init methos as well. If so, what should I write over there ?
Is there anything else I should do in order to make it work ? I mean that after every new node creation, something will be writen into some log file.
when it'll work, I'll start dealing with calling to a SOAP Webservice instead of writing into a log file.
thanks,
Michael.
Attached is a custom module with some workflow event script code that I was doing.I added the node call backs you wanted and I write a simple statment to a log file under your logs folder.The __Init is usefui when you want certain things to happen on startup I beleive or I could be wrong.Anyways I did not have to do that in this.Now I restricted the .fsubtypes to be 0,144 so if you add a document /folder or update a document/folder you should see logs and as well an echo statement.First try to see if the module installs,I did it on 9.7.1 builder.
Here's the link to the module
https://knowledge.opentext.com/knowledge/llisapi.dll?func=ll&objId=19023710&objAction=download
To create modules I use the useful utilty called MakeNewModule