manifoldcf-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alessandro Benedetti <abenede...@apache.org>
Subject [Respository Connector] Connections
Date Wed, 13 May 2015 09:43:39 GMT
Hi guys,
just wondering around the pool of connections in a  repository connector.
In my Repo Connector I have a getSession method of this kind :

"*if (session == null) {*









*    ...    try {        session = new BoxSession(clientId,
clientSecret, username, password);    } catch (RuntimeException e) {
     throw new ManifoldCFException("[Box Session] Manifold Exception :
",e);    }...    lastSessionFetch = System.currentTimeMillis();}*"

This method is called in the :


   - processDocuments(...)
   - getDocumentVersions(...)
   - addSeedDocuments(...)
   - connect()
   - check()

Because of the null check, a new BoxSession will be created only one
time per Repository Connection ( I guess) .

In my Repository Connector configuration I set *"Max Connections" = 10.*

1)Does this mean that every time a Job involving that connector will
run, will open a max of 10 concurrent repository connections ?

2)Or this is extra job ? i.e. in the entire system, indepentendly of
how many jobs are there for that connector , we will have a total of N
Connections for that Repository ?

If I understood the documentation, I would say (2)

So if I execute the Job every 5 minutes, in an hour I will try to get
120 Box Session ?
If I understood well this should be the expected behaviour.
Can happen that actually we open much more sessions ?

Cheers


-- 
--------------------------

Benedetti Alessandro
Visiting card : http://about.me/alessandro_benedetti

"Tyger, tyger burning bright
In the forests of the night,
What immortal hand or eye
Could frame thy fearful symmetry?"

William Blake - Songs of Experience -1794 England

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message