UN-SUBSCRIBE
Re: Debugging and orion
Hi, You can use -out and -err commandline swiches to specify where System.outs and System.errs are written. For example: $JAVA_HOME/bin/java -server -jar orion.jar \ -config $ORION_HOME/config/server.xml \ -out $ORION_HOME/log/server-out.log \ -err $ORION_HOME/log/server-err.log -- Joni [EMAIL PROTECTED] Nusairat, Joseph F. wrote: OK its an older thread ... but i dont have time to read them all I was just wondering ... if i run Orion as a service ... how do i see the System.out.printlns? Does it write them to any log file?? OR is there anyway i can pick them up -Original Message- From: Justen Stepka [mailto:[EMAIL PROTECTED]] Sent: Wednesday, February 21, 2001 11:08 AM To: Orion-Interest Subject: Re: Debugging and orion No matter what anyone tells you, System.out.println (ObjectName:MethodName ():line number); will work wonders! Justen Stepka On Wed, 21 Feb 2001, Julian Richardson wrote: Hi, What tools / IDEs are people out there using to develop EJBs for use with Orion? At the moment we (as a project team, rather than company) are trying to standardise on an app server and IDE to use, requirements being the usual: cost speed flexibility resource usage debugging support from the IDE - I saw that someone mentioned using Kawa with Orion on the orionsupport website; has this combination been used by many people? (I'm new to the app server world, although I've been doing server-side Java work for several years now - I'm not used to environments where it's even possible to use an integrated debugger, but others on the team say it's necessary :-) Comments about the speed / flexibility / resource usage of Orion are welcome too, from the website it looks pretty slick and the documentation looks good, but time will tell... also if there's any major snags with orion in terms of things that the current version doesn't do correctly or doesn't implement... cheers Jules --
AW: Memory leaks
We do not have any production site, yet, but from my experience with orion and EJB, the most important thing is to provide an orion-ejb-jar.xml with your application, where you specify maximum instance limits for each entity bean. Otherwise there will be only a timeout to destroy cached instances, which under heavy load may not be sufficient. This looks like: ?xml version=1.0? !DOCTYPE orion-ejb-jar PUBLIC -//Evermind//DTD Enterprise JavaBeans 1.1 runtime//EN http://www.orionserver.com/dtds/orion-ejb-jar.dtd; orion-ejb-jar enterprise-beans entity-deployment name=BeanName location=BeanName max-instances=[Number of Instances] validity-timeout=360 / /enterprise-beans /orion-ejb-jar Best performance (together with exclusive-write-access) you get with high timeouts and a sufficient number of instances to fill your RAM without swapping - only that you must set it for each bean and play around a bit to find the best values (especially when you have a lot of entity beans). Lowest memory usage you get with both low timeouts and max-instances, of course. This is no memory leak issue, but may seem as such if you don't limit the number of beans and put your system under heavy load. Other problems with memory (except for our own code ;-) did not show up yet. Good luck, Jens Stutte -Ursprüngliche Nachricht- Von: Nusairat, Joseph F. [mailto:[EMAIL PROTECTED]] Gesendet am: Donnerstag, 28. Juni 2001 21:17 An: Orion-Interest Betreff: Memory leaks I was curious ... i am about to put orion into a production enviroment within the next week. I have been writing some EJB's with it ... and some testing and configuring I was wondering how bad or good it is at memory leaks? Do u all have to restart your servers often??? Or??? any suggestions It will be on win2k boxes
RE: Memory leaks
There are issues with memory leaks and some jdbc drivers. Search the list on postgresql, for example. This is not necessarily orion, but if you are using a database with orion, the driver will be in the orion vm. If the driver chews up memory, so will orion. the elephantwalker -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Jens Stutte Sent: Friday, June 29, 2001 12:31 AM To: Orion-Interest Subject: AW: Memory leaks We do not have any production site, yet, but from my experience with orion and EJB, the most important thing is to provide an orion-ejb-jar.xml with your application, where you specify maximum instance limits for each entity bean. Otherwise there will be only a timeout to destroy cached instances, which under heavy load may not be sufficient. This looks like: ?xml version=1.0? !DOCTYPE orion-ejb-jar PUBLIC -//Evermind//DTD Enterprise JavaBeans 1.1 runtime//EN http://www.orionserver.com/dtds/orion-ejb-jar.dtd; orion-ejb-jar enterprise-beans entity-deployment name=BeanName location=BeanName max-instances=[Number of Instances] validity-timeout=360 / /enterprise-beans /orion-ejb-jar Best performance (together with exclusive-write-access) you get with high timeouts and a sufficient number of instances to fill your RAM without swapping - only that you must set it for each bean and play around a bit to find the best values (especially when you have a lot of entity beans). Lowest memory usage you get with both low timeouts and max-instances, of course. This is no memory leak issue, but may seem as such if you don't limit the number of beans and put your system under heavy load. Other problems with memory (except for our own code ;-) did not show up yet. Good luck, Jens Stutte -Ursprüngliche Nachricht- Von: Nusairat, Joseph F. [mailto:[EMAIL PROTECTED]] Gesendet am: Donnerstag, 28. Juni 2001 21:17 An: Orion-Interest Betreff: Memory leaks I was curious ... i am about to put orion into a production enviroment within the next week. I have been writing some EJB's with it ... and some testing and configuring I was wondering how bad or good it is at memory leaks? Do u all have to restart your servers often??? Or??? any suggestions It will be on win2k boxes
Re: Debug JSP - how to?
Try uncommenting the error-page thing in web.xml, this would let you see what is actually going on. Johan - Original Message - From: Henrik Skafsgaard Larsen [EMAIL PROTECTED] To: Orion-Interest [EMAIL PROTECTED] Sent: Friday, June 29, 2001 8:07 AM Subject: Re: Debug JSP - how to? I AM using IE and that thingy for *user friendly* messages has been disabled. Both Netscape and IE attempts to save the file instead of displaying it. What I do not understand is, how can I actually make an instance of the class but not use a method in it? Seems odd to me. mvh / best regards Henrik Skafsgaard Larsen - Original Message - From: Scot Weber [EMAIL PROTECTED] To: Orion-Interest [EMAIL PROTECTED] Sent: Thursday, June 28, 2001 5:21 PM Subject: Re: Debug JSP - how to? Henrik, Are you by chance using IE? If you are, go to the advanced properties and disable the beautified error page display, this will give you the actual jsp error information from things like 500 Server Errors. If you're using nutscrape and not getting meaningful error messages, then something is radically wrong. - peace - scot weber / [EMAIL PROTECTED] [ this space reserved for something really clever ] Henrik Skafsgaard Larsen wrote: Hello I have this servlet, which actually doesn't do much except write html, so for testing purpose I decided to change it to JSP. I want to use some methods defined in our homegrown packages and imported the package with: %@ page import=com.mypacke.util.* % I then wrote the following: . . % Cleo c = new Cleo(); out.println(Howdy from Cleo: + c.getDate()); % . . the result was, that my page could not be displayed. Removing the reference: c.getDate() helped but I cannot find any hints ind the logfiles as to WHY it doesn't work. med venlig hilsen / best regards Henrik Skafsgaard Larsen
UNSUSCRIBE
CMP vs BMP and finder methods
Hi forum, I would like to know what strategies people use in real life to design their entity beans, when use CMPs and when BMPs. Each approarch has its own benefits and drawbacks. This is what I found out during my experience with EJB: 1.CMPs Benefits: -easy to develop; -better perfomance. Drawbacks: - less flexible then BMPs; - some of the queries cannot be performed with pure CMP, so sometimesit is necessary to add a data access object ( java class ) that uses JDBC to directly communicate with database ( to retreive the number of records etc. ). The problem here is that it is necessary - not all queries can be coded with CMP finder methods ( consider example: I need to extract 20 records, starting with 500 out of 3000 records in a table. Using Collection would be extremely expensive ). 2.BMPs Benefits: - full control over data flow. you can do anything JDBC is capable of. Drawbacks: - huge perfomance degradation when retrieving a collection of BMPs - the problem of n+1 call. My conclusion is: everyting is fine with the creation, updating and deleting the entities. The problem arises with finder methods: You are either to slow with BMPs or fast with CMPs but with limited functionality. Another idea is to use CMPs to create/update/delete entities, but use JDBC and retreive collections valuesvalue objects for finders, something like: public class EntityValue { public int id; public String data; } The problem here is that we lose encapsulation... How do you handle this situation? Any suggestions are very much appreciated. Sergei.
Re:
Go look on www.orionsupport.com or search through the mailing list. You should find examples! RHH --- struts orion [EMAIL PROTECTED] wrote: Hi I am using oracle thin driver the data-source.xml configuration is data-source class=com.evermind.sql.DriverManagerDataSource name=oraclethin location=jdbc/Oracle connection-driver=oracle.jdbc.driver.OracleDriver username=varro password=varro url=jdbc:oracle:thin:@192.0.0.8:1521:hcp inactivity-timeout=30 / How to use/locate this data source in a simple client application which uses this datasource and connects to database If possible give example code for client application thanks regards praveen __ Do You Yahoo!? Get personalized email addresses from Yahoo! Mail http://personal.mail.yahoo.com/ __ Do You Yahoo!? Get personalized email addresses from Yahoo! Mail http://personal.mail.yahoo.com/
mdb and external jms
Still wondering about the subject. When using swiftmq jms server, client only has to set INITIAL_CONTEXT_FACTORY and PROVIDER_URL to connect to swiftmq router/jms server. So in orion-ejb-jar.xml we define message-driven-deployment tag.. Under it its possible to set lookup-context location and context-attribute. Question goes: is it possible set up bean to listen external jms using these tags? Example is this valid: context-attribute name=PROVIDER_URL value=smqp://localhost:4001 / ..? (trying to set java.naming.provider.url .. And what should the value for lookup-context location be then?
UNSUSCRIBE
-- /* * Kenneth N. M. Eisner * Developer * * Brics|net US, LLC * 53 Green St. * Portsmouth, NH * 03801 * * (tel.) 603-436-6868 * (fax.) 603-436-5760 */
Re:JMS .xml files question
Queues and topics that are in the config/jms.xml dont have to be in the application-client.xml. I have not been able to create a factory in the config/jms.xml.
Re:
package com.cyonara.gw.sql; import com.cyonara.gw.util.*; import java.sql.Connection; import javax.naming.Context; import javax.naming.InitialContext; import javax.naming.NamingException; import javax.sql.DataSource; public class DataSourceSqlConnector implements SqlConnector { //===/ //=== Static Data Members ===/ //===/ private static final Log fLog = LogFactory.getInstance(DataSourceSqlConnector.class); /// //=== Data Members ===/ /// private String fDataSourceName = null; /// //=== Constructors ===/ /// public DataSourceSqlConnector( final String dataSourceName) { fDataSourceName = dataSourceName; } //==/ //=== Public Methods ===/ //==/ public Connection getConnection() throws Exception { fLog.beginDebug(getConnection()); Context context = new InitialContext(); DataSource ds = (DataSource)context.lookup(fDataSourceName); Connection result = ds.getConnection(); fLog.endDebug(getConnection()); return result; } } - Original Message - From: struts orion [EMAIL PROTECTED] To: Orion-Interest [EMAIL PROTECTED] Sent: Thursday, June 28, 2001 8:57 PM Hi I am using oracle thin driver the data-source.xml configuration is data-source class=com.evermind.sql.DriverManagerDataSource name=oraclethin location=jdbc/Oracle connection-driver=oracle.jdbc.driver.OracleDriver username=varro password=varro url=jdbc:oracle:thin:@192.0.0.8:1521:hcp inactivity-timeout=30 / How to use/locate this data source in a simple client application which uses this datasource and connects to database If possible give example code for client application thanks regards praveen __ Do You Yahoo!? Get personalized email addresses from Yahoo! Mail http://personal.mail.yahoo.com/
Re:UNSUSCRIBE
-- /* * Kenneth N. M. Eisner * Developer * * Brics|net US, LLC * 53 Green St. * Portsmouth, NH * 03801 * * (tel.) 603-436-6868 * (fax.) 603-436-5760 */ hello: my name is ¿×ÏéÓÑ,I am form beijin tel.:01067501840 ===sms.163.com--ÍøÒ׶ÌÐÅ ÎÞÂÛÄãÉíÔں䦣¬Ò²²»¹ÜÒƶ¯»òÊÇÁªÍ¨£¬ÍøÒ׶ÌÐŶ¼ÄÜÒ»Íø´ò¾¡£¡ Ñ¡ÔñÍøÒ׶ÌÐÅ£¬ÐÄÓëÐÄÖ®¼ä½«²»ÔÙÓоàÀ룡
returning an interface
Has anyone ever returned an interface from an EJB? I get the following error: com.evermind.server.rmi.OrionRemoteException: Error (de-)serializing object: MyInterfaceImpl Here is my Remote Interface: public interface Test extends EJBObject{ public IMyInterface getInterface() throws RemoteException;} Here is the implmentation of the method: public IMyInterface getInterface() throws RemoteException { return new MyInterfaceImpl(); } Thanks, Paul
500 Internal Server Error after deploying
Title: 500 Internal Server Error after deploying Here's the deal, I set up and deploy an ear file and i try to run the associated servlet and i get 500 internal server error. Now the kicker is i have succesfuly deployed some of the other beans. I really have absolutely no clue what i am doing wrong this time. I will spend more monday and disect it. However does anyone know what i could be missing? Nothing is being written to log file or in the system.out.println's I am at a loss ... and trying to figure it out so i never do it again. (btw i am used BMP bean and a servlet) to start it out
Documents and dynamic web pages
I am aiding a department that is using a two tier application design, with a JSP engine and Oracle, to build a dynamic web site. It's easy to deal with images, by either using a URL link, or a BLOB field in Oracle. Now I wonder how to deal with documents. Is it best to store them as BLOBS, or perhaps PDF files, and use software such as www.pdflib.com to transform them. Any suggestions on the best approach. __ Do You Yahoo!? Get personalized email addresses from Yahoo! Mail http://personal.mail.yahoo.com/
Setting Up JDBC driver for Oracle database
Hello, I am trying setup Orion to communicate with an Oracle 8.0.5.1 database. I've obtained the JDBC drivers from Oracle, but I'm confused about what I should be doing next. The Orion documentation says I need to copy the driver to the Orion\lib directory and add a data source in data-sources.xml; but what fields do I change and what values should I use? Can anyone, perhaps someone who uses Orion and Oracle, help clear up this process for me? Thanks in advance, Mong Kon Mo
RE: Documents and dynamic web pages
Hi. Here is ths Oracle DS sample. We use thin driver. (orion 1.5.2) -- data-sources.xml ?xml version=1.0? !DOCTYPE data-sources PUBLIC Orion data-sources http://www.orionserver.com/dtds/data-sources.dtd; data-sources !-- An example/default DataSource that uses an ordinary JDBC-driver (in this case hsql) to create the connections. This tag creates all the needed kinds of data-sources, transactional, pooled and EJB-aware sources. The source generally used in application code is the EJB one - it provides transactional safety and connection pooling. -- data-source class=com.evermind.sql.DriverManagerDataSource name=Your Name location=jdbc/Your Name xa-location=jdbc/xa/Your Name ejb-location=jdbc/Your Name connection-driver=oracle.jdbc.driver.OracleDriver username=Your ID password=Your Password url=jdbc:oracle:thin:@192.168.1.21:1521:ora8 schema=database-schemas/oracle.xml max-connection=50 inactivity-timeout=30 / /data-sources
RE: Setting Up JDBC driver for Oracle database
Mong, Here's a data-sources.xml I use with 8i, I don't know if it will work with 8, though: ?xml version=1.0? !DOCTYPE data-sources PUBLIC Orion data-sources http://www.orionserver.com/dtds/data-sources.dtd; data-sources data-source class=com.evermind.sql.DriverManagerDataSource name=ora data-source location=jdbc/MyDS xa-location=jdbc/xa/MyXADS ejb-location=jdbc/MyDS connection-driver=oracle.jdbc.driver.OracleDriver username=scott password=tiger url=jdbc:oracle:thin:@mymachine:1521:ora inactivity-timeout=30 schema=database-schemas/oracle.xml / /data-sources Regards, the elepantwalker -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Mong Kon Mo Sent: Friday, June 29, 2001 4:58 PM To: Orion-Interest Subject: Setting Up JDBC driver for Oracle database Hello, I am trying setup Orion to communicate with an Oracle 8.0.5.1 database. I've obtained the JDBC drivers from Oracle, but I'm confused about what I should be doing next. The Orion documentation says I need to copy the driver to the Orion\lib directory and add a data source in data-sources.xml; but what fields do I change and what values should I use? Can anyone, perhaps someone who uses Orion and Oracle, help clear up this process for me? Thanks in advance, Mong Kon Mo
Re: Setting Up JDBC driver for Oracle database
data-sources data-source name=Devel One DS class=com.evermind.sql.ConnectionDataSource location=jdbc/DevelOneCoreDS pooled-location=jdbc/DevelOnePooledDS xa-location=jdbc/xa/DevelOneXADS ejb-location=jdbc/DevelOneDS schema=database-schemas/oracle.xml url=jdbc:oracle:thin:@samoa.spottedfly.com:1521:DEV1 -- change to your host and SID connection-driver=oracle.jdbc.driver.OracleDriver username=mySchemaName password=myPassword / /data-sources peace - scot Mong Kon Mo wrote: Hello, I am trying setup Orion to communicate with an Oracle 8.0.5.1 database. I've obtained the JDBC drivers from Oracle, but I'm confused about what I should be doing next. The Orion documentation says I need to copy the driver to the Orion\lib directory and add a data source in data-sources.xml; but what fields do I change and what values should I use? Can anyone, perhaps someone who uses Orion and Oracle, help clear up this process for me? Thanks in advance, Mong Kon Mo -- scot weber - [EMAIL PROTECTED] - Given a choice between a folly and a sacrament, one should always choose the folly -- because we know a sacrament will not bring us closer to God and there's always a chance that a folly will. - Erasmus The only man who never makes a mistake is the man who never does anything. - Theodore Roosevelt.