[Biocorba-l] Re: Migrating to biocorba 2
Brad Chapman
chapmanb@arches.uga.edu
Thu, 5 Apr 2001 22:26:50 -0400
Hi Harold, Jason;
Harold:
> 1) Is there a UML model of the interface? If not, I'd be glad to crank one
> out, but I don't want to spend time on something that has already been done.
This would be very worthwhile to have! To help out, I used synopsis
(http://synopsis.sourceforge.net), which can generate a UML diagram
from the IDL file which can be imported into Dia. After a bit of
hacking, I got it working, and prettied up what it spit out.
So here's a first attempt at some UML:
http://bioinformatics.org/bradstuff/bc/biocorba.dia
is the Dia formatted stuff, so you can load it up and play with it,
and:
http://bioinformatics.org/bradstuff/bc/biocorba.png
is just a pretty picture.
BTW, there are also the start of some biocorba specific docs linked to
from the BiopythonCorba wiki page:
http://biopython.org/wiki/html/BioPython/BiopythonCorba.html
They're kinda python biased, but they might be of some interest.
Harold:
> 3) The BioEnv interface _from_file interface talks about file names. Was it
> the intent of the spec to allow URL's? The reason that I'm asking is that,
> as the documentation mentions, file names make little sense across the net.
> Url's, however, have the potential of allowing one to make the BioEnv
> factory aware of all sorts of new information sources.
Jason:
> Hmm, I don't think so - But I think we are open to good arguments here. I
> can certainly see how it would be useful,
I think the purpose of the from_file stuff was just for local
files. If we want to support URLs, my preference would be to have a
separate from_url function. Otherwise, we get into the problem of
deciding what's a file, and what's a URL.
Harold:
> 5) GNOME root - Is this mechanism actually in place and behaving correctly?
> How well has it worked? Do all of the applications use it?
Well, both biopython and bioperl use this. For the stuff I've done
with a bioperl server and a biopython client, it seems to work well. I
call unref() when my python objects get deleted, and bioperl takes
care of things on its side decently. When I use a biopython server and
a biopython client in testing, I think I'm having problems releasing
the memory -- but I haven't been able to figure out how to fix this
yet. Once I loop over a lot of sequence (ie. the entire Arabidopsis
genome), I end up needing to kill the server and restart because all
of my free memory (256) is sucked up. Damn, I was so hoping python
garbage collection was going to take care of this for me!
So anyways, the ref stuff is sort of in place, but memory management
needs more work.
> Who calls ref() when a method returns an object reference - the caller or
> callee?
Callee (the server returning the object reference). I think it should
be assumed you are going to have a reference if you return an
object. The client then needs to be good enough to call unref when it
is done with it.
> Does a sequence manage the references on its elements?
> How are structures containing object references handled?
I don't think we are into this enough to be this fancy :-). In
general, the reference counting is supposed to be relatively simple,
and work for "most cases."
Alan might also be a good person to comment on this -- he has a
EMBL biocorba database set up, so he might have some good ideas how to
effectively manage things.
> Is it necessary for applications that create objects directly to still do
> reference counting?
I'm not sure what you mean here... but I think you only need to ref
count if you are worried about getting too many resources sucked
up.
> What is the policy regarding circular references?
Well, my policy is to pray that the python garbage collector is going
to take care of them :-). Of course, this hasn't been working great so
far...
Harold:
> 6) Are there strong feelings about using Java inheritence vs. delegation on
> inherited interfaces?
> 7) (Related to 6) Are there strong feelings about using the <class>_TIE
> approach vs. the <class>POA? While neither can be entirely transparent
Jason:
> I have only done the perl implementation so I think
> some of these are specific to the language implementation.
I'll have to agree with Jason, as I'm not very knowledgable in Java
beyond the very basics. In python, you don't have to muck with these
kind of problems because you can just rely on the ol' multiple
inheritence. So you probably know better than me what to do :-)
Harold:
> I realize that I'm an newbie to this world and a lot of these issues may
> have already been hashed out long ago. If so, feel free to point me at the
> FAQ so that I don't waste your own time.
Nah, it is definately *not* a waste of time -- sounds like you are
already getting ahead of me :-). Seriously, I hope my answers helped
some -- sorry to be so slow in getting back with you -- I've been
doing too much actual grad school work this week.
Jason:
> We are happy to have your CORBA expertise on board.
Agreed! I'm really happy that you are interested in picking up the
Java part of things. I'll be happy to help with python to java testing
once things start to get underway.
Thanks for the mail! Talk to you soon.
Brad