Page 1 of 1

Third Party Integration over URL

PostPosted:Mon Aug 27, 2012 2:09 am
by b1nd
Hello Everybody,
Not quite sure whether this is the correct place for posting about this problem, sorry otherwise :)
I'm in the market for finding a solution KMS that will integrate with one of our database systems. I need to create a proof of concept in order to demonstrate whether OpenKMS will fit our requirements.
The requirements are as follows:
1) OpenKMS needs to be able to take parameters from a URL call from Third Party software (i.e 127.0.0.1?p1=x&p2=y&p3=z). Then, OpenKMS will have to create folders for each of them.
- I am able to write a script that takes an array of arguments, but have been having trouble using libraries to keep a script running permanently to listen for network packets.
or
2) OpenKMS needs to be able to read from from a text file that contains a batch of all these parameters.

Preference goes to 1) because it is a more centralised system and option 2) requires a middle-man application to convert these requests.

Any information on a solution or POF would be fantastic :)

Aside: Running Windows x64 machine (but am well versed in Linux if required)

Kind Regards
:)

Re: Third Party Integration over URL

PostPosted:Tue Aug 28, 2012 4:03 pm
by jllort
Obviously for doing it you should extend openkm actual features. Is not clear to me if you're going to have some security hole doing it, because anybody can build this url ... you have not talked about security ... I would like before give to you some idea you talk about it.

Re: Third Party Integration over URL

PostPosted:Thu Aug 30, 2012 8:08 am
by b1nd
Hey!
Firstly, thanks for the reply.
Secondly, security isn't a problem in this case. The string being passed will not be need to be private or secure, therefore there is not need for any encryption.
I simply just want to extend openKMS so that it listens for example on a socket for an incoming connection. Than upon a validated String, will create a directory within openKMS pertaining to that string.

:) Hope this helps

Re: Third Party Integration over URL

PostPosted:Fri Aug 31, 2012 10:36 am
by jllort
The most easiest way for doing it is add some jsp into OpenKM.war ( I suggest for doing tests in a non production environment !!!!, explode OpenKM.war into /server/default/deploy/OpenKM folder and delete OpenKM.war file ).

I suggest try create jsp file directly into /OpenKM folder into the jsp try something like
Code: Select all
import com.openkm.api.*;
import com.openkm.core.*;
import com.openkm.bean.*;
 
String token = JcrSessionManager.getInstance().getSystemToken();
System.out.println(token)
Then with this token you'll be able to make any operation across repository.

Re: Third Party Integration over URL

PostPosted:Tue Sep 04, 2012 2:20 am
by b1nd
Hey,
Thanks for the reply.
I'm actually running Windows version of OpenKMS atm and the directories are completely different.
Would you suggest running OpenKMS on Linux distro instead?

Also, I believe I'm going to have to reverse engineer the use of tokens throughout the WAR, because currently i have limited understanding on how to use these to integrate Socket networking and then how to parse this input into the system to create folders etc.

Any guidance on this would also be appreciated.

Kind Regards
Clint

Re: Third Party Integration over URL

PostPosted:Fri Sep 28, 2012 2:48 pm
by pavila
Linux offer best performance in the same hardware, so I can recommend it for server tasks.