Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Is iText thread safe??

456 views
Skip to first unread message

Eric

unread,
Sep 6, 2003, 12:53:36 PM9/6/03
to
Do anyone know the answer, please help.

Regards,
DLT

Paulo Soares

unread,
Sep 6, 2003, 7:00:29 PM9/6/03
to
iText is thread safe.

Best Regards,
Paulo Soares

d...@hongkong.com (Eric) wrote in message news:<69a0d604.03090...@posting.google.com>...

Aandi Inston

unread,
Sep 7, 2003, 5:41:57 AM9/7/03
to
var...@yahoo.com (Paulo Soares) wrote:

>iText is thread safe.

Just a rather off topic curiosity, if iText is Java, as I suspect it
is, can a Java program be anything other than thread safe? (Unless, I
suppose it uses external resources like a fixed temporary file name).
----------------------------------------
Aandi Inston qu...@dial.pipex.com http://www.quite.com
Please support usenet! Post replies and follow-ups, don't e-mail them.

Jos Vernon

unread,
Sep 8, 2003, 6:10:48 AM9/8/03
to
> Just a rather off topic curiosity, if iText is Java, as I suspect it
> is, can a Java program be anything other than thread safe? (Unless, I
> suppose it uses external resources like a fixed temporary file name).

It's easy to write thread unsafe code in any language.

The simplest way to do this is to use uncontrolled access to global or
static variables. This kind of shared state amongst threads will cause
considerable confusion.

A less common cause is sharing one object on multiple threads. In this case
member variables get changed by different threads leading to confusion.

Many applications are thread-safe in the static/global variable sense. Few
are thread safe in the member-variable sense.

Jos


Paulo Soares

unread,
Sep 8, 2003, 7:26:56 AM9/8/03
to
Java is not thread safe, a synchronize block (a critical section in
windows language) is needed to ensure that a single thread at a time
can access some resource. In the particular case of iText thread
safety only exists if no more than a thread at a time writes to a
particular document. The normal case is each thread has it's document
or documents.

Best Regards,
Paulo Soares

qu...@dial.pipex.com (Aandi Inston) wrote in message news:<3f5afd23....@reading.news.pipex.net>...

0 new messages