O'Reilly logo

Mastering Eclipse Plug-in Development by Dr. Alex Blewitt

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 6. Understanding ClassLoaders

In this chapter, we will look at how OSGi's use of ClassLoaders permits bundle separation, and what effect this has on libraries that mistakenly assume there is only one ClassLoader per JVM. We will cover the Java ServiceLoader and describe the problems and solutions it has in an OSGi framework. Finally, we will look at how to upgrade such libraries so that they are OSGi compatible.

Overview of ClassLoaders

One of JVM's biggest contributions to runtime loading has been the ClassLoader design and infrastructure. This allows a JVM to load the bytecode from arbitrary locations or even generate them on demand. It was this infrastructure that enabled Applets and Remote Method Invocation (RMI)—two key technologies ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required