Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.java.programmer > #29499
| Path | csiph.com!usenet.pasdenom.info!aioe.org!eternal-september.org!feeder.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail |
|---|---|
| From | Martin Gregorie <martin@address-in-sig.invalid> |
| Newsgroups | comp.lang.java.programmer |
| Subject | Re: dealing with ClassLoaders... |
| Date | Fri, 1 Aug 2014 21:45:10 +0000 (UTC) |
| Organization | A noiseless patient Spider |
| Lines | 35 |
| Message-ID | <lrh1p6$de7$1@dont-email.me> (permalink) |
| References | <slrnltl6t2.fp3.avl@login.logic.tuwien.ac.at> <lre9rv$mnu$1@dont-email.me> <slrnltn8l2.fp3.avl@login.logic.tuwien.ac.at> <slrnlto0hg.fp3.avl@login.logic.tuwien.ac.at> |
| Mime-Version | 1.0 |
| Content-Type | text/plain; charset=UTF-8 |
| Content-Transfer-Encoding | 8bit |
| Injection-Date | Fri, 1 Aug 2014 21:45:10 +0000 (UTC) |
| Injection-Info | mx05.eternal-september.org; posting-host="e5160e2be48f1ea550cf61512446f525"; logging-data="13767"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18XNzjguj2mnF4puP04bJ5k7lCMvk/WbZA=" |
| User-Agent | Pan/0.139 (Sexual Chocolate; GIT bf56508 git://git.gnome.org/pan2) |
| Cancel-Lock | sha1:LyVsD1A1Kyd1yVxc0dizimcncxk= |
| Xref | csiph.com comp.lang.java.programmer:29499 |
Show key headers only | View raw
On Fri, 01 Aug 2014 21:10:07 +0000, Andreas Leitgeb wrote:
> Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> wrote:
>> Martin Gregorie <martin@address-in-sig.invalid> wrote:
>>> public class MAClassLoader extends ClassLoader {
>> [ no snip ]
>>> }
>>> I hope this is useful info.
>
> On further examination, I think it isn't as simple as that. Essentially,
> this "empty" ClassLoader-subclass would pass everything through to the
> parent classloader (or the pre-
> mordial one, absent a parent) and thus not be associated to any of the
> classes loaded through it, thus provide no isolation at all.
>
Your requirements would seem to be as bit different from mine, which were
purely to package a number of programs (some Swing apps, some pure
command-line apps, all accessing a single PostgreSQL database instance)
into one convenient file and to be able to run them without needing to
unpack the distribution file. There is almost never any need to run more
than one of these programs at a time by any user/on any PC. So, as none
of these ever share a JVM the most convenient way to do this was to pack
them all into a jar file and use that very simple class loader as a way
to select and run one of the programs in it. I do not have any of the
your process isolation requirements which is why I can get away with such
a simple class loader. Once the top level class defining the program to
be run has been loaded I don't care what class loader is used to pull in
the other classes it needs - in fact I'd be surprised if the default
class loader *wasn't* used for that.
--
martin@ | Martin Gregorie
gregorie. | Essex, UK
org |
Back to comp.lang.java.programmer | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
dealing with ClassLoaders... Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2014-07-31 19:40 +0000
Re: dealing with ClassLoaders... Martin Gregorie <martin@address-in-sig.invalid> - 2014-07-31 20:44 +0000
Re: dealing with ClassLoaders... Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2014-08-01 14:22 +0000
Re: dealing with ClassLoaders... Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2014-08-01 21:10 +0000
Re: dealing with ClassLoaders... Eric Sosman <esosman@comcast-dot-net.invalid> - 2014-08-01 17:32 -0400
Re: dealing with ClassLoaders... Joerg Meier <joergmmeier@arcor.de> - 2014-08-02 01:21 +0200
Re: dealing with ClassLoaders... Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2014-08-02 00:00 +0000
Re: dealing with ClassLoaders... Martin Gregorie <martin@address-in-sig.invalid> - 2014-08-01 21:45 +0000
Re: dealing with ClassLoaders... Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2014-08-01 23:14 +0000
Re: dealing with ClassLoaders... Martin Gregorie <martin@address-in-sig.invalid> - 2014-08-02 00:35 +0000
Re: dealing with ClassLoaders... Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2014-08-05 15:38 +0000
Re: dealing with ClassLoaders... Silvio <silvio@internet.com> - 2014-08-01 13:31 +0200
Re: dealing with ClassLoaders... Silvio <silvio@internet.com> - 2014-08-01 13:37 +0200
Re: dealing with ClassLoaders... Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2014-08-01 16:06 +0000
Re: dealing with ClassLoaders... "Chris Uppal" <chris.uppal@metagnostic.REMOVE-THIS.org> - 2014-08-01 13:19 +0100
Re: dealing with ClassLoaders... Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2014-08-01 15:51 +0000
Re: dealing with ClassLoaders... Josip Almasi <joe@vrspace.org> - 2014-08-01 15:55 +0200
Re: dealing with ClassLoaders... Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2014-08-04 15:12 +0000
Re: dealing with ClassLoaders... Mike Amling <mamling@chaff.us> - 2014-08-04 19:53 -0500
Re: dealing with ClassLoaders... Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2014-08-05 15:16 +0000
Re: dealing with ClassLoaders... Josip Almasi <joe@vrspace.org> - 2014-08-08 11:53 +0200
Re: dealing with ClassLoaders... Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2014-08-08 18:46 +0000
Re: dealing with ClassLoaders... Josip Almasi <joe@vrspace.org> - 2014-08-10 13:22 +0200
Re: dealing with ClassLoaders... Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2014-08-12 17:16 +0000
csiph-web