Hi...
This is probably (hopefully) a newbie question. I have a need for
multiple instances of a service, that codewise are identical but have
different runtime configurations -- names, files accessed, etc. So my
thought was to create a service factory that kicked off as many
instances of the
=...MyImpl
property name=prop1 value=value2/
/instance
/ipojo
At runtime, you will have two instances with different properties. The
service will be published by the two instances.
Regards,
Clement
2010/4/28 Holger Hoffstätte holger.hoffstae...@googlemail.com
Donald Whytock wrote
Actually...
Properties props = new Properties();
props.put(name, name);
props.put(prop1, context.getProperty(messagequeue. + name + .prop1));
context.registerService
(
MessageQueueService.class.getName(),
new MessageQueueImpl(props),
props);
On Wed, Apr 28, 2010 at 9:38 AM, Donald Whytock
I wound up having to create a factory in bundle.b that's an extension
of a class in bundle.a. The bundle.b subclass would override a method
for providing an instantiation of the desired class. I had to
instantiate the factory in bundle.b and pass it to bundle.a. That
lets bundle.a crank out the
Remote shell, perhaps?
Don
On Sun, May 9, 2010 at 2:19 AM, Kent Tong k...@cpttm.org.mo wrote:
Hi,
What is the best way to start a bundle installed in Felix from a Java program
running in another JVM (not a bundle)?
Thanks!
hell.
Hope this helps, kind regards,
? ? ? ?Peter Kriens
On 6 mei 2010, at 22:33, Donald Whytock wrote:
I wound up having to create a factory in bundle.b that's an extension
of a class in bundle.a. ?The bundle.b subclass would override a method
for providing an instantiation
a difference at some point, to
where it's better to consolidate a bunch of bundles into one for
runtime efficiency?
Don
2010/5/11 Donald Whytock dwhyt...@gmail.com:
Actually, after a week of playing with it, I find I have something
similar to the ManagedServiceFactory principle.
You're right
If ListenerThread implements Runnable, the way to start it is
ListenerThread listener = new ListenerThread(39000);
new Thread(listener).start();
according to the API:
http://java.sun.com/javase/6/docs/api/java/lang/Thread.html
The start() method only works with extensions of Thread.
Don
On
Hi...Trying to extend ServiceTracker rather than use a
ServiceTrackerCustomizer, but when I try new ServiceTracker(context,
filter, null) I get a Cannot Find Symbol for constructor
ServiceTracker(BundleContext, String, nullable).
The ServiceTracker javadoc talks about what happens if the
)
{ super(context, clazz, custom); }
That compiled, but at runtime it gave me a NullPointerException when
instantiating the ShellTracker.
On Fri, Jun 25, 2010 at 12:57 PM, Richard S. Hall he...@ungoverned.org wrote:
On 6/25/10 12:50, Donald Whytock wrote:
Hi...Trying to extend ServiceTracker rather
:
Is your context argument != null ?
On Fri, Jun 25, 2010 at 7:21 PM, Donald Whytock dwhyt...@gmail.com wrote:
One of the ServiceTracker constructors takes a Filter, but not a
filter String. Still, it shouldn't complain at compile time about
(BundleContext, String, null) as parameters regardless
projects. This helps with
quickly getting to the build and execution stage.
cheers,
-Nima
On Fri, Sep 10, 2010 at 8:52 AM, Donald Whytock dwhyt...@gmail.com wrote:
A few months back I'd thought about submitting my Chatterbot project
to the incubator. Now that I have a fully functional prototype
Quick-start version up now at
http://www.imtower.net/chatterbot/doku.php?id=download
largely ripped from the conf and felix-cache folders. Source code up soon.
Don
On Fri, Sep 10, 2010 at 5:36 PM, Donald Whytock dwhyt...@gmail.com wrote:
Haven't worked with maven before, but I can throw
Would the main() typically be instantiating the class? If so, since
the class would be instantiated at activation, wouldn't this be
doubling memory?
How about gutting the main() and putting the functionality in a method
that both start() and main() would then call?
On Thu, Sep 23, 2010 at 5:29
I'll build it that way. Thanks!
Don
On Tue, Oct 5, 2010 at 3:04 PM, Richard S. Hall he...@ungoverned.org wrote:
On 10/5/10 14:58, Donald Whytock wrote:
I'm using the objectClass along with another property, yes. Currently
the bundles generate services of a particular class and add a name
This may be what was meant by the Fragment suggestion earlier, but...
Include the bundle in a wrapper bundle, include the bundle in the
wrapper's Bundle-ClassPath, export everything in the bundle,
instantiate the bundle's activator in the wrapper's activator? Then
you'd certainly have the
Hi all...
I'd like to execute felix shell commands from inside a bundle. Used
to was, that was done with org.apache.felix.shell.ShellService. I
assume it's done now using
org.apache.felix.service.command.CommandSession, fetched from
org.apache.felix.service.command.CommandProcessor.
But I
:
You have to import it with status=provisional, since the Gogo API is based
on unreleased OSGi API, so it will change in the future and we are warning
you about this by making the status attribute mandatory.
- richard
On 4/4/11 17:17, Donald Whytock wrote:
Hi all...
I'd like to execute felix
,org.osgi.servi
ce.startlevel;version=1.1,org.osgi.util.tracker;version=1.3
That looks pretty similar, no?
- richard
On 4/4/11 17:30, Donald Whytock wrote:
Okay, I've tried the following:
org.apache.felix.service.command;status=provisional;version=0.8.0
and on load it comes up with missing
Might be nice for things like Gogo.
On Fri, Apr 8, 2011 at 4:37 PM, John Robinson jsro...@gmail.com wrote:
I was really looking for the implementation specific Java docs so that when
working on Felix specific tutorials, I can walk easily from the Eclipse IDE
to the associated JavaDocs.
On
Yes, Dual Screen. Felix for GameBoy, with new stylus interface for gogo.
On Mon, May 23, 2011 at 9:24 AM, sam lee skyn...@gmail.com wrote:
What's DS? Dual Screen? Declarative Service? Dynamic Service?
On Mon, May 23, 2011 at 8:44 AM, Peter Kriens peter.kri...@aqute.bizwrote:
It is the
It can be made sort of pluggable. There are jars that have OSGi
activators and manifests that handle all the OSGi-specific
functionality and are otherwise ignored when the jar's used outside of
OSGi.
A couple things you need to pay attention to:
- Thread control. Just because you stop a bundle
Do you absolutely need the statistics bundle to run in a Felix
framework? Or could you just include the bundle's .jar on your
classpath, instantiate the service object and run the method directly?
Don
On Tue, Jun 21, 2011 at 6:31 PM, Justin Stoecker jstoecker...@gmail.com wrote:
Hi,
I have a
on other bundles, all of which I could use directly, but it
would be desirable and/or interesting for learning purposes.
Justin
On Tue, Jun 21, 2011 at 6:36 PM, Donald Whytock dwhyt...@gmail.com wrote:
Do you absolutely need the statistics bundle to run in a Felix
framework? Or could you just
Hi all...
I'm having a problem with JavaMail running under Felix.
I have a simple application that fetches a
multipart/alternative-type email from a POP3 server. If I run this
application standalone, I see the message correctly, with its content
as class MimeMultipart. If I run this
What about something like
File file = new File(bundle.getResource(file name inside bundle).toURI());
with bundle being the bundle you want the file from?
No, I haven't tried it yet. :)
Don
On Fri, Jul 8, 2011 at 3:19 PM, Richard S. Hall he...@ungoverned.org wrote:
On 7/8/11 15:02, Shamik
My experience with OSGi/Felix is comparatively limited compared to
some, but I think I'm making good use of its fundamental capability:
hot-swapping components.
My app is a framework for hooking a varying number of command
interpreters to a varying number of communication components, thus
I tend to use basic OSGi and the Gogo interface, though one of my
command interpreters emulates Gogo commands, so that I can configure
through Jabber or email if needed. I might expand this to handle
emailing the system bundle jars to install or update.
Don
That should mean refreshing bundle 0 refreshes everything, right?
On Fri, Aug 12, 2011 at 12:36 PM, Richard S. Hall he...@ungoverned.org wrote:
On 8/12/11 12:32, Jim Talbut wrote:
No I didn't.
How does that work with existing instantiated objects?
When you refresh a bundle, any bundles that
Hi all...
I've been having a problem with method overrides in Felix.
Generalized scenario:
Two bundles: BundleA and BundleB.
BundleB's ActivatorB extends BundleA's ActivatorA. ActivatorB does
not define a start() method.
BundleB's ServiceImplB extends BundleA's ServiceImplA.
ActivatorA is
When BundleB is started, ActivatorA.start() instantiates and starts an
extension of ServiceTracker, myServiceTracker.
myServiceTracker.addingReference() calls getServiceImpl() for a
ServiceImpA and calls showStatus() on it.
If ServiceImplB.showStatus() calls super.showStatus(),
Unable to reproduce the problem today. Maybe all that time I was just
short by a refresh.
Thanks anyway for the help...
Don
On Wed, Aug 17, 2011 at 11:41 AM, Donald Whytock dwhyt...@gmail.com wrote:
When BundleB is started, ActivatorA.start() instantiates and starts an
extension
What you probably want in the long run is a datasource-generating
service, to which you pass the database URI. You can put things in
the properties of the service to indicate whether it's Oracle, mySQL,
MSSQL, etc., so that you can have multiple generating services at the
same time.
Don
On Wed, Mar 21, 2012 at 12:17 PM, Christian Schneider
ch...@die-schneider.net wrote:
I also wondered if I should start writing something like this. The problem
is that DataSources and in the same way jms ConnectionFactories are
configured
very differently. It is not only a url and usernam,
Might I suggest:
GET_ONE: name=foo
GET_ALL: name=all
services: (|(name=name)(name=all))
Don
On Wed, May 16, 2012 at 1:40 PM, Tim Moloney tim.molo...@gmail.com wrote:
I am having trouble figuring out how to implement the following using the
whiteboard pattern.
There are several services
Sorry...a little more of an inline response:
Scenario 1
- All services are registered according to their function
- GET_ALL also registered as a StatusListener with *no* service properties
- GET_ONE also registered as a StatusListener with name=foo service
property
- When sending status,
36 matches
Mail list logo