The OSGi Specifications do not make any recommendation on this question – that is not their function.
But as I have commented in the bug, why would we have to enumerate all exported packages in the Export-Package header if exporting everything was intended to be the default? On Mon, 2 Dec 2019 at 15:50, BJ Hargrave <hargr...@us.ibm.com> wrote: > That advice is too broad. A bundle should export the package which are its > API. That is, the packages which users of the bundle need access to in > order to use the bundle. Packages which are implementation detail should > not be exported to properly encapsulate implementation detail. Some bundles > will export no packages since they are pure implementation. Some bundle are > pure API and thus will export all packages. But it is not true that all > bundles should export all packages. > > If every bundle exports all packages, then where is any modularity and > encapsulation of implementation detail? > -- > > BJ Hargrave > Senior Technical Staff Member, IBM // office: +1 386 848 1781 > OSGi Fellow and CTO of the OSGi Alliance // mobile: +1 386 848 3788 > hargr...@us.ibm.com > > > > ----- Original message ----- > From: Lars Vogel <lars.vo...@vogella.com> > Sent by: equinox-dev-boun...@eclipse.org > To: Equinox development mailing list <equinox-dev@eclipse.org> > Cc: > Subject: [EXTERNAL] [equinox-dev] Should OSGi bundles always export all > packages? > Date: Mon, Dec 2, 2019 10:31 > > Hi OSGi experts, > > In one of the Eclipse releases a warning was activated that a plugin > must exports all its packages. It is possible to change this for a > workspace but IMHO this new default is wrong. > > Plug-ins should not always export all packages as IMHO this defies the > purpose of a good module system. Internal stuff should be hidden. > > Can you clarify what the OSGi recommended way is? See > https://bugs.eclipse.org/bugs/show_bug.cgi?id=544977 > > Best regards, Lars > > -- > Eclipse Platform project co-lead > CEO vogella GmbH > > Haindaalwisch 17a, 22395 Hamburg > Amtsgericht Hamburg: HRB 127058 > Geschäftsführer: Lars Vogel, Jennifer Nerlich de Vogel > USt-IdNr.: DE284122352 > Fax (040) 5247 6322, Email: lars.vo...@vogella.com, Web: > http://www.vogella.com > _______________________________________________ > equinox-dev mailing list > equinox-dev@eclipse.org > To change your delivery options, retrieve your password, or unsubscribe > from this list, visit > https://www.eclipse.org/mailman/listinfo/equinox-dev > > > > _______________________________________________ > equinox-dev mailing list > equinox-dev@eclipse.org > To change your delivery options, retrieve your password, or unsubscribe > from this list, visit > https://www.eclipse.org/mailman/listinfo/equinox-dev
_______________________________________________ equinox-dev mailing list equinox-dev@eclipse.org To change your delivery options, retrieve your password, or unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/equinox-dev