Using Java

Hi all!

I’ ve just begun some days ago to star using J9.

is there anybody around who has done some work with that? , i.e. a simple
I/O Resource Manager, or something like that… that can give a clue or
some orientation as I’m new in QNX stuff as well, an all the examples are
only for C.

:slight_smile:)

Thanks

Hi,

juan carlos wrote:

I’ ve just begun some days ago to star using J9.

is there anybody around who has done some work with that? , i.e. a simple
I/O Resource Manager, or something like that… that can give a clue or
some orientation as I’m new in QNX stuff as well, an all the examples are
only for C.

I don’t think you can implement anything system oriented in Java, and I/O
Manager is just good example :slight_smile: All is Java about is just to be system
independent, and I/O Managers (i.e. drivers :slight_smile: is from different Universe :slight_smile:


BR, Andrej

Well, that’s simply not true. You can native methods to do whatever you
need in Java, but implemented in C. Having said that, there exist no
‘bindings’ (JNI methods) for Neutrino-specific os services, for any Java VM,
that I’m aware of.

The interesting bit, actually, is all standard Java VMs (including IBM’s J9
vm) are implemented in such a way that JNI libraries (dlls for windows, so’s
for *nixs) can be used by any VM, as long as the JNI libraries stick to the
‘standard’ JNI functions available.

Juan, I suspect:

  • you’re going to offer me some more pints :slight_smile:
  • you’ll get a better response in the vame newsgroup at the ibm site; there
    just aren’t that many people using Java here, I’m guessing …

Patrick Mueller
Patrick_Mueller@oti.com



Andrej Timchenko <silpol@yahoo.com> wrote in message
news:39ED8771.79EB2DFE@yahoo.com

Hi,

juan carlos wrote:

I’ ve just begun some days ago to star using J9.

is there anybody around who has done some work with that? , i.e. a
simple
I/O Resource Manager, or something like that… that can give a clue or
some orientation as I’m new in QNX stuff as well, an all the examples
are
only for C.

I don’t think you can implement anything system oriented in Java, and I/O
Manager is just good example > :slight_smile: > All is Java about is just to be system
independent, and I/O Managers (i.e. drivers > :slight_smile: > is from different Universe
:slight_smile:


BR, Andrej

<!doctype html public “-//w3c//dtd html 4.0 transitional//en”>

Hi

Patrick, are you sure? Juan was talking about writing "i.e. a simple I/O Resource Manager, or something like that...". Give me a reason why one should implement _device_driver_ in Java, even if JVM is so small in footprint as J9 is? I don't see any rationale in that...

Patrick Mueller wrote:

Well, that's simply not true.  You can native methods to do whatever you
need in Java, but implemented in C.  Having said that, there exist no
'bindings' (JNI methods) for Neutrino-specific os services, for any Java VM,
that I'm aware of.

The interesting bit, actually, is all standard Java VMs (including IBM's J9
vm) are implemented in such a way that JNI libraries (dlls for windows, so's
for *nixs) can be used by any VM, as long as the JNI libraries stick to the
'standard' JNI functions available.

Juan, I suspect:
- you're going to offer me some more pints :slight_smile:
- you'll get a better response in the vame newsgroup at the ibm site; there
just aren't that many people using Java here, I'm guessing ...

--
--------------------------------------
Patrick Mueller

--------------------------------------

Andrej Timchenko <> wrote in message
news:<39ED8771.79EB2DFE@yahoo.com>...
> Hi,
>
> juan carlos wrote:
>
> > I' ve just begun some days ago to star using J9.
> >
> > is there anybody  around who has done some work with that? , i.e. a
simple
> > I/O Resource Manager, or something like that.... that can give a clue or
> > some orientation as I'm new in QNX stuff as well, an all the examples
are
> > only for C.
>
> I don't think you can implement anything system oriented in Java, and I/O
> Manager is just good example :slight_smile: All is Java about is just to be system
> independent, and I/O Managers (i.e. drivers :slight_smile: is from different Universe
:)
>
> --
> BR, Andrej
>
>

--
BR, Andrej
 

Previously, Patrick Mueller wrote in qdn.public.qnxrtp.devtools:

Well, that’s simply not true. You can native methods to do whatever you
need in Java, but implemented in C. Having said that, there exist no
‘bindings’ (JNI methods) for Neutrino-specific os services, for any Java VM,
that I’m aware of.

The interesting bit, actually, is all standard Java VMs (including IBM’s J9
vm) are implemented in such a way that JNI libraries (dlls for windows, so’s
for *nixs) can be used by any VM, as long as the JNI libraries stick to the
‘standard’ JNI functions available.

This is true as far as I can tell. The great thing about the QNX resource
manager model though is that one can implement a resource manager pretty
easily in C and access it using normal file i/o calls from any language.

Andrej Timchenko <> silpol@yahoo.com> > wrote in message
news:> 39ED8771.79EB2DFE@yahoo.com> …
Hi,

juan carlos wrote:

I’ ve just begun some days ago to star using J9.

is there anybody around who has done some work with that? , i.e. a
simple
I/O Resource Manager, or something like that… that can give a clue or
some orientation as I’m new in QNX stuff as well, an all the examples
are
only for C.

I don’t think you can implement anything system oriented in Java, and I/O
Manager is just good example > :slight_smile: > All is Java about is just to be system
independent, and I/O Managers (i.e. drivers > :slight_smile: > is from different Universe
:slight_smile:


BR, Andrej


\


David L. Hawley D.L. Hawley and Associates

!doctype html public “-//w3c//dtd html 4.0 transitional//en”
html

Hi Andrej.

could you please turn off HTML in your email replys please,
it makes it VERY hard to read in several non browser email readers.


Paul May, Manchester, UK
Team Phoenix

Am I sure about what?

Why would you want to implement a resource manager in Java? Because there’s
lots of great APIs already available in Java. If I wanted to write a
resource manager that mapped a base URL to a directory, this would be
relatively easy using Java’s URL support (faking directories would be hard,
or impossible, but such a resource manager could be useful in some
situations, even without directory support). This is because Java does a
lot of work already to handle the URL glop - it’s unbelievably simple. As
it is with Python, and Perl as well. In C, well, I don’t know. I’m sure
there are some nice libraries to do HTTP access, but I’m already bought into
the KISS world of OO/Scripting languages, that I try to limit the amount of
C programming that I do these days. If accessing a URL in C means calling
more than 10 functions from some library, setting up a bunch of structures,
yadda/yadda/yadda, then I start pining to do it in Java/Python/Perl.

Then there is just the plain old “cool” factor > :slight_smile:

you should take a look at http://www.rebol.com too Patrick,
now thats a KISS & Cool Scripting/internet Language.


Paul May, Manchester, UK
Team Phoenix

Well, that’s simply not true. You can native methods to do whatever you
need in Java, but implemented in C. Having said that, there exist no
‘bindings’ (JNI methods) for Neutrino-specific os services, for any Java VM,
^ YET ?



that I’m aware of.

The interesting bit, actually, is all standard Java VMs (including IBM’s J9
vm) are implemented in such a way that JNI libraries (dlls for windows, so’s
for *nixs) can be used by any VM, as long as the JNI libraries stick to the
‘standard’ JNI functions available.

Juan, I suspect:

  • you’re going to offer me some more pints > :slight_smile:
  • you’ll get a better response in the vame newsgroup at the ibm site; there
    just aren’t that many people using Java here, I’m guessing …

perhaps not, but i think its always wise to ask rather than Guess
at an answer ( i hope you. the readers agree).

actually, i`m thinking that many people might be interested in the
J9 given that you are ? working in Cooperation with Dan and
the RTP team on this realtime Initative.

could all the relavent IBM (and other ?)NGs be placed/peered on the
inn.qnx.com to help encurage this Cooperation and in the process,
help benifit both developers and end users alike in the longer term,
thats part of what our Phoenix Developers Consortium is about,
its far better for all concerned, to try and help, and work together
in the long run, rather than seperate in to little boxes were
everyones running around the web trying to figure out the best
options for their needs.


Paul May, Manchester, UK
Team Phoenix

Am I sure about what?

Why would you want to implement a resource manager in Java? Because there’s
lots of great APIs already available in Java. If I wanted to write a
resource manager that mapped a base URL to a directory, this would be
relatively easy using Java’s URL support (faking directories would be hard,
or impossible, but such a resource manager could be useful in some
situations, even without directory support). This is because Java does a
lot of work already to handle the URL glop - it’s unbelievably simple. As
it is with Python, and Perl as well. In C, well, I don’t know. I’m sure
there are some nice libraries to do HTTP access, but I’m already bought into
the KISS world of OO/Scripting languages, that I try to limit the amount of
C programming that I do these days. If accessing a URL in C means calling
more than 10 functions from some library, setting up a bunch of structures,
yadda/yadda/yadda, then I start pining to do it in Java/Python/Perl.

Then there is just the plain old “cool” factor :slight_smile:

However, having said this, I run into a lot of people who actually >do< want
to do this, but it’s because they’ve bought into the Java/OO story too much.
It’s great for a lot of things. But sometimes, it’s just easier to revert
to C. In this particular case (resource managers), I suspect it would
almost always be easier to just do the resource manager in C, then talk to
it with java.io.File (assuming it understands standard read/write resource
manager calls). Until someone actually does the “Neutrino Bindings for
Java” piece of work … in which case, if they did it right, it would
probably be easier to do it in Java.

Performance is always a concern as well. You lose a little control over
your runtime when you use Java, although the Java Realtime work in helping
reign that in a bit …

When it comes right down to it, ‘language’ should never be the concern.
Size, speed, speed-to-market, maintainability, functionality are the only
things that count. Your customers >really< don’t care if your product is
implemented in C with the gcc toolchain or visual basic …

Patrick Mueller
Patrick_Mueller@oti.com



Andrej Timchenko <silpol@yahoo.com> wrote in message
news:39EF3A63.ECAE110@yahoo.com
Hi
Patrick, are you sure? Juan was talking about writing “i.e. a simple I/O
Resource Manager, or something like that…”. Give me a reason why one
should implement device_driver in Java, even if JVM is so small in
footprint as J9 is? I don’t see any rationale in that…
Patrick Mueller wrote:
Well, that’s simply not true. You can native methods to do whatever you
need in Java, but implemented in C. Having said that, there exist no
‘bindings’ (JNI methods) for Neutrino-specific os services, for any Java VM,
that I’m aware of.
The interesting bit, actually, is all standard Java VMs (including IBM’s J9
vm) are implemented in such a way that JNI libraries (dlls for windows, so’s
for *nixs) can be used by any VM, as long as the JNI libraries stick to the
‘standard’ JNI functions available.
Juan, I suspect:

  • you’re going to offer me some more pints :slight_smile:
  • you’ll get a better response in the vame newsgroup at the ibm site; there
    just aren’t that many people using Java here, I’m guessing …

Patrick Mueller
Patrick_Mueller@oti.com

Andrej Timchenko <silpol@yahoo.com> wrote in message
news:39ED8771.79EB2DFE@yahoo.com

Hi,

juan carlos wrote:

I’ ve just begun some days ago to star using J9.

is there anybody around who has done some work with that? , i.e. a
simple
I/O Resource Manager, or something like that… that can give a clue or
some orientation as I’m new in QNX stuff as well, an all the examples
are
only for C.

I don’t think you can implement anything system oriented in Java, and I/O
Manager is just good example > :slight_smile: > All is Java about is just to be system
independent, and I/O Managers (i.e. drivers > :slight_smile: > is from different Universe
:slight_smile:


BR, Andrej

\

BR, Andrej

Paul May wrote:

!doctype html public “-//w3c//dtd html 4.0 transitional//en”
html

Hi Andrej.

could you please turn off HTML in your email replys please,
it makes it VERY hard to read in several non browser email readers.

hopefully, I switched news to “plain mode” writing… would you please
to drop me a line - did I succeed or not? E-mail is in header…

thanks Andrej, it seems to be working fine now.

\

Paul May, Manchester, UK
Team Phoenix

Paul May wrote:

!doctype html public “-//w3c//dtd html 4.0 transitional//en”
html

Hi Andrej.

could you please turn off HTML in your email replys please,
it makes it VERY hard to read in several non browser email readers.

hopefully, I switched news to “plain mode” writing… would you please
to drop me a line - did I succeed or not? E-mail is in header…


BR, Andrej

Paul May <paul@phinixi.com> wrote in message
news:1568.329T354T1953484paul@phinixi.com

Well, that’s simply not true. You can native methods to do whatever you
need in Java, but implemented in C. Having said that, there exist no
‘bindings’ (JNI methods) for Neutrino-specific os services, for any Java
VM,
^ YET ?

that I’m aware of.

Yes, your wish for “YET” is hopefully a “YET” as opposed to “AND THERE NEVER
WILL BE ANY”. It’s a SMOP (Simple Matter of Programming). It’s not simple,
but not rocket science. You don’t need to wait for IBM to do it. And per
my following paragraph, it can be done in such a way that ANY Java VM could
make use of it, so a likely candidate to ask to do this is QSSL itself. Who
knows the Neutrino APIs better than them?

The interesting bit, actually, is all standard Java VMs (including IBM’s
J9
vm) are implemented in such a way that JNI libraries (dlls for windows,
so’s
for *nixs) can be used by any VM, as long as the JNI libraries stick to
the
‘standard’ JNI functions available.

As an aside, I used to work VisualAge Smalltalk, and any time we wanted to
use some ‘external’ API like database, transaction systems, tcp/ip, etc, we
had to do it ourselves, because the product owner had no idea our product
existed, much less the skill or time or interest to do it. That is, do the
mapping layer between the API and Smalltalk, which is very much in the same
vein as Java JNI. In the new Java universe, it’s become much easier to get
the API owners to do their own mapping layers, since they have the skill or
can easily get it, and usually have the interest. Time is always the killer
though. Anyhoo, I always defer to the API owners to do the mapping layer
since it’s THEIR API that people are going to be using, and they may have a
particular spin on how they want it to look to the developers. Push come to
shove, someone else may have to do it …

Juan, I suspect:

  • you’re going to offer me some more pints > :slight_smile:
  • you’ll get a better response in the vame newsgroup at the ibm site;
    there
    just aren’t that many people using Java here, I’m guessing …

perhaps not, but i think its always wise to ask rather than Guess
at an answer ( i hope you. the readers agree).

actually, i`m thinking that many people might be interested in the
J9 given that you are ? working in Cooperation with Dan and
the RTP team on this realtime Initative.

could all the relavent IBM (and other ?)NGs be placed/peered on the
inn.qnx.com to help encurage this Cooperation and in the process,
help benifit both developers and end users alike in the longer term,
thats part of what our Phoenix Developers Consortium is about,
its far better for all concerned, to try and help, and work together
in the long run, rather than seperate in to little boxes were
everyones running around the web trying to figure out the best
options for their needs.

I’m not guessing about getting better support for the j9 vm in the ibm ng.
I scan inn.qnx.com and news.software.ibm.com and there are clearly more j9
questions in the ibm group than on this server. The ibm group’s sole focus
is the j9 vm (and related technologies such as our IDE). I suspect, for
instance, there are not many J9 developers hanging out here, but there some
number that hang out in the ibm group, all the time.

I don’t have a clue as to how to peer the newsgroup, but you could certainly
post there and ask. One problem is going to be that the ibm group is
probably 80% consumed by folks working with the j9 vm on the palm. So, if
it appeared here, I suspect you’d get folks cross-griping about “why do you
keep asking palm questions in this nto ng???” :slight_smile:

Patrick Mueller
Patrick_Mueller@oti.com