Peter,
you have a point there... We are creating a trully distributed system,
one of our requirements is that on a batch basis a number of files have to
be splitted..
In my opinion this can be done using ejb and getting additional support from
the container (security)
or via a helper class .... Judging the various opinions i should better
create a helper class than
and ejb..
Thanks for your information,
Marco Pas
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: woensdag 3 januari 2001 16:34
To: Marco Pas
Cc: [EMAIL PROTECTED]
Subject: Re: File I/O in an session EJB
Marco,
The EJB spec under "runtime environment" states:
"An enterprise bean must not use the java.io package to
attempt to access files and directories in the file system."
It goes on to say:
"The file system APIs are not well-suited for business
components to access data. Business components should use a
resource manager API, such as JDBC API to store data."
So, it is not hard to imagine a zillion cached beans serving some
monster client base. If all those beans upon creation/activation
needed to individually open up a file and read the contents, this
could create quite a bottle neck.
In your case it sounds like perhaps your application is more "batch" in
nature...? If this is the case (and not knowing much about your
requirements) does you problem really fit into a client/server/distributed
object paradigm....?
cheers,
peter
At Wed, 3 Jan 2001 16:12:19 +0100 , Marco Pas <[EMAIL PROTECTED]>
wrote:
>Why is File I/O in a bean not a good idea ?
>
>I have to create a bean that reads a file and splits the file...
>I thought it was a very good idea to do this in an EJB,
>because you can take advantage of the security mechanisms, etc...
>
>Kind Regards,
>Marco
>
>-----Original Message-----
>From: A mailing list for Enterprise JavaBeans development
>[mailto:[EMAIL PROTECTED]]On Behalf Of Mikko Laanti
>Sent: woensdag 3 januari 2001 15:49
>To: [EMAIL PROTECTED]
>Subject: Reading Properties from EJB?
>
>
>Hi,
>
>In EJB Spec. there was mentioned that using direct file io from Ejb is
>not a "good idea". People also talked about this in this newsletter.
>
>How about using Properties class? I know it's based on file IO but does
>Ejb container support it?
>
>Anyone know?
>
>Br
>
>- Max
>
>
>email: [EMAIL PROTECTED]
>
>===========================================================================
>To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
>of the message "signoff EJB-INTEREST". For general help, send email to
>[EMAIL PROTECTED] and include in the body of the message "help".
>
>===========================================================================
>To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
>of the message "signoff EJB-INTEREST". For general help, send email to
>[EMAIL PROTECTED] and include in the body of the message "help".
>
>
>
===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".