[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [equinox-dev] Re:Can ActiveMQ be used together with OSGI?

Hi Jan and Wang,

FYI, we (ECF) have a JMS provider bundle that exports the (currently) geronimo_jms_1.1-rc4.jar JMS API impl (but would like to move to a more recent version of JMS API....geronimo or not).  The bundle is called org.eclipse.ecf.provider.jms and is located here:  http://ecf1.osuosl.org.  I would like to coordinate with whoever is appropriate to create a bundle exposing *just* the JMS API (javax.jms.*) for Orbit-based distribution:  http://www.eclipse.org/orbit.

We also have an old activemq-based bundle that we are using to implement an ActiveMQ ECF provider:  org.eclipse.ecf.provider.jms.activemq.  This bundle has all of the ActiveMQ libs (albeit old...3.5...versions of activemq) and depends upon org.eclipse.ecf.provider.jms.  Would like to see new version of activemq libs there also if we can manage it.

Please feel free to file bugs/enhancement requests here:  https://bugs.eclipse.org/bugs/enter_bug.cgi?product=ECF&bug_severity=enhancement

Thanks,

Scott


Jan Stette wrote:
To add to that: JMS is provided in the ActiveMQ distribution, specifically in the geronimo-jms_1.1_spec-1.0.jar file in the /lib directory.  So check that the bundle that contains ActiveMQ is exporting the javax.jms package.  Or, if the bundle where your code lives contains the ActiveMQ libraries directly, check that this jar file is on your bundle's classpath.

Jan

On 21/06/07, Stuart McCulloch <stuart.mcculloch@xxxxxxxxxx> wrote:
also, FYI - javax.jms is a J2EE API package which won't be in the base JDK, but is provided
by various J2EE implementations and the J2EE JDK... perhaps your Eclipse installation has
a plugin / feature that provides this package?


On 21/06/07, Stuart McCulloch < stuart.mcculloch@xxxxxxxxxx> wrote:
On 21/06/07, Wang Zhu <transitwang@xxxxxxxxx> wrote:
But I have import those things in my program:
import javax.jms.Connection;
import javax.jms.Destination;
import javax.jms.JMSException;
import javax.jms.Session;
import javax.jms.DeliveryMode;
import javax.jms.MessageProducer;
import javax.jms.TextMessage;
import org.apache.activemq.ActiveMQConnection;
import org.apache.activemq.ActiveMQConnectionFactory;
import org.apache.activemq.util.IndentPrinter;

There is a difference between imports at the Java language level, and imports between OSGi bundles.
 
For example, I may have a private internal class that uses another class - in this case I may need to
import it using a normal Java import (such as import com.example.MyClassImpl). But if both classes
are internal to the OSGi bundle then I don't need to mention them, or their packages, in the import or
export package instructions.

Think of Import-Package and Export-Package as describing wires between OSGi bundles - internally
your code will use Java-level imports, but as a bundle it needs to describe what classes it can share
with other bundles and what classes it needs from other bundles (or the framework).

If your bundle doesn't contain the javax.jms.* classes then they either need to come from the system
classpath, or another bundle.

    ( ps. you might want to look at the Bnd tool, which can produce OSGi metadata
      for you just by analyzing your classfiles - see http://www.aqute.biz/Code/Bnd )

hope this makes things a bit clearer...

Regards,
--
TransitWang/WangZhu
Computer School,Northwestern Polytechnical University

_______________________________________________
equinox-dev mailing list
equinox-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/equinox-dev




--
Cheers, Stuart



--
Cheers, Stuart

_______________________________________________
equinox-dev mailing list
equinox-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/equinox-dev



_______________________________________________ equinox-dev mailing list equinox-dev@xxxxxxxxxxx https://dev.eclipse.org/mailman/listinfo/equinox-dev