Can a Chrome extension run or access an external jar file

2,716 views
Skip to first unread message

Owen Bell

unread,
Jan 3, 2011, 12:09:35 AM1/3/11
to Chromium-extensions
I am currently building an extension for Chrome designed to sync
browser state across multiple computers. An equivalent extension has
already been built in Firefox that creates a string and passes it to a
jar file (using its api) which then serves as the communicator between
the different computers. I am currently trying to implement an
extension in Chrome to interface with this same jar. I have, however,
not discovered any documentation on how I would go about doing this or
if it is even possible and was hoping that I could get clarification
and assistance with this.

PhistucK

unread,
Jan 4, 2011, 1:13:43 PM1/4/11
to Owen Bell, Chromium-extensions
You cannot natively synchronize data between several instances of an extension yet.
You will either have to use a server (and a user name\password\openID or similar for each user) for that, or use the bookmark API (in case the user has enabled the bookmark synchronization) wisely.

PhistucK




--
You received this message because you are subscribed to the Google Groups "Chromium-extensions" group.
To post to this group, send email to chromium-...@chromium.org.
To unsubscribe from this group, send email to chromium-extens...@chromium.org.
For more options, visit this group at http://groups.google.com/a/chromium.org/group/chromium-extensions/?hl=en.


Arne Roomann-Kurrik

unread,
Jan 4, 2011, 4:18:43 PM1/4/11
to Owen Bell, Chromium-extensions
Can you provide more information on how the Firefox extension accesses the jar?  Java applets should work (assuming that the user has Java installed/enabled) but if there's some other approach it uses, it likely won't be possible.

~Arne


Owen Bell

unread,
Jan 11, 2011, 11:06:32 AM1/11/11
to Chromium-extensions
I do not know how the firefox extension worked I am afraid. I can
explain what I do know. The jar file will already be running when the
extension needs access it. What I was told was that the extension
should communicate with the jar file via xmlrpc on localhost: 8198

On Jan 4, 4:18 pm, Arne Roomann-Kurrik <kur...@chromium.org> wrote:
> Can you provide more information on how the Firefox extension accesses the
> jar?  Java applets should work (assuming that the user has Java
> installed/enabled) but if there's some other approach it uses, it likely
> won't be possible.
>
> ~Arne
>
>
>
>
>
>
>
> On Sun, Jan 2, 2011 at 9:09 PM, Owen Bell <owenalexb...@gmail.com> wrote:
> > I am currently building an extension for Chrome designed to sync
> > browser state across multiple computers.  An equivalent extension has
> > already been built in Firefox that creates a string and passes it to a
> > jar file (using its api) which then serves as the communicator between
> > the different computers.  I am currently trying to implement an
> > extension in Chrome to interface with this same jar.  I have, however,
> > not discovered any documentation on how I would go about doing this or
> > if it is even possible and was hoping that I could get clarification
> > and assistance with this.
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Chromium-extensions" group.
> > To post to this group, send email to chromium-extensi...@chromium.org.
> > To unsubscribe from this group, send email to
> > chromium-extensions+unsubscr...@chromium.org<chromium-extensions%2Bunsubscr...@chromium.org>
> > .

Arne Roomann-Kurrik

unread,
Jan 11, 2011, 5:55:12 PM1/11/11
to Owen Bell, Chromium-extensions
Oh, then the transport should be HTTP then so you should be able to communicate via XMLHttpRequest calls from your javascript.  You should be able to find a bunch of tutorials on how to post XML data to a web service using XMLHttpRequest.  

You'll also need to request permission to talk to http://localhost:8198/* from your extension.

~Arne


To post to this group, send email to chromium-...@chromium.org.
To unsubscribe from this group, send email to chromium-extens...@chromium.org.

PhistucK

unread,
Jan 12, 2011, 2:40:39 AM1/12/11
to kur...@chromium.org, Owen Bell, Chromium-extensions
Note that you must remove the port and the path (asterisk is this case) when specifying the host in the permissions key - it will not work with the port and the asterisk.
Use this instead -
http://localhost/

PhistucK
Reply all
Reply to author
Forward
0 new messages