Re: java.lang.OutOfMemoryError in Product Application
This is a known bug. A workaround was posted a while back. I have since moved to another company and dont have an installation of orion here so Im going from memory here. there should be some class in the orion API like com.evermind.Administrator which has a function flush() (static I believe) which flushes theentities from memory. Sven Globetrot Communications wrote: Could it be that Orion does not passivate entity beans, thus running out of virtual memory? I was able to restart the ProductClient and continue adding to the table. Does anybody know of a solution better than having to stop and restart? Thanks --- Globetrot Communications [EMAIL PROTECTED] wrote: I am populating a postgreSQL database with "Product" entity beans. I get a java.lang.OutOfMemeoryError After adding about 200K entries. Am I getting this error because all these entity beans stay in memory? Is there a work-around it besides increasing the -mx option value? How can one to create number of objects limited only by the disk-space? Thanks for your help. while (true) { // Create a new Product and narrow the reference. Product product = (Product)PortableRemoteObject.narrow(home.create(i), Product.class); name = "product"+i cost = i; product.setName(name); product.setPrice(cost); } Satish __ Do You Yahoo!? Yahoo! Auctions - Buy the things you want at great prices. http://auctions.yahoo.com/ = __ 5.5 cents calls with 6-second billing no fees. Free toll-fre numbers. No other charges 4 cents Domestic calls with no fees: 5 cents per minute International calls also available http://globetrot.hypermart.net e-mail: [EMAIL PROTECTED] __ __ Do You Yahoo!? Yahoo! Auctions - Buy the things you want at great prices. http://auctions.yahoo.com/
Re: Problems authenticating
I have seen that error once.. When I had my form tag like: form action="some_action" method="post" I had the error, I then changed to: form method="post" action="some_action" and for some reason my troubels disappeared. sven Matt Bauer wrote: I have a simple app (very similiar to the pet store) that uses form based login. I can created an account and see it created in the appropriate principals.xml file. The problem is every time I use my form based login I get an error: 400 Bad request: HTTP method POST is not supported by this URL. My form uses action="j_security_check" method="post" just like its suppose to. Any one know why this fails. Also, I plan on using EJBUserManager, but the docs for it stink. What do I have to add to my orion-application.xml or other xml files to make this thing work? Thanks M
Re: class cast exception
PhoneEntryHome home = (PhoneEntryHome) boundObject; should be : PhoneEntryHome home = (PhoneEntryHome)javax.rmi.PortableRemoteObject.narrow(boundObject, PhoneEntryHome); Marcus Lankenau wrote: Hi! I've started developing a very simple phonebook application for learining purpose. The app consists of an ejb and a servlet adding and showing the phone entries. The servlet is running quite well at home, but in office I get this exception: Exception caught: java.lang.ClassCastException: PhoneEntryHome_EntityHomeWrapper14 while casting the homeinterface: Object boundObject = context.lookup("java:comp/env/ejb/PhoneEntry"); PhoneEntryHome home = (PhoneEntryHome) boundObject; Any idears what is going wrong? thx in regards Marcus Lankenau -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Stand alone client needs orion server?
Guilherme Ceschiatti wrote: Hi... I need to know if it's necessary to have orionserver in the client. If so, It's necessary to start it or just put the jar's in the class path? client needs: orion.jar jndi.jar ejb.jar application-client.xml the jars need to be in the classpath sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Running two instances of Orion on the same IP and port
Larry Velez wrote: I know that binding a second IP to the box and having the second Orion listen on that IP would probably work. Is there an obvious reason that the way I am attempting always gives me an "Error starting HTTP server: Address already in use" error on the second instance? Yest there is, there can be only one HTTPD listening to the same port. You could run have the other instance listen to 8080 for example. I don't think binding another ip to the box will help you eiter. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Huge amounts of entities, no pooled instances
Yesterday I posted a question about batch updating in Orion. Orion is creating huge amounts of instances of my entity without pooling. Someone mentioned that my updates possibly would be inside the same TX. Actually I'm using updating 2 tables, in one table, There is only 1 entity ised and it's pooled, the other one creates huge amounts of entities. (One for each line in my file, there are some 20 lines to each file and sometimes a Deadlock occurs due to an OutOfMemoryException). I have now set the Tx attribute to my update and remove methods to RequiresNew, but still one bean is creating huge amounts of Beans while the other is pooling. Here's the updater method of my session bean: public boolean update(ContaEncerradaModel m, String nome){ boolean result = false; try{ try{ Ccf ccf = ccfHome.findByPrimaryKey(new CcfPK(m.getCgcCpf(), m.getBanco(), m.getAg())); ccf.setQt(m.getQty()); ccf.setDate(m.getDate()); result = true; } catch (FinderException ex){ // if we cant find it we need to create it try{ ccfHome.create(m.getCgcCpf(), m.getBanco(), m.getAg(), m.getQty(), m.getDate()); result = true; } catch (CreateException exc){ result = false; } } try{ // no need to set result in this block, since we anly want to know about ccf // here's where only one instance is created, it's activated and passivated constantly. the CCF part however keeps creating instances without passifating. // nHome.create(m.getCgcCpf(), nome); } catch (CreateException ex){ //this probably means we already have the name, so forget it } } catch (Exception ex){ System.out.println(ex.toString()); } finally { return result; } } -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: AW: Huge amounts of entities, no pooled instances
"Haeussler, Heinz" wrote: Hello Sven, it's an old problem of orion and the only legal way to reduce the EJB-Entity-Pool is to press the "Flush"-Button in the orion-console. Please search in the mailing-list with the key "pool" and you will get interesting mails discussing this problem. Ok, I found the workaround in the mailing list: import com.evermind.server.administration.*; snip Context context = new InitialContext(); Object o = context.lookup("java:comp/Administrator"); ApplicationAdministrator admin = (ApplicationAdministrator)javax.rmi.PortableRemoteObject.narrow(obj, ApplicationAdministrator.class); snip admin.flushEJBCache("name of your entity-bean"); snip and I've added a finally block to my try{}catch{} blocks. This seems to work, the bean is passifating now and the application uses only 1 pooled instance of the bean. However, IMHO this is something the container should be taking care of for me. I'm taking a look at Bugzilla to see if there is any report on this. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: AW: Huge amounts of entities, no pooled instances
"Haeussler, Heinz" wrote: Hello Sven, it's an old problem of orion and the only legal way to reduce the EJB-Entity-Pool is to press the "Flush"-Button in the orion-console. Please search in the mailing-list with the key "pool" and you will get interesting mails discussing this problem. Heinz I found the bug report it's #174. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Follow Up on BUG#174: batch updates entities do not get passivated.
I'm currently running my batchupdates with the earlier proposed workaround: import com.evermind.server.administration.*; snip Context context = new InitialContext(); Object o = context.lookup("java:comp/Administrator"); ApplicationAdministrator admin = (ApplicationAdministrator)javax.rmi.PortableRemoteObject.narrow(obj, ApplicationAdministrator.class); snip admin.flushEJBCache("name of your entity-bean"); snip This works perfectly. Only 1 entity bean instance gets created. CPU usage wich earlier was at 100% corrently stays around 53% and significantly less memory is used. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Anyone debugging Orion applications in JBuilder (no jdpa)
Michael Rimov wrote: Set the project working directory to the orion root directory. (You need JBuilder4 for this) Nope works just fine with 3.5 too. I missed that one on the first try though. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Anyone debugging Orion applications in JBuilder (no jdpa)
Suresh Ajja wrote: I am using JBiulder4 ,In the Tools, enterprise set up i could only see two options to add app server, i.e. IAS and Weblogic, I set my working dir. as orion as root, but how to add AppServer. need help Suresh Take a look at www.orionsupport.com. It explains how to debug orion ejb's in JBuilder. Allthough it says you can only do it with JBuilder 4.0, It also works for JBuilder 3.5. The author forgot one option however. You must run not only with -classic, but also with -Duser.dir=/path/to/orion. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Used Instances
In Orion console, what does 'Used Instances' denote? I'm doing batch updates to a database (about 20 daily) and about three quarters on the way, Orion console shows some 59000 used instances of my entity bean somewhere after that, my application crashes with a DeadlockException and shows that the nested exception is an OutOfMemoryException. I'm at a loss here, does Orion actually keep these 59000 entity beans in memory ?? Shouldn't these be pooled ?? (Pooled instances shows 0!!). I'm currently testing the application and would like to know if there's any way to have these beans pooled. The app that does the batch updates is a simple class, it reads the lines in a file and then calls a session bean (stateless) through either of two methods (update or remove) update checks for excistence of the entity, if exists, it sets some values, when a FinderException gets thrown, it calls ejb.create(). remove finds the bean and calls ejb.remove(). I read in the specs(9.4.1): The container can choose to passivate the instance (...) Th container invokes the ejbPassivate() method when the container wants to disassociate the instance form the entity object without removing the entity object. I've been printing some output to stdout telling me when a bean is activated and when it's passivated but sofar as I can see, ejbPassivate() is never called. Is this some bug in Orion or am I getting mad??? I'm using 1.3.8 sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Orion In Prodution
"Juan Lorandi (Chile)" wrote: There's a list of Overwhelming Orion Powered Sites, hosted by Jason Rimmer at http://orion.irth.net/OOPS/oopslist.jsp where you can add your site(s) to the list... everyday I moderate the list so that new entries appear on the official list... Today however it's like. empty. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Anyone debugging Orion applications in JBuilder (no jdpa)
I'm trying to debug my ejb apps in orion. I get Orion to run inside JBuilder no sweat. However it tries to locate the config directory relative to my project.jpr file and not relative to the orion base directory. Any ideas?? sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Anyone debugging Orion applications in JBuilder (no jdpa) !!!! SOLVED
Sven van 't Veer wrote: I'm trying to debug my ejb apps in orion. I get Orion to run inside JBuilder no sweat. However it tries to locate the config directory relative to my project.jpr file and not relative to the orion base directory. Any ideas?? ok I forgot the -Duser.dir=d:\orion option sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: DB changes not reflected in CMP bean.
Winston Ng wrote: Hi All, This is more of an EJB question. I wrote a simple app using a CMP bean that talks to an Oracle DB. Started the server and was able to get/set information to the bean and subsequently see the changes in the DB. However, if I make any updates to the DB from sqlplus and commit the changes, they are not reflected in the Entity bean! The changes are only reflected if I restart Orion. Is this normal? What should I do to have the bean reflect changes in the database? Is that what BMP bean is for?? Yes that is absolutely normal. You can however in orion-ejb.xml set exclusive-write-access="false" in entity-deployment. Sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Anyone using Orion in production?
Paul Kofon wrote: Hi, I'd like to know, is anyone currently using Orion in a production environment? The rather high number of issues people report here bothers me because I'd like to get serious with a particular EJB server and my opinion was that Orion was the right choice because of it's low cost and features. I've trying out orion and Inprise Application Server at the same time a while ago, following the orion list and the Inprise Application Server newsgroup and I must say the number of issues in the orion group are much lower than in the IAS forum. Most issues with orion relate to the EJB 2.0 spec which is implemented in Orion but still sortof in the BETA FASE (ejb 2.0 isn't even final yet). E couple of weeks ago a list passed with sites using Orion in Production and the list was rather long. In addition, I'd like to know if Orion's HTTP server is suitable for production work, I really would like to have a unified environment instead of having a separate web server for my JSPs and servlets. Eventhough not all my projects are JSP/Servlet/EJB i've started moving all my sites form Apache to Orion. The Orion HttpServer is quite fast and stable (Ok, not as stable as Apache, it might crash every two weeks or so but usually related to a bug in a jdbc driver i'm using). Sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Anyone using Orion in production? [long]
my personal opinion on this is that evermind should deliver source (while retaining full rights on enhancements and bug fixes) with the product to eliminate that risk. other commercial projects like orbaccus (http://www.ooc.com) have shown that they still make a lot of money despite shipping source for more than five years now. I'm sure about 80% of the bugs our team has reported would have been fixed by us immediately or at least would have been accurately described to the line of source code that has to be changed. I've brought this up to karl and magnus but they don't want to do this and it simply is their baby and therefore their decision (they probably think I'm either a parrot or insane, repeating the same stuff over and over again ;-). Well you're no parrot and neither insane. I agree wholeheartedly. Before moving to Java I did a lot of development on Borland C++ Builder which ships with full source code to the vcl libraries. Serious bugs where easilly found by me and other developers, reported and corrected. It's lot's easier to report a bug if you can see the source code. However I can sympatize with Karl and Magnus. EJB is a very new technology. Shipping the source makes it relatively easy for the competition to copy the product which of course is the downside. But I think shippingg the source would be for the better of the server. Nobody is perfect and if all of us have our hands on the source lots of those silly bugs should be fixed in much less time. Having to submit a testcase makes for a lot of effort on both sides since we have to create a testcase which has to be recreated by the orion team and tested. Most of these bug however would simply appear running your app through a debugger and jumping into the orion source. any other orion users have an opion on that? This was my two-cents. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: JetSpeed
"J.T. Wenting" wrote: using Js 1.2b1, which works fine on Tomcat 3.1 (at least it does not throw any errors, the generated HTML is not always as it should be and there seems to be a gaping memory leak). The error is as stated "could not find package in import: org.apache.cocoon.*, org.w3c.dom.*, etc...). I tried putting all jars in /orion/lib, web-app/WEB-INF/lib and even putting them all in both locations. It happens when accessing XSP only (as far as I can tell), the frontpage displays correctly for example. For me, putting the Jetspeed jars in /orion/lib gives me the following error when calling http://hostname/servlet/jetspeed java.io.FileNotFoundException: /tmp/turbine.log (O sistema não pode localizar o caminho especificado) at java.io.FileOutputStream.openAppend(Native Method) at java.io.FileOutputStream.init(FileOutputStream.java:100) at java.io.FileWriter.init(FileWriter.java:39) at org.apache.turbine.util.Log.init(Log.java:112) at org.apache.turbine.util.Log.clinit(Log.java:102) at org.apache.turbine.services.TurbineServices.getService(TurbineServices.java:115) at org.apache.turbine.services.resources.TurbineResourceService.setPropertiesFileName(TurbineResourceService.java:107) at Turbine.init(Turbine.java:120) at com.evermind.server.http.HttpApplication.wo(JAX) at com.evermind.server.http.HttpApplication.v6(JAX) at com.evermind.server.http.HttpApplication.uh(JAX, Compiled Code) at com.evermind.server.http.ed.sp(JAX, Compiled Code) at com.evermind.server.http.ed.so(JAX, Compiled Code) at com.evermind.util.f.run(JAX, Compiled Code) DbBrokerImpl: Is now turned on. java.lang.ExceptionInInitializerError: java.lang.NullPointerException at org.apache.jetspeed.turbine.navigations.JetspeedTopNavigation.clinit(JetspeedTopNavigation.java) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java, Compiled Code) at org.apache.turbine.modules.NavigationLoader.getInstance(NavigationLoader.java, Compiled Code) at org.apache.turbine.modules.NavigationLoader.eval(NavigationLoader.java:118) at org.apache.jetspeed.turbine.layouts.JetspeedLayout.build(JetspeedLayout.java:86) at org.apache.turbine.modules.LayoutLoader.exec(LayoutLoader.java:111) at org.apache.turbine.modules.pages.DefaultPage.build(DefaultPage.java:88) at org.apache.turbine.modules.PageLoader.exec(PageLoader.java:111) at Turbine.doGet(Turbine.java, Compiled Code) at javax.servlet.http.HttpServlet.service(HttpServlet.java) at javax.servlet.http.HttpServlet.service(HttpServlet.java) at javax.servlet.http.HttpServlet.service(HttpServlet.java) at com.evermind.server.http.d1.si(JAX, Compiled Code) at com.evermind.server.http.d1.forward(JAX) -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: help...servlet claspath
Edmund Cheung wrote: Hi, In weblogic, I defined the servlet classpath in the weblogic properties file as follow; weblogic.httpd.servlet.classpath=D:/weblogic/myserver/servletclasses weblogic.httpd.register.UserManagerController=servlet.UserManagerController In my jsp, I call thsi servlet name form method="post" action="/UserManagerController" In Orion, I defined the following in web.xml but where should I define the classpath for servlet ? servlet servlet-nameUserManagerController/servlet-name descriptionUser manager controller/description servlet-classservlet.UserManagerController/servlet-class .. /servlet Thanks reagrds, Edmund Actually you don't have to do anything in Orion. Just putting the classfile for the servlen in orion/applications/your_app/your_app-web/WEB-INF/classes makes the servlet available to Orion by calling: http://localhost/servlet/YourServlet sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: EJB Assembler tool
Alexander Sparkowsky wrote: Did somebody successfull use the EJB Assembler tool? When adding a bean the tool tells me that it is unable to find the bean class also if I add the classes to my classpath. The EJB Assembler is a funny tool.. Let's say you hae an app called myapp myapp/META-INF myapp/myapp-ejb.jar myapp/myapp-web etc. To open the EJB application, you should point the assemblet to myapp-ejb.jar (even though it's a directory and not a jar at all). If it succeeds to open the jad(ditectory) you'll see all the classes appear unde [+]-Files. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
JetSpeed
Is there anyone who has gotten Jetspeed to work under Orion ?? sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: JetSpeed
"J.T. Wenting" wrote: I asked the same question last week and got no response. There seems to be a versioning problem between Jetspeed and the Orion XML stuff. My problem seems to be that it cannot find some of the Turbine stuff. http://server/servlet/jetspeed produces a blank page. Have you got any further ?? sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: ciphering URLs
Ismael Blesa Part wrote: Hi all, I am trying to cipher some of the parameters that are sent to my application Server. I am having some problems with the conversion from String to an array of bytes. Sometimes the conversion losts info. Have any of you already solved this issue. I'm not using a cipher, but a simple MD5 hash: private void addAssinatura(){ try{ MessageDigest md = MessageDigest.getInstance("MD5"); char[] chtext = text.toCharArray(); byte[] bytes = new byte[chtext.length]; for (int i = 0; i chtext.length; i++){ bytes[i] = (byte)chtext[i]; } md.update(bytes); String sign = ""; byte[] digest = md.digest(); for (int i = 0; i digest.length; i++){ sign += String.valueOf(digest[i]); } text += "Assinatura: " + sign; this.key = sign; } catch (Exception ex){ text += "Erro interno. Não foi possivel assinar texto"; } } -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: help ! classpath to the shared jar files or class files
Edmund Cheung wrote: I have non-ejb classes ( called share.jar)are used by all ejb jar files and how do I let Orion know to use this jar file for the ejb jars files ? Define the classpath somewhere ? I have got the error below while deploying the ejb jar files. Thanks for your help. just place them in the /path/to/orion/lib directory and they will be loaded on startup of Orion sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: orion server works with jdk 1.3???
"J.T. Wenting" wrote: check and doublecheck (goes for *nix too). For example Oracle installs its own JVM without asking or telling you. If you choose custom setup you will see 1.1.7 in the list of installed items, but removing it from the install has no effect,it is still installed... This caught us by surprise once, installing Oracle left all our Java2 stuff inoperable :( It's not just Oracle though. DB2 v7.1 comes with IBM JDK 1.1.8 (WIN NT) and without JDK on Linux. On windooze it screws up your install, however on Linux you need to manually install IBM JDK1.1.8 since it does not run on SUN or Blackdown. All these near 100% java Databases are sortof cool, but it would be nice if they could at least run on the before-last stable Sun jdk (1.2.2 for example). sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: SQL Server - Autoincrement Primary Keys
Chris Miller wrote: Hi all, This is possibly more of a generic EJB question, although maybe not since Orion has to implement the persistence... I was wondering if it is possible to use CMP beans against an existing SQL-Server database that has autoincrement primary keys. It's not possible to insert a value for the key (have to supply null), so using something like counter.jar to override the PK generation is not an option. Has anyone done this successfully? What's the trick, or am I stuck with BMP (as I suspect is the case)? Using auto incrementing fields in EJB is not very usefull since they may map to databases not supporting such features, it's just like stored procedures. They might seem to look like a good idea, but it just makes the application much less portable. Orion includes an EJB which can generate a unique id for you, it's in counter.jar (I think you can find it in the news app). However if you really have to use an existing DB, you're either stuck with using BMP or you could write an entitybean (CMP) which only does the updates for you and may delete te bean by calling remove on the bean and a stateles session bean that handles the insertions for you. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: EJB Basics
"Mark A. Richman" wrote: What is the difference between WEB-INF and META-INF? How do these directory structures relate to jar, ear, and war files? Which of these is J2EE, and which is Orion-specific? Maybe I am confusing something with Tomcat... - Mark BOTH are J2EE. META-INF contains application specific information in the application-root/META-INF/application.xml META-INF in the application-ejb.jar contains the deployment descriptor for the EJB's contained therein. WEB-INF in the application-web.WAR (WEb ARchive) should contain web.xml which describes the web application and should supply informatuion about the EJB's contained in application-ejb.jar that the web application needs to use. The EAR (Enterprise ARchive) contains both the application-ejb.jar and the application-web.war files. The EAR file should be a portable application deployment unit. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: SQL Server - Autoincrement Primary Keys
Shayne Hughes wrote: I'd be interested to hear what others think of this method of using MSSQL's autoincrement type as PK. I have tried this and it seems to work in simple tests. Yeah it's not portable and probably breaks several rules. For this table... CREATE TABLE [dbo].[Lab] ( [LabID] [int] IDENTITY (1, 1) NOT NULL , [Name] [varchar] (255) NOT NULL , [LastUpdate] [datetime] NOT NULL ) I have an CMP EJB with the following in the orion-ejb-jar.xml... finder-method query="insert into Lab (Name,LastUpdate) values ($1,GetDate()); select LabID,Name,LastUpdate from Lab where LabID=@@IDENTITY" partial="false" method ejb-nameLab/ejb-name method-namefindNew/method-name method-params method-paramjava.lang.String/method-param /method-params /method /finder-method So, you never create a new bean in the normal CMP way, but if you need a new one, you call this finder which creates a new one and finds it. This is a really cool workaround ;-) sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Newbie Q: Can't find bean?
"Sean P. McNamara" wrote: In addition to the specification, I have a copy of the Monson-Haefel book on Enterprise JavaBeans, but there is virtually no mention of JSP-EJB interaction. I also spent some time earlier today browsing JSP-centric books in the local bookstore, and found little mention (usually about 1 paragraph) regarding EJB's. I agree with you, it's hard to find information on that subject. I've been reading this list and the sun J2EE interest for a couple of months now and am almost ready doing my first complete EJB / JSP app. The thing I found is as follows. It seems that by using a tag-lib you can use your EJB directly in your jsp's, but the general opinion in this list and others is that the way to do such things is by creating 'common' java beans or classes to use with the jsp:useBean tags in the jsp. These classes than refrence stateful or stateless session beans, which in turn reference the entity beans. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Web upload of a Java class
Storm Linux User wrote: It's not form commercial use. It's for my research project for getting my master's degree in Electrical Engineering ... I'm not concered about securety right now. Hmm as long as you're not pursueing a masters in computer security.. Take a look at http://www.servlets.com and get the /com/oreilly/servlet package. It contains a class called MultiPartRequest, which should help you upload the file to your server. Then all you should do is have your servlet copy the file from te location from where it was uploaded to the location from where you can run the classfile.. It's quite dangerous thou ;-) sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: HELP! Confused about CMP and Primary Keys
Vidur Dhanda wrote: OK, Now I'm thoroughly confused.Would someone please help me before I confuse myself even more. Here's the question/scenario: I have a primary key, public class PK implements Serializable { public String fooGuts; constructor/get/Set ... } The only way it seems to work is by having a String member in the Entity bean -- fooGuts. But that seems primitive. I know the EJB 1.1 spec says the for _composite_ primary keys ... But to my thinking this is more of a OR problem -- I have a CMP field (that happens to be the primary key) and I want to control its relational representation. And with all the nice OR stuff in Orion, it must be possible. My only constraint is that I have to adhere to EJB1.1. You'll need that public string for cmp to work. The primary Key class should contain the primary key field in your table (as a public field) so oruion can manipulate it. Take a look at yeh EJB sprec, section 9.4.7.1 and 9.4.7.2 sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Get the web uploaded file
Storm Linux User wrote: form method="post" action="my_servlet" input type="file" name="my_class_file" input type="submit" /form Your form tage is missing the ENCTYPE="multipart/form-data" tag. Without this your page does not return a file. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Properties
"Magnus Naeslund(b)" wrote: Shouldn't that do? Or is /WEB-INF special? According to specs WEB-INF/classes is where your (non-jarred) classes should go and WEB-INF/lib is where you should put your .jar files (e.i. your mail.jar). I suppose your jar should work if you put it in /WEB-INF/lib and place the properties file there as well. Take a look on /orion/doc/application-howto.html (might be application-creation-howto.html) sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Non-Commercial
"Lee, Se Hee" wrote: Sorry for stupid question... Anyway, it seems like Orion server is free for non-commercial usage Does that mean that for non-profit organizational use, it's free??? or is it for development license? Se Hee Nope if you're not making profit, it's free.. Sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Servlet regains control after execution of .Forward()
Grant Doran wrote: getServletContext().getRequestDispatcher("/index.jsp").forward(request, response); } else { System.out.println("[GATEWAYSERVLET]Authentication failure. Username:[" + username + "] Password:[" + password + "]"); request.getSession().setAttribute("LoginFailure","true"); BUGGER ME! I AM HERE AFTER ALL How can this be? Execution of the servlet(thread) is supposed to cease immediately and control handed to the target. Am I missing something? You might want to try to return from your method ;-) Forwarding a request does not mean that execution of your method does not continue. Just like in any code, control reverts to the method after forward returns. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Does Orion support CMP using user defined types?
Ken Shitamoto wrote: Does Orion support CMP using user defined types? e.g. oracle objects? You can set the percistance-type in the orion-ejb.jar sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Please Help with Orion Debuging (Third Post !) Please Help !!!
[EMAIL PROTECTED] wrote: Greetings ! I have migrated my ejb to Orion, these ejb has System.out.println("flags") that Orion doesn't show in the console. I'm runing orion in this way:java -jar Orion.jar I don't know if I have to run orion in an special way or do any configuration in order to get that orion show the System.out.println("flags") in the console ? thanks Don't understand what goes wrong. I print to stdout all the time using orion -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Problems with CMP PrimKey...
"Sean P. McNamara" wrote: It turns out that it wasn't finding it since the attribute was private. Does this mean that all my attributes in a CMP bean need to be public? If so, I'm not sure why, since reflection since JDK1.2 allows you to view private attributes based on security properties. When using CMP al the fields in your entity bean that use CMP, including your primary key field need to be public (see EJB spec section 9.4.1) since the container must have acces to these fields (it does not call get/set methods to access the data). sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
EJB 1.1 findByPrimaryKey in orion 1.4.3 broken ?
I'm developing an EJB app for a while now on orion. The last version I had installed was 1.4.0. Most of my app was already working like a beauty. Today I auto updated to 1.4.3 and it seems that findByPrimaryKey where the primary key is a comppound primary key, got broken. I did some test and all my calls to findByPrimaryKey(java,lang.String) seemed to work. However all calls to findByPrimaryKey(new PrimaryKeyClass)) throw a finder exception. I reverted back to 1.3.8 which is running on an other machine, copying orion.jar to my dev box and all worked perfectly again. Has anyone seen this??? orion-team It would be very nice if autoupdate.jar would create a backup for the updated files for example in the form of: orion/backup/xxx.jar.version.no this would enable us to revert back to the last stable version some more graciously. /orion-team sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Orion System Requirements
Unico Hommes wrote: I was wondering what are the recommended and/or minimum system requirements for running Orion Server. I have a 100 Mhz Pentium - 24 Mb memory linux box which I want to use for testing and developing web apps with Orion server. Will this work ? I didn't find this info anywhere in the faq etc. on the Orion website. Up till a few months ago I ran a web application on Linux (RH 6.2) SunJDK1.2.2RC4 on a Pentium 133 with 48 megs and no problems whatsoever. The app is small and has only about 3000 acesses a day, but I've seen no hicups yet (I expanded memory to 112 megs to accomodate sybase on the same machine) performance for this site is great considering most accesses are done by modem 33.6 k. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Orion and Windows 2000 Professional
Jan Tye wrote: I have an application which runs fine under Windows 98, Orion 1.3.8 and JDK1.3 When the same application is run under Windows 2000 Professional (SP1) I get the access violation shown below during database connection. D:\orionjava -jar orion.jar Orion/1.3.8 initialized Database connect failed.. # # An EXCEPTION_ACCESS_VIOLATION exception has been detected in native code outside the VM. # Program counter=0x77fca8ef # # Problematic Thread: prio=9 tid=0x9d7f60 nid=0x424 runnable # The application uses the standard JDBC connection code shown below. I've seen this too. I don't think it has something to do with win2000 as I was using NT at the time ;-) Its a problem of Orion w/ JDK 1.3. Try substituting for JDK1.2.2. Anyone seen this too?? Might it be a bug? sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Adding a site? - (2nd Post)
Thomas DeBruycker wrote: 3) Added the line web-site path="./TestSite.xml" / to server.xml you missed adding : application name="TestSite" path="../applications/TestSite/" /" to server.xml (ahead of the web-site path You have to remember, Orion is an Application Server and not a WebServer it does not understand a web application without a base application eventhough you're not using any EJB. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
orion-ejb.xml
I was under the impression that changes manually made to orion-ejb.jar, however, every time I change the following line: cmp-field-mapping name="date" persistence-name="date_" / to: cmp-field-mapping name="date" persistence-name="date" / and redeploy, Orion changes it back. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
orion-ejb-jar.xml
Ok I sortof figured it out. Both password and date have disallowed-field tags in the sybase.xml (database schemas) However, I have two tables using these field names, one of which has more than 7 million records in the table. I can't find anywhere in my sybase docs however that these field names are disallowed. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: REPOST: Help with Finder query
Vidur Dhanda wrote: finder-method query="$source-getUsername() = $1" file:/C:/dev/lib/: Unable to process query: source was not a property/field mapped field (invalid '.' use) at column 16 in query '?source.username = ?1' in the finder-method tag, use the cmp-field-name you defined in your bean e.i.: your bean public String username; finder-method query="$username = $1" sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Deployment to Orion
Hegyi Tibor wrote: Hi, I am quite new to Orion Server (and to the Orion-Interest mailing list) and have been dealing with it for three days. I feel desperate now because I am trying to install a simple (one-class) test servlet but still to no avail. Unfortunately, Orion does not provide too much examples on deploying applications. I have ever tried to use the graphical tools but also failed. Please help me deploy the simple class file as a servlet to the default web site. I'd expect some step-by-step description (what files to edit and what to write in those files). I'd really thankful for any help. Orion comes with an application-how-to.html. There is also some info on http://www.jollem.com. However deploying a servlet should not be such a big deal. if it does not exist, create a directory in the /path/to/orion/default-web-app WEB-INF/classes and drop the class file in this directory. Due to defualt servlet mapping, orion should be able to find it with an url like: http://localhost/servlet/YourServlet if it does not, edit the web.xml (in default-web-app/WEB-INF) to include something like: servlet servlet-name YourServlet /servlet-name servlet-class your.package.YourServlet /servlet-class /servlet servlet-mapping servlet-name YourServlet /servlet-name url-pattern /YourServlet /url-pattern /servlet-mapping that should do the trick -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: choosing database for EJB use?
James Ho wrote: Hi all... Can anyone pls tell me, is there any searching criteria for RDBMS for use with EJB/Orion and why? Is transactions support necessarily for CMPs? No transaction support is not necessary. However if you use a RDBMS without transactions, your EJB application will not support transactions. If you're looking for a db that has transactions and is free, i'd recomend Sybase 11.3. It's free on Linux. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: MYSQL, Orion, EJB and transactions ??
"Laufer, Michael" wrote: Hi there, If I understood it correctly, that would mean, that it should be possible to use mysql with entity beans. Am I right ?? What's confusing to me is the fact, that I only find news in mailing-list, that mysql is not supporting transactions. Havent been with mysql for a while, but AFIK, transactions are supported in version 3.23.27. So I don't really now, if I can use mysql for entity beans. You can use mysql for Entity Beans without any problems. You should be aware however that there will be no trnasactions if the DB does not support them. If not, which database would you suggest ?? It should work on NT and not be the most expensive one as I use it 'only' for writing my Master's Thesis. Unfortunately, you work on NT. Various free databases can be found for Linux, even sybase has a free version of it's ASE database. However since you're using Orion take a look at Cloudscape. It runs in process. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
excerpt from TheServerSide newsletter.
Slightly OT. I found this in my mailbox this morning ;-) * Being compliant with the latest specs. BEA and Orion have shined here. BEA was 6 months ahead of the pack with their EJB 1.0 product, which positioned them extremely well. Orion has unofficially been supporting many of the latest J2EE specs (probably the first independant vendor to support EAR files). BEA and Orion are currently the market leaders in EJB 2.0 compliance. Both vendors have had EJB 2.0 beta features for months now, and are close to full support. * Ease-of-use. Again, BEA and Orion get top marks here. Installing BEA application server on a Unix machine has been a simple process of unzipping a file. Deploying a complete J2EE application in Orion requires adding an EAR file and two lines to the Orion config files. Some other vendors have been much more complicated, which creates undue confusion for developers. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: rumors
Frank Kettenbeil wrote: is this a rumor or a joke ? just found it on bugzilla of Orionserver.com... as a headline "BEA Closes Acquisition of Orion - The transaction is valued at approximately DM 582 million (US$283 million). " But if it's true.. we're F%$^*^ sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Problems with EJB.
fresnaULL wrote: Hi all, I think I've deployed correctly a EJB, because I'm able to use from a java application. I've deployed the ejb like the cart ejb example. My problem is that when I try to use it from a servlet the context.lookup doesn't find the EJB and generate an exception. Please I need help!!! Thanks. did you add ejb-ref 's to the web.xml?? -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re:
Naveed Ahmad wrote: Hi, How can I enforce, that the whole bean and jsp page is executed before the processing for the next quesiton starts. I feel that it should be the web servers responsibilty to queue and sysnchronise. But it is ot doing suh. That's not the responsability of the webserver since http is a stateless protocol. I had a similar problem with clicking on a button when the form is already posted, but the resonse not yet sent. What I did was decalre a var (javascript) and set it to false like so: script language="javascript" buttonClicked = false; function formPost(){ if (buttonClicked){ return false; } else { buttonClicked = true; return true; } } /script in your case you could do simething similar: script language="javascript" formLoaded = false; function setPageLoaded(){ formLoaded = true; } function someButtonClicked(){ return formLoaded; } /script body onLoad="setPageLoaded()" sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Anyone using Interbase in production?
Jim Archer wrote: Does anyone here have any experience with Interbase in a production environment? We are trying to decide which database to deploy in production. Since we are a very low budget operation, we are looking at Open Source, but somehow missed this one. Our most important requirements are stability, transaction support, a solid JDBC driver (for use with an EJB server) and online backup capability. Any experiences people can offer would be appreciated, especially in a Linux environment. I heard of no problems using Interbase and Orion. However if you're looking for cheap Linux, I'm using Sybase currently. It's stable and it's free (version 11.someting for Linux anyway). sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Can't call an EJB from Within another EJB
J Davis wrote: We have gotten our Orion server(1.3.8) to work with EJBs on a singular level(i.e. we can call EJB A, B or C and it works fine.) But If one of our EJB's tries to call another(i.e. A calls B) A throws a naming exception that it can't find the EJB reference when doing a jndi lookup. Is there a dependency tag or something within one of the XML files that denotes EJB dependencies on one another? I'm sure this is something simple, but it is getting annoying. Had the same problem..: in ejb-jar.xml, you should add the dependencies. For one of my session beans I have: ejb-ref ejb-ref-nameLogin/ejb-ref-name ejb-ref-typeEntity/ejb-ref-type homeLoginHome/home remoteLogin/remote ejb-linkLogin/ejb-link /ejb-ref sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Orion in production
"Juan Lorandi (Chile)" wrote: Hi! I have been using orion for about 6 months now, and now, as I'm finishing my app, I need to sell orion to my customers... For this, it would be *VERY* valuable to have a list of sites (on the internet or intranets) which use orion... So, basically, what I have in mind is that anybody on this list that wishes to report a site as being partiallly/fully powered by orion, report it to my email address, [EMAIL PROTECTED], so that I can make a list of these, to publish it on WWW I think this will prove useful for us all. www.cachoeiro.net www.snpc.com.br -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: JBuilder + Orion
John D'Ausilio wrote: Can't say for sure if Jbuilder debugging works, but I've had good luck (and just slight flakiness) using Forte and JPDA to debug .. I used the NetBeans notes in the FAQ to set it up, and had no major problems This was posted a while ago by Chris Miller: I have managed to get this working by doing the following: - Adding orion.jar and ejb.jar to the required libraries of the project properties 'paths' tab. - Setting the main class to 'com.evermind.server.ApplicationServer' and the VM parameters to '-Duser.dir=c:\orion' on the 'run' tab. -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Entity bean ejb/entity/Autor autocreate table
Robert Krueger wrote: At 16:44 14.10.00 , you wrote: Robert Krueger wrote: check out orion-ejb-jar.dtd docs. you can change the table names to whatever you like. I knew that much, but that's created -after- deployment, and only if deployment was succesful. I was looking for a way to do this before deployment. only option you have is to write a minimal orion-ejb-jar.xml yourself. orion will not overwrite anything you put in there but add some internal stuff. that way you can put your table names in there before deployment. works well and AFAIK it's the only possible solution. tnks sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Entity bean ejb/entity/Autor autocreate table
Upon deploying my beans, my EntityBean AutorBean (jndi env/entity/Autor) tries to Autocreate the table Autor as create table env/entity/Autor. Is this standard behaviour, or is there an option in ejb-jar.xml to change this behaviour? sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
javax.naming.NameNotFoundException
Orion can't find my deployed bean: java.rmi.RemoteException: com.evermind.server.rmi.OrionRemoteException: Transaction was rolled back: Error while creating session: java.rmi.RemoteException: javax.naming.NameNotFoundException: Autor not found in AutorFacade; nested exception is: java.rmi.RemoteException: javax.naming.NameNotFoundException: Autor not found in AutorFacade at br.com.snpc.web.user.AutorWrapper.getInterfaces(AutorWrapper.java:34) at br.com.snpc.web.user.AutorWrapper.init(AutorWrapper.java:23) at /editar_autor.jsp._jspService(/editar_autor.jsp.java:31) at com.orionserver.http.OrionHttpJspPage.service(JAX) This is the getInterfaces method for AutorWrapper: private void getInterfaces() throws RemoteException{ if (home == null){ try{ Context ctx = new InitialContext(); Object obj = ctx.lookup("java:comp/env/ejb/session/AutorFacade"); home = (AutorFacadeHome)javax.rmi.PortableRemoteObject.narrow(obj, AutorFacadeHome.class); remote = home.create(); } catch (Exception ex){ throw new RemoteException(ex.toString()); } } } and the ejb-jar.xml: display-nameAutor/display-name ejb-nameAutor/ejb-name homebr.com.snpc.user.ejb.entity.AutorHome/home remotebr.com.snpc.user.ejb.entity.Autor/remote ejb-classbr.com.snpc.user.ejb.entity.AutorBean/ejb-class persistence-typeContainer/persistence-type prim-key-classbr.com.snpc.user.util.AutorPK/prim-key-class and the web.xml: ejb-ref descriptionAutor DB layer/description ejb-ref-nameAutor/ejb-ref-name ejb-ref-typeEntity/ejb-ref-type homebr.com.snpc.user.ejb.entity.AutorHome/home remotebr.com.snpc.user.ejb.entity.Autor/remote /ejb-ref The AutorFacade on ejbCreate() tries to get the Home Interface for the AutorEntityBean: private void getInterfaces() throws RemoteException{ if (home == null){ try{ Context ctx = new InitialContext(); Object obj = ctx.lookup("java:comp/env/Autor"); home = (AutorHome)javax.rmi.PortableRemoteObject.narrow(obj, AutorHome.class); } catch (Exception ex){ throw new RemoteException(ex.toString()); } } } I don't understand why this interface cannot be found. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Entity bean ejb/entity/Autor autocreate table
Robert Krueger wrote: check out orion-ejb-jar.dtd docs. you can change the table names to whatever you like. I knew that much, but that's created -after- deployment, and only if deployment was succesful. I was looking for a way to do this before deployment. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Problems with EJB and JNDI-context
Nils Frohberg wrote: Hi, I am facing a problem with my EJBs that i cannot solve. I try to access a EJB via a JSP page: javax.servlet.jsp.JspException: NamingException: Error instantiating web-app JNDI-context: No location specified and no suitable instance of the type 'de.tako.user' found for the ejb-ref ejb/user at com.evermind.ejb.taglib.UseHomeTag.doStartTag(Compiled Code) My ejb-ref looks like this: ejb-ref ejb-ref-nameejb/user/ejb-ref-name ejb-ref-typeSession/ejb-ref-type homede.tako.userHome/home remotede.tako.user/remote /ejb-ref Is there any aspect i am missing? I could not find any clues on the list, nor in the web. Maybe someone can give me a hint? :) I had the same problem more or less. Do you have a jndi.properties file in the web-app ?? I'm not exacly sure where to put it for EJB in JSP, but try putting it in web-inf/classes if that does not work move it around some. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Interbase Details [Was HARDWARE FOR J2EE apps]
Mike Cannon-Brookes wrote: Sybase JDBC drivers are called "JConnect". Current version is 5.2 (for JDBC2) and 4.2 (JDBC1) I had a few problems with them ages ago and bought a commercial driver - never tried again, but they have evolved I think. And JDBC drivers for Sybase? Last time I tried to get them from Sybase I failed miserably. Couldn't find them, not to mention download them. I seem to remember a very awkward system with registration and icky navigation to get to the drivers at all...is that easier now? Maybe I gave up to late. :-) - Where can the JDBC drivers for Sybase be downloaded? - Which version should be used? - Any special things worth knowing about Sybase and its JDBC drivers that could cause problems otherwise? The drivers can actially be found at sybase ;-) It took me a couple of hours to find them their site really sucks in relation to navigation. I'm using JConnect 5.2 and it's a pretty good driver (much better imho than for example DB2 Oracle drivers. I've heard of one bug, but haven't seen it myself, it's simmilar to the bug in the older MySql (mm) drivers, and does not allow images of more than 32k to be inserted into or obtained from the database. But I agree with the above mentioned. IMHO the free linux version is the best i've seen so far. Highly scalable, quite fast (select * from where pk='x' on a table with more than 7 million records is almost instantanious and several joins on tables with more than 7 million records goes in less than a second), it's slow (imho) in populating the db (700 records took about 14 hrs (4 on mysql!)). The docs are great (about seven books(ps) with 500+ pages) sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: NEWBIE QUESTION: How do I shut this thing down
Robert Keith wrote: Hi Guys, I have trawled through the docs to try and find a way to shut orion down cleanly, however I can't find the default username and password in order to shut it down. Can you guys let me know what it is? cheers Rob I guess it's the one you created with: java -jar orion.jar -install sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: EJB vs Servlets
Hani Suleiman wrote: 1) Connection pooling: This is available everywhere, and everyone can reap the benefits of it while being perfectly EJBless. 2) Transaction support: Stored procedures can take care of this. Stored procedures to do your transactions for you takes away the possibility to easilly 'plug-in' another database, which, imho is one of the greatest benefits of EJB. While trying to learn orion EJB at the same time, I was able to run the app I developed on Orion Interprise App Server against Oracle, DB2, Sybase, Cloudscape MYSQL without any changes to my code (Of course w/o the benefit of transactions in MySql. 3) Caching of database objects: Pretty easy to implement 4) Failover/load-balancing: As Kevin mentioned, works very nicely for servlets. Sure all this can be easilly implemented, but why should you? The guys at Orion, Inprice, IBM etc already did this for us. Which is another nice benefit of EJB, a container that does all this for you, you only have to implement the bussines logic. More tedious sure, it's the stuff mentioned above which is the nice part of programming, calculating priceindexes is not really fun. Having said all that though, I'm still going to try and use EJB's in my current project, and port all the existing 'model' objects to become full fledged EJB's. I'm hoping the advantages will become apparent then! Also, does anyone have any concrete examples of EJB's performance/scalability? Has anyone deployed them in a high volume production environment? Most people seem to be using them for prototyping and small scale projects, that I know of... It's quite a new technology, so there are hardly any big projects running. I know that here in brazil some financial institutions are messing with it (IAS because of Cobra). Sure EJB is slower, it's the java standard for a transactional framework, not the Java implemented in McLaren cars ;-) sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: CMP with DB2 again. Urgent.
Russ White wrote: Hey folks, I really need an answer to this question because while I would love to use Orion I cannot risk moving my 100+ EJBs over to Orion until I can get this resolved. I am at a critical descission point here. The IBM DB2 JDBC drivers do not allow SetNull(FLOAT). Instead you have to use setObject(null). I know this a bug in the JDBC driver, but there are work arounds. Here is how I do it with Inprise Application Server (which I am using now). I write the follow class which implements JdbcAccesserFactory: AFIK, there are some drivers on the market for DB2 that are better than the Standard IBM drivers. I've never tested them, but I've seen a class 4 driver for DB2. You might want to give those a try. -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: SSL - Only a few pages need SSL, does that slow things down?
"Duffey, Kevin" wrote: Hi, Seeing all this SSL talk has me wondering a bit...we only have 3 pages right now that use the HTTPS protocol. The other 200+ are just HTTP. If we have Orion use SSL does it take any noticeable hit on the rest of the pages that are not using SSL? I just want to make sure that before we go production with our clustered SSL Orion setup, it isn't going to come to a crawl because a few pages are using SSL. I haven't read much on how to get SSL to work yet, but it seems to me as if the whole server goes in to SSL mode if you use it. Is this the case..or is it only pages that use SSL that are slow, the rest being unscathed by the SSL mode? Thanks. I haven't worked with SSL in Orion yet. But if Orion entirely goes SSL, that would probably have some impact on server speed. FWIF i think that when you set up orion to work with SSL you should set up a new web-app for only those three pages. This app should be bound to the ssl port e.i. port 443. your myweb-web-site.xmp would looke some like: web-site host="[ALL]" port="443" display-name="myweb" virtual-hosts="myweb.com.br" Which would only encrypt your three pages.. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Orion Server java:comp/env?
Blasius Lofi Dewanto wrote: Hi! I just wonder, is that possible to make the lookup from "the client program" without java:comp/env? The problem is, I want to write an EJB application that can use JOnAs and Orion as the container. JOnAs's JNDI does not support java:comp/env at the client level. Client program: For example: Context context = new InitialContext(); Object homeObject = context.lookup("java:comp/env/BankHome"); This won't work in JOnAs. Instead I have to write this: Context context = new InitialContext(); Object homeObject = context.lookup("BankHome"); Looking at the ejb1.1 specs, lookup("BankHome") is non-standard. EJB should do lookups relative to java:comp/env. You could however store this string as an evnironment property for your beans, when deploying on JOnAs you would store "" and on an ejb1.1 clmpliant server you would store "java:comp/env/" sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Doubts on finder methods orion-ejb-ar.xml
I have a couple of doubts concerning the finder-method tag. specifically, I would like to implement a query like "select * from table where field LIKE '%value'" Considering I have: cmp-field-mapping name="_fantasia" persistence-name="FANTASIA" / in my orion-ejb-jar.xml. and the docs tell me: finder-method partial="true|false" query="$1 = $myField AND $myOtherField 5" I suppose (not really clear in the docs) that $1 is the value passed to the finder method and $MyField is the persistence name, in the above example FANTASIA and not _fantasia. Is that correct? in this case can I create a query like: finder-method query="$1 LIKE '%' + $FANTASIA + '%'" Sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Wap url rewriting
In the code below, Orion automatically rewrites the URL, creating a wrong link in the celphone. Is this rewriting default behaviour, and how can i undo this? % if (checkBean.getContas() != null) { % a href="#contas"contas encerradas/abr/ % } else { % sem contas encerradasbr/ % } % % if (checkBean.getTelefone() != null) { % a href="#telefone"Informações do tel/abr/ % }% Sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Orion Sybase
I just installed sybase and after updating the data-sources.xml I redeployed what I'm currently developing. While deployng, orion started autocreating tables, which is ok with me, except for th fact that it is autocreating in the wrong database. Here's the relevant part of my database xml data-source class="com.evermind.sql.DriverManagerDataSource" name="CEP" location="jdbc/cepDS" xa-location="jdbc/xa/cepXADS" ejb-location="jdbc/cepDS" connection-driver="com.sybase.jdbc2.jdbc.SybDriver" username="sa" password="" url="jdbc:sybase:Tds:brvip.com.br:7100/CEP" inactivity-timeout="30" schema="./database-schemas/sybase.xml" / data-source class="com.evermind.sql.DriverManagerDataSource" name="BOLETO" location="jdbc/boletoDS" xa-location="jdbc/xa/boletoXADS" ejb-location="jdbc/boletoDS" connection-driver="com.sybase.jdbc2.jdbc.SybDriver" username="sa" password="" url="jdbc:sybase:Tds:brvip.com.br:7100/BOLETO" inactivity-timeout="30" schema="./database-schemas/sybase.xml" / and a part of my orion-ejb-jar.xml: entity-deployment name="User" location="User" wrapper="UserHome_EntityHomeWrapper9" table="Users" data-source="jdbc/boletoDS" primkey-mapping cmp-field-mapping fields cmp-field-mapping name="cgc_cpf" persistence-name="cgc_cpf" / /fields /cmp-field-mapping /primkey-mapping cmp-field-mapping name="_ie_rg" persistence-name="_ie_rg" / cmp-field-mapping name="_nome" persistence-name="_nome" / cmp-field-mapping name="_fantasia" persistence-name="_fantasia" / The tables to be autocreated are in the boletoDS. However the tables are created as if I u used: url="jdbc:sybase:Tds:brvip.com.br:7100" for an url instead of url="jdbc:sybase:Tds:brvip.com.br:7100/BOLETO" Does anyone have any experience with Orion sybase ? What might it be that I'm missing here? Sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: SV: Orion Sybase
[EMAIL PROTECTED] wrote: Put the datasource of the database you want the tables to autodeploy in first in the datasources-xml. Or remove autocreatetable support and deploy, then edit orion-ejb.jar.xml to point to the right datasource, then enable autocreate option and redeploy again. Should work just fine :) And so it did ;-) The three words that apply to me are STUPID, STUPID and STUPID ;-) I had created the db boleto (no caps) and pointed to BOLETO (all caps). I suppose this is a bug in Sybases JConnect. IMHO if the db does not exist, it shouldn't put the tables just anywhere.. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
autocreating tables
When orion autocreates tables, string fields are always represented as char(255). How do i change this behavior so it will create for example: String name as char(25) String firstname as char(20) String zipcode as char(8) etc. Sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Benchmarks
Lawrence Fry wrote: Christof, I read this article, and the comparison in this benchmark is between php, perl and java. The benchmark is not intended to compared j2ee application servers, and as noted in the article, only includes "toy" applications like hello world. The conclusion of the article is that java is as good or better than php and perl. However, lets make some comparisons. Orion is about 2% faster than Resin, which in my book is nearly the same. However, Resin is not a j2ee server, and uses non-j2ee ejb protocols. Most of us use Orion for the ejb support. Besides, Both where tested on JDK 1.2. And the Orion version was 0.7.someting. Sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: IDE use with Orion
Christian Sell wrote: but i can see potential for the orion crew to make a couple of modules for forte to get an "ide" that has ejb generation and so on matching Orion. I for my part can still see a significant potential for the orion crew writing documentation before delving into tools and stuff... While at the same time getting the GUI's to work without problems of course. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: adding vhosts without restarting server?
"Joseph B. Ottinger" wrote: I have a client who adds new vhosts on a regular basis; currently that means (AFAIK) they have to restart on each addition. Is this correct? If they restart, doesn't that imply that any current sessions are wiped? I've 'hot deployed' some applications and virtual hosts on orion. You just need to create the directory structure (or ear and war files), edit the proper web-site files, and as the last you edtit Server.xml. As soon as you save server.xml, Orion will start to deploy the application. Sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
IBM DB2 Orion
Has anyone got DB2 working with Orion ?? Depoloying an application with a DB2 DS under jdk1.2.2 causes a crash in java.exe. Under 1.3 causes orion to crash: java.lang.NoSuchFieldError: rsType at COM.ibm.db2.jdbc.app.DB2Statement.SQLAllocStmt What's wrong here? Does anyone have an example of a DB2 Database schema? sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: Remote debugging from JBuilder
Maxim Weiss wrote: Hello, is it possible to debug EJBs from JBuilder IDE? Yes it can be done. See the docs for JBuilder debugging with IAS and apply this to the jars in /installdir/orion. I haven't done it yet, but I heard of people doing it. What it basically involves is starting Orion in-process in Jbuilder. sven -- == Sven E. van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Re: JBuilder 4
Cory Adams wrote: JBuilder 4.0 just came out and the Enterprise edition will let you develop fully J2EE compliant apps. Does anybody have any experience using this version of JBuilder 4 and Orion? Well, since it's 'just out' it will be hard to find anyone with experience. However, since you can debug j2ee apps in JBuilder-Orion with JB 3.5, I guess it will be possible with JBuilder 4 too. sven -- == Sven van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] ==
Prepared Statements
Does Orion pool prepared statements, or do I depend on the DB to cache the query plan? sven -- == Sven van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] _/_ The answer / \ to the ultimate questionnnn|. .|nnn 42 =U
Re: How do you like Orion?
2.3+..not sure about the new 3.0 version) ). It got shot down simply because our "big boys" felt they were too small of a company to rely on being around in a couple of years. Despite the fact that I already had our site running on it (not production..but on my local box) and it was extremely easy to configure, they put WebLogic, WebSphere and Oracle App Server on the list..that was it. Even though Orion is several times faster than WebLogic, we would rather spend $150k on WebLogic (cluster..$15K per cpu per server) than $10K on Orion to do the same thing..yet better. Go figure. Hehehe Isn't it amazing. I had the same discussion with my partners some financial backers for our ptoject relating to my choice for databases. I've chosen for DB2 for various reasons, but my main reason being that it's been on the market for more time than i've been using computers, because of IBM's heavy support for JAVA and it's scalability (I've been able to use it quite well even on a win 98 box with only 32 megs of ram) Oracle, our other choice, I've personally not been able to install, neither on a linux box nor on solaris or nt. It cracked up on some 99%. I had to defend IBM DB2 (US$ 26,000) agianst Oracle (On our dev machine would be around US$250,000) based on the difference in price."With that difference, there must be something wrong". Orion is a great tool. It's the only app server I know, but all I hear of others such as weblogic, iPlanet is that they are not 100% j2ee. What's the use of having a j2ee standard and having an appserver that does things different. Luckily I'm in the position to decide on what to buy when the time comes. I will never fork over US$150.000 for an appserver when I might just as well pay only US$ 1500 for something that works *at least* just as well. The only thing are the docs. sven -- ============== Sven van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] _/_ The answer / \ to the ultimate questionnnn|. .|nnn 42 =U
Problems executing HelloClient
I'm just now starting to use Orion for EJB deployment and have created the HelloWorld example from Ed Roman's book "Mastering Enterprise Java Beans". When trying to execute the HelloClient however, I get a java.lang.SecurityException, invalid user/password. I've set the user password in the appdeployments/myapp/principals.xml. What Am I missing? sven -- ====== Sven van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] _/_ The answer / \ to the ultimate questionnnn|. .|nnn 42 =U
IE explorer
I supose it's a M$ problem, but maybe someone knows a workaround. When (in IE5) a user enters: www.somehost.com in the location bar of IE and presses enter without http:// prefixed, no page is returned. In Netscape this is no problem. sven -- == Sven van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] _/_ The answer / \ to the ultimate questionnnn|. .|nnn 42 =U
orion on linux not serving jsp from /examples
I've just installed orion on my linux box and tried to access the example jsp's in the default web-app context, but I get an error 500. The servlets work however. I run orion on Linux RH 6.1 with jdk 1.2.2 RC2 (sun). I've also installed orion on my NT box where it serves jsp's just fine.. (with jdk1.3). Is this a jdk problem ? sven -- == Sven van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] _/_ The answer / \ to the ultimate questionnnn|. .|nnn 42 =U
stupid
I'm sorry for the last e-mail I send about orion on linux.. I should read the manual some more.. Ofcourse without tools.jar in orion/ things don't work. sory I'm back to RTFM. sven -- == Sven van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] _/_ The answer / \ to the ultimate questionnnn|. .|nnn 42 =U
Orion serving Static HTML
I'm considering replacing Apache/Jserv and Apache/Tomcat on two machines with orion, unless Orion is much slower serving static html than Apache. Are there any benchmarks available? sven -- == Sven van 't Veer http://www.cachoeiro.net Java Developer [EMAIL PROTECTED] _/_ The answer / \ to the ultimate questionnnn|. .|nnn 42 =U