Re: How are database JOINS achieved with EJBs?
Hello Steven, Friday, May 26, 2000, 4:52:00 AM, you wrote: example: Write folowing in yours Home interface or ( deployment orion ejb-jar.xml (full: not included) public static final String findByID_STORE_AND_ID_GRP_ORDER_BY_NAME_query= "full:SELECT PL.Id_Pricelist, PL.Datestart, PL.Datestop, PL.Discount, PL.Id_Product, PL.Id_Status, PL.Itemcomment, PL.Oldprice, PL.Price, PL.Quantity FROM PriceList PL, Product P WHERE PL.ID_PRODUCT=P.ID_PRODUCT AND PL.ID_STATUS<>'0' AND PL.ID_STATUS IS NOT NULL AND P.ID_STORE=$1 AND P.ID_GRP=$2 ORDER BY P.PRODUCTNAME" public static final String findByID_INVITEM_query= "Id_Value in ( select Id_Value from OrderedValues where Id_InvItem=$1 )"; SP> Dear EJB Community: SP> Entity java beans pretty much represent a row of data SP> in a database table. SP> If one has: SP> Table XTable Y SP> -- -- SP> A B C DD E F G SP> One commonly executes a SQL command like: SP> select A from X join Y on X.D=Y.D where Y.G ="Bill Clinton" SP> How would one do the equivalent task in an elegant SP> "Enterprise Java Bean" like manner? That is, other SP> than simply writing some member function that performs SP> a JDBC select command like above.
Re: How are database JOINS achieved with EJBs?
you can do it the same way using BMP. Although I would be careful, I think we, as programmers have convinced ourselves that if something is in a database it MUST be an entity bean. This attitude seems to prevail all over, even at my work, where I am having a heck of a time convincing people it is just not so, or doesnt have to be :) Al - Original Message - From: "Steven Punte" <[EMAIL PROTECTED]> To: "Orion-Interest" <[EMAIL PROTECTED]> Sent: Thursday, May 25, 2000 8:52 PM Subject: How are database JOINS achieved with EJBs? > Dear EJB Community: > > Entity java beans pretty much represent a row of data > in a database table. > > If one has: > > Table XTable Y > -- -- > A B C DD E F G > > One commonly executes a SQL command like: > > select A from X join Y on X.D=Y.D where Y.G ="Bill Clinton" > > How would one do the equivalent task in an elegant > "Enterprise Java Bean" like manner? That is, other > than simply writing some member function that performs > a JDBC select command like above. > > Inquiring Minds Want To Know > > -- > STeve Punte > e-Business Software Architect > Technologent Inc > [EMAIL PROTECTED] > >
How are database JOINS achieved with EJBs?
Dear EJB Community: Entity java beans pretty much represent a row of data in a database table. If one has: Table XTable Y -- -- A B C DD E F G One commonly executes a SQL command like: select A from X join Y on X.D=Y.D where Y.G ="Bill Clinton" How would one do the equivalent task in an elegant "Enterprise Java Bean" like manner? That is, other than simply writing some member function that performs a JDBC select command like above. Inquiring Minds Want To Know -- STeve Punte e-Business Software Architect Technologent Inc [EMAIL PROTECTED]
RE: Session bean time out : URGENT
I believe you can but I haven't tried. But you can still make the session timeout changes and restart the server. It will preserve your changes. Conrad -Original Message- From: Walker, Eric [mailto:[EMAIL PROTECTED]] Sent: Thursday, May 25, 2000 2:28 PM To: 'Conrad Chan'; Orion-Interest Subject: RE: Session bean time out : URGENT Where is this file documented? I see that it is created AFTER I deploy but that's too late for me to set the time out. Can I create this file and included it as part of my pre-deployment packaging? Thanks Eric -Original Message- From: Conrad Chan [mailto:[EMAIL PROTECTED]] Sent: Thursday, May 25, 2000 3:59 PM To: 'Walker, Eric'; Orion-Interest Subject: RE: Session bean time out : URGENT I believe you could control the session timeout in ora-ejb-jar.xml which have the setting like below:- Conrad -Original Message- From: Walker, Eric [mailto:[EMAIL PROTECTED]] Sent: Thursday, May 25, 2000 12:43 PM To: Orion-Interest Subject: RE: Session bean time out : URGENT Hi We are currently working on a application using the orion server. I would like some information on how to control the timeout interval for EJBs under Orion. We seem to be timing out after two minutes or so. We have a critical deadline and this is really holding us up. I have posted this question to the mailing list before but I have never received a reply from anyone at orion. Any help would be greatly appreciated. Thanks Eric -Original Message- From: Walker, Eric [mailto:[EMAIL PROTECTED]] Sent: Tuesday, May 16, 2000 6:06 PM To: Orion-Interest Subject: Session bean time out Is there any way for me to set the timeout interval for an EJB? Thanks Eric
cloudscape and orion
Hi, I was wondering if we can use the clouscape database that comes with sun's j2sdkee in the orion server. thanks Alex Alexandre J. Boudreau President, Directeur de Projets Fibro Movement Corp. BEGIN:VCARD VERSION:2.1 N:Boudreau;Alexandre;J. FN:Alexandre J. Boudreau ORG:Fibro Movement TEL;WORK;VOICE:514-575-1580 EMAIL;PREF;INTERNET:[EMAIL PROTECTED] REV:2224T064224Z END:VCARD
RE: Session bean time out : URGENT
Where is this file documented? I see that it is created AFTER I deploy but that's too late for me to set the time out. Can I create this file and included it as part of my pre-deployment packaging? Thanks Eric -Original Message- From: Conrad Chan [mailto:[EMAIL PROTECTED]] Sent: Thursday, May 25, 2000 3:59 PM To: 'Walker, Eric'; Orion-Interest Subject: RE: Session bean time out : URGENT I believe you could control the session timeout in ora-ejb-jar.xml which have the setting like below:- Conrad -Original Message- From: Walker, Eric [mailto:[EMAIL PROTECTED]] Sent: Thursday, May 25, 2000 12:43 PM To: Orion-Interest Subject: RE: Session bean time out : URGENT Hi We are currently working on a application using the orion server. I would like some information on how to control the timeout interval for EJBs under Orion. We seem to be timing out after two minutes or so. We have a critical deadline and this is really holding us up. I have posted this question to the mailing list before but I have never received a reply from anyone at orion. Any help would be greatly appreciated. Thanks Eric -Original Message- From: Walker, Eric [mailto:[EMAIL PROTECTED]] Sent: Tuesday, May 16, 2000 6:06 PM To: Orion-Interest Subject: Session bean time out Is there any way for me to set the timeout interval for an EJB? Thanks Eric
RE: Session bean time out : URGENT
I believe you could control the session timeout in ora-ejb-jar.xml which have the setting like below:- Conrad -Original Message- From: Walker, Eric [mailto:[EMAIL PROTECTED]] Sent: Thursday, May 25, 2000 12:43 PM To: Orion-Interest Subject: RE: Session bean time out : URGENT Hi We are currently working on a application using the orion server. I would like some information on how to control the timeout interval for EJBs under Orion. We seem to be timing out after two minutes or so. We have a critical deadline and this is really holding us up. I have posted this question to the mailing list before but I have never received a reply from anyone at orion. Any help would be greatly appreciated. Thanks Eric -Original Message- From: Walker, Eric [mailto:[EMAIL PROTECTED]] Sent: Tuesday, May 16, 2000 6:06 PM To: Orion-Interest Subject: Session bean time out Is there any way for me to set the timeout interval for an EJB? Thanks Eric
setting http session time out
It seems like the http session expires after a couple of minutes if the application deployed on Orion has been sitting idle. As long as there is some activity, the session stays active. For example, if the session is first acquired in one servlet which brings up a login web page: HttpSession mySession = request.getSession( true ); Clicking of the submit button invokes another servlet where the same session is obtained: HttpSession mySameSession = request.getSession( false ); This works fine if the user clicks the submit button within a couple of minutes. If the user waits longer, the value of mySameSession is null. Does anybody know how we can set session time outs regardless of whether there has been any activity or not? Our application consists of servlets talking to stateful session beans. Is the http session time out related to session bean time outs? Thanks.
Number of instances of servlets used
Is there a way to set the number of servlet instances that the orion server can use in its servlet instance pool? Thanks.
RE: Session bean time out : URGENT
Hi We are currently working on a application using the orion server. I would like some information on how to control the timeout interval for EJBs under Orion. We seem to be timing out after two minutes or so. We have a critical deadline and this is really holding us up. I have posted this question to the mailing list before but I have never received a reply from anyone at orion. Any help would be greatly appreciated. Thanks Eric -Original Message- From: Walker, Eric [mailto:[EMAIL PROTECTED]] Sent: Tuesday, May 16, 2000 6:06 PM To: Orion-Interest Subject: Session bean time out Is there any way for me to set the timeout interval for an EJB? Thanks Eric
Adding to the Server.
Being New to Orion and EJB are there any documents giving a step by step guide to the tools required to add an application to Orion. I have started a number of the tools but which one builds the WAR or the EAR. Which order do I use them in. This seems to be the area where Orion is missing a document or 2. Tim Bentley
JNDI lookups
Hi everyone, this might have been asked before, but I have a question regarding JNDI lookups. I tried the ConverterApp example that is in the J2EE Developer's Guide (Getting Started). So I used the J2EE deploytol and then deployed the ear in orion. In order to run the application Client I need to put both the client-jar and the EJB-jar in the classpath: CPATH=.;%ORION_HOME%\orion.jar;%ORION_HOME%\ejb.jar;%ORION_HOME%\jndi.jar;ap p-client-ic.jar;ejb-jar-ic.jar java -classpath %CPATH% ConverterClient If I don't put the ejb-jar in the classpath, the client doesn't run. So in this sense, it seems that the JNDI name lookup doesn't work!? Then how would I go about running a remote client that communicates with the ejb if such lookup doesn't work? It's possible that I misunderstood something. So any comments would be appreciated. thanks regards, Alex Alexandre J. Boudreau President, Directeur de Projets Fibro Movement Corp. BEGIN:VCARD VERSION:2.1 N:Boudreau;Alexandre;J. FN:Alexandre J. Boudreau ORG:Fibro Movement TEL;WORK;VOICE:514-575-1580 EMAIL;PREF;INTERNET:[EMAIL PROTECTED] REV:2224T064224Z END:VCARD
Installing Servlets in Orion
Hi, I am having a few problems installing servlets into Orion. My Server.xml is set to: My default-web-site.xml is set to: http://localhost/pops-web/servlet/ParameterObjectFactory and http://localhost/pops-web/servlet/General Obviously I am missing something as I am getting HTTP 500 - Internal server error Anyone tell me where I am going wrong. Is what I want to do possible ? Or do I have to package ALL servlets in one war file ? Thanks Mark
Re: AW: EJB state question & Configurable EJB start-up
Hi, Another option could be that the Session Bean instantiates and registers a rmi object if it does not exist, and use this object as the global state. I think it must not be difficult to register a rmi object in the Orion rmi registry. I will try ... Do you find suitable this solution ? Or you find more correct to use an Entity Bean ? Another question: Configurable EJB start-up. Is it possible in any server or is included in the spec any way of configuring EJB start-up ? Let´s say a CheckerEJB that wakes up at ten o´clock in order to update some information. Is it possible to set this in any server ? Jens Stutte wrote: > As far as i know, there is no other way than defining a real entity bean to > store something. One could think to use static variables within a stateless > session bean, but this approach fails if it comes to clustered servers with > multiple JVMs (and nobody can guarantee anything about the lifetime of a > static variable, when the bean is no longer in use in a single JVM model, > too). The spec does not define some sort of "stateful server bean" to store > temporary information within server lifetime, so you have to simulate it by > an entity bean (which means, to ensure transaction safe behaviour and so on > you'll need a database...). BTW, this is not very orion specific ;-). > > Jens Stutte > > -Ursprüngliche Nachricht- > Von: Pedro Garcia Lopez [mailto:[EMAIL PROTECTED]] > Gesendet am: Donnerstag, 25. Mai 2000 13:01 > An: Orion-Interest > Betreff: EJB state question > > Hi all, > > How can I maintain non-persistent state in a component that will be > accesed by multiple clients ? > > For example, I have a component that subscribes to a JMS topic and > listen for events. > I created a Stateless Session Bean with a getLastMesssage() methof that > returns the last message obtained from the topic. > But, due to the stateless nature of the session bean, it always returns > the default value. > If it is statful is only valid for a client, so ... > > Is it possible in the EJB model to create a component that maintain > state and it is accesed for several users ? > > In the Web model (WAR) you can use a bean with application scope, but, > how can I do it with EJBs ? > > Regards,
R:
Steve, 1)Add more than one data-source in data-sources.xml 2)reference them in orion-ejb-jar.xml: this way every Bean can use a different data source Hope this help -Luciano -Messaggio originale- Da: Steven W. Rock [mailto:[EMAIL PROTECTED]] Inviato: giovedì 25 maggio 2000 15.13 A: Orion-Interest Oggetto: How do I reference more than one database in my applications for CMP objects? -Steve
AW: EJB state question
As far as i know, there is no other way than defining a real entity bean to store something. One could think to use static variables within a stateless session bean, but this approach fails if it comes to clustered servers with multiple JVMs (and nobody can guarantee anything about the lifetime of a static variable, when the bean is no longer in use in a single JVM model, too). The spec does not define some sort of "stateful server bean" to store temporary information within server lifetime, so you have to simulate it by an entity bean (which means, to ensure transaction safe behaviour and so on you'll need a database...). BTW, this is not very orion specific ;-). Jens Stutte -Ursprüngliche Nachricht- Von: Pedro Garcia Lopez [mailto:[EMAIL PROTECTED]] Gesendet am: Donnerstag, 25. Mai 2000 13:01 An: Orion-Interest Betreff: EJB state question Hi all, How can I maintain non-persistent state in a component that will be accesed by multiple clients ? For example, I have a component that subscribes to a JMS topic and listen for events. I created a Stateless Session Bean with a getLastMesssage() methof that returns the last message obtained from the topic. But, due to the stateless nature of the session bean, it always returns the default value. If it is statful is only valid for a client, so ... Is it possible in the EJB model to create a component that maintain state and it is accesed for several users ? In the Web model (WAR) you can use a bean with application scope, but, how can I do it with EJBs ? Regards,
Re: doPost/doGet confusion
Title: RE: doPost/doGet confusion No, it can be forced to do a POST-request by using the setRequestMethod method. /August - Original Message - From: Patrik Andersson To: Orion-Interest Cc: E-volution Sent: den 25 maj 2000 15:05 Subject: RE: doPost/doGet confusion Hi! Doesn't HttpUrlConnection make an HTTP GET request? Isn't that what it's made for? Best regards Patrik Andersson -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: den 25 maj 2000 13:23 To: Orion-Interest Cc: E-volution Subject: doPost/doGet confusion Hello! We have experienced a most strange behaviour on a fresh installation of Orion 1.0rc1 deploying a web application of ours. When executing a "POST" request on a servlet (using a java client program using a HTTPUrlConnection) the orion server seems to dispatch to the "doGet" method instead of "doPost"!! We have tried to swap the Orion server for a Tomcat 3.1, using exactly the same client software and the same deployed WEB-archive and code, and Tomcat correctly invokes the "doPost" method for the same request. Is this a common and known bug, or do we need to dig deeper to get more debug information? Any information useful in solving this mystery would be greatly appreciated. Best Regards /August Linnman, ITEC OBI AB, Stockholm. == August Linnman, ITEC Open Business Integrator AB. Stockholm, Sweden Telephone: +4670 930 61 05 PGP key lookup: http://certserver.pgp.com:11371/pks/lookup?op=get&search=0x2BF524E7 ==
No Subject
How do I reference more than one database in my applications for CMP objects? -Steve
RE: doPost/doGet confusion
Title: RE: doPost/doGet confusion Hi! Doesn't HttpUrlConnection make an HTTP GET request? Isn't that what it's made for? Best regards Patrik Andersson -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: den 25 maj 2000 13:23 To: Orion-Interest Cc: E-volution Subject: doPost/doGet confusion Hello! We have experienced a most strange behaviour on a fresh installation of Orion 1.0rc1 deploying a web application of ours. When executing a "POST" request on a servlet (using a java client program using a HTTPUrlConnection) the orion server seems to dispatch to the "doGet" method instead of "doPost"!! We have tried to swap the Orion server for a Tomcat 3.1, using exactly the same client software and the same deployed WEB-archive and code, and Tomcat correctly invokes the "doPost" method for the same request. Is this a common and known bug, or do we need to dig deeper to get more debug information? Any information useful in solving this mystery would be greatly appreciated. Best Regards /August Linnman, ITEC OBI AB, Stockholm. == August Linnman, ITEC Open Business Integrator AB. Stockholm, Sweden Telephone: +4670 930 61 05 PGP key lookup: http://certserver.pgp.com:11371/pks/lookup?op=get&search=0x2BF524E7 ==
doPost/doGet confusion
Hello! We have experienced a most strange behaviour on a fresh installation of Orion 1.0rc1 deploying a web application of ours. When executing a "POST" request on a servlet (using a java client program using a HTTPUrlConnection) the orion server seems to dispatch to the "doGet" method instead of "doPost"!! We have tried to swap the Orion server for a Tomcat 3.1, using exactly the same client software and the same deployed WEB-archive and code, and Tomcat correctly invokes the "doPost" method for the same request. Is this a common and known bug, or do we need to dig deeper to get more debug information? Any information useful in solving this mystery would be greatly appreciated. Best Regards /August Linnman, ITEC OBI AB, Stockholm. == August Linnman, ITEC Open Business Integrator AB. Stockholm, Sweden Telephone: +4670 930 61 05 PGP key lookup: http://certserver.pgp.com:11371/pks/lookup?op=get&search=0x2BF524E7 == BEGIN:VCARD VERSION:2.1 N:Linnman;August FN:August Linnman ORG:ITEC Open Business Integrator AB;Software development TITLE:System Engineer NOTE;ENCODING=QUOTED-PRINTABLE:PGP key lookup: http://certserver.pgp.com:11371/pks/lookup?op=3Dget&search= =3D0x2BF524E7=0D=0A TEL;WORK;VOICE:+468-343431 TEL;WORK;VOICE:+4670-4928641 TEL;HOME;VOICE:+468-308917 TEL;CELL;VOICE:+4670-9306105 TEL;WORK;FAX:+468-343438 TEL;HOME;FAX:+468-314954 ADR;WORK:;;Ynglingagatan 17;Stockholm;Stockholm;11347;Stockholm LABEL;WORK;ENCODING=QUOTED-PRINTABLE:Ynglingagatan 17=0D=0AStockholm, Stockholm 11347=0D=0AStockholm ADR;HOME:;;Torbjörn Klockares g 13;Stockholm;Stockholm;113 30;Sweden LABEL;HOME;ENCODING=QUOTED-PRINTABLE:Torbj=F6rn Klockares g 13=0D=0AStockholm, Stockholm 113 30=0D=0ASweden X-WAB-GENDER:2 URL:http://www.itec.se/august.htm URL:http://www.itec.se EMAIL;PREF;INTERNET:[EMAIL PROTECTED] REV:2525T112300Z END:VCARD
EJB state question
Hi all, How can I maintain non-persistent state in a component that will be accesed by multiple clients ? For example, I have a component that subscribes to a JMS topic and listen for events. I created a Stateless Session Bean with a getLastMesssage() methof that returns the last message obtained from the topic. But, due to the stateless nature of the session bean, it always returns the default value. If it is statful is only valid for a client, so ... Is it possible in the EJB model to create a component that maintain state and it is accesed for several users ? In the Web model (WAR) you can use a bean with application scope, but, how can I do it with EJBs ? Regards,