Re: Sharing httpsession among several applications

2002-03-19 Thread Rafael Alvarez

Hello Juan,

Tuesday, March 19, 2002, 5:11:31 AM, you wrote:

JF> Hi people.

JF> When talking about secure applications, you have recommended to set the
JF> shared attribute to "true". In that way, session is shared between the
JF> secure and non-secure parts of an application.

JF> My scenario is several applications deployed on the same orion server.
JF> Is it possible to share the httpSession among them using the shared flag
JF> in default-web-site.xml?

JF> Thanks


AFAIK, you can only share the HttpSession object among diferent instances
of the same web-app in the same Enterprise Application.

Even if the an Enterprise Application has more that one webapp,
the session will not be shared between them.

m2c

Rafael







Re: is restarting Orion necessary ??

2002-03-14 Thread Rafael Alvarez

Hello mittal,

Thursday, March 14, 2002, 12:48:14 AM, you wrote:


msajcj> Hi

msajcj> Please let me know if restarting Orion necessary if I change a class when
msajcj> the server is running.

msajcj> I do not want to run my server in development mode

msajcj> regards
msajcj> Sunil



Hi!

The answer is yes, you have to restart Orion as the default behavior
of the JVM is to not reload a class that is already loaded in memory.
Redeployment can flush that cache for servlets and EJB, but sometimes
helper classes are not reloaded, so a restart is needed in those
cases.

m2c

Rafael







Re: jsp:forward problem on Mac IE.

2002-02-01 Thread Rafael Alvarez

Hello Fredrik,
Congrats! You have encounter an error that is not your's nor orion's.
The problems is in the way IE4.5 for Mac parse the http header.

I posted and issue at www.elephantwalker.com. Check it out at
http://www.elephantwalker.com/searchresult?id=162
(Note: elephantwalker registration is free)

After searching lots of forums I found out that a lot of people had
problems with forward (not only with orion) on Mac and IE 4.5. So,
I suggest that you start coding the "ugly-code" workaround.

What I did was to wrap my forward call into a include/redirect
combination.

Sorry I can't be of more help, and good luck.

-- 
Best regards,
 Rafael Alvares
 mailto:[EMAIL PROTECTED]







Re[2]: Persistance between HTTP and HTTPS

2001-12-06 Thread Rafael Alvarez

Hi!
If you want to share info between Http and Https session , you have
two options:

i) Use a central repository (like JNDI)

ii) Use the same web-app for http and https service, and set
shared="true" in the deployment (check out the web-site.xml
documentation). This way the HttpSession object, servlet context, etc
are shared by both instances.

This topic was discussed some time ago in this list, perhaps in the
archives you can find a better (or more specific) answer

http://www.mail-archive.com/orion-interest%40orionserver.com/

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]







Re: NoSuchObjectException taking over FinderException

2001-11-21 Thread Rafael Alvarez

Hello Brian,
are you setting the exclusive-write-access to false for that bean?
There is a known bug (bug #532 in bugzilla) about findByPrimaryKey not
throwing an ObjectNotFoundException when it should if
exclusive-write-access is set to false. It's reported from 1.4.5 and
it hasn't be fixed.

The workaround is to use a try/catch block around call of the method
to catch a NoSuchObjectException.

Tuesday, November 20, 2001, 3:19:39 PM, you wrote:

BC> There seems to be a problem with FinderExceptions due to lazy loading of entity 
beans.
BC> It seems to me that FinderExceptions are not working properly for entity beans? 
Any ideas. See the following snipet.
BC> InitialContext ic = new InitialContext();
BC> Object o = ic.lookup("java:comp/env/ejb/CounterHome");
BC> CounterHome counterHome = (CounterHome)PortableRemoteObject.narrow(o, 
CounterHome.class);

BC> // FinderException should be thrown but is NOT.

BC> Counter counter = counterHome.findByPrimaryKey("xyz");

BC> // NoSuchObjectException is thrown because the entity does not exist.

BC> System.out.println(counter.getNextID());

BC> - Thanks.

BC> [EMAIL PROTECTED]



-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]







Re: session bug

2001-09-18 Thread Rafael Alvarez

Hello Denis,
Try doing this:
session = request.getSession(true);
System.out.println("session = request.getSession(false);\t" +
session.hashCode());
System.out.println("session = " + session);
session.invalidate();
System.out.println("session.invalidate();\t" + session.hashCode());
System.out.println("session = " + session);
session = request.getSession(true);
System.out.println("session = request.getSession();\t" +
session.hashCode());
System.out.println("session = " + session);

That way you'll get a new session after the session is invalidated.
The problem arises because the session object that is associated with
the request object is the invalidated one until you create a new
session, either by a new hit in the page/servlet or by using
request.getSession(true).


Tuesday, September 18, 2001, 9:44:52 AM, you wrote:

DK> Hello everyone!

DK> I think I have found bug in orion 1.5.2.
DK> There is problem with sessions. When I invalidate session and then get new
DK> session, sometimes (not always) I get same invalidated session.
DK> Does anybody have same problem? Any solution except that I remove all data
DK> from session?
DK> Thanks in advance.


DK> Here is code that demonstrates bug:

DK> session = request.getSession(true);
DK> System.out.println("session = request.getSession(false);\t" +
DK> session.hashCode());
DK> System.out.println("session = " + session);
DK> session.invalidate();
DK> System.out.println("session.invalidate();\t" + session.hashCode());
DK> System.out.println("session = " + session);
DK> session = request.getSession();
DK> System.out.println("session = request.getSession();\t" +
DK> session.hashCode());
DK> System.out.println("session = " + session);


DK> Orion's output:

DK> session = request.getSession();2935133
DK> session = HTTP Session AKAEMHOGAJOD
DK> session.invalidate();   2935133
DK> session = HTTP Session AKAEMHOGAJOD
DK> session = request.getSession(); 2935133
DK> session = HTTP Session AKAEMHOGAJOD

DK> Exception is
DK> java.lang.IllegalStateException: Session was invalidated
DK> at com.evermind.server.http.EvermindHttpSession.setAttribute(Unknown
DK> Source)
DK> at
DK> isvu.kadrovska.web.command.LoginCommand.execute(LoginCommand.java:161)
DK> at isvu.kadrovska.web.Kadrovska.doPost(Kadrovska.java:183)
DK> at javax.servlet.http.HttpServlet.service(HttpServlet.java:211)
DK> at javax.servlet.http.HttpServlet.service(HttpServlet.java:309)
DK> at javax.servlet.http.HttpServlet.service(HttpServlet.java:336)
DK> at com.evermind._cxb._abe(Unknown Source)
DK> at com.evermind._cxb._uec(Unknown Source)
DK> at com.evermind._io._twc(Unknown Source)
DK> at com.evermind._io._gc(Unknown Source)
DK> at com.evermind._if.run(Unknown Source)



Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re[2]: Session share problem.

2001-09-06 Thread Rafael Alvarez

Hello Jishan,
There is an option (shared="true as stated in other posting) to share
session between different instances of the SAME application. The
keyword is SAME. If you use different applications for each of your
normal site and your secure site then that solution won't work.

What you can do in that case is to "send" the sessionId() of the
nonsecure site to the secure site, and viceversa. For example:
To enter the secure site, use a link like :
secure.jsp?nonsecureId=

To reenter the non-secure site:
nonsecure.jsp;jsessionId=?secureId=

To reenter the secure site:
secure.jsp;jsessionId=?nonsecureId=


Wednesday, September 05, 2001, 9:34:33 PM, you wrote:

GM> i think there's a share="true" attribute that you have to put in the web-site.xml 
file ??? check out the doco in www.orionserver.com

GM>   - Original Message - 
GM>   From:  Li
GM>   To: Orion-Interest 
GM>   Sent: Wednesday, September 05, 2001 7:42 PM
GM>   Subject: Session share problem.


GM>   Hi,
GM>  I have session share problem between ssl site and non-ssl site. My ssl site 
name is secure.mysite.com and non-ssl site name is www.mysite.com. when I start my 
server, and visit
GM> www.mysite.com firstly, everything goes well. But when I visit secure.mysite.com 
firstly after I starting my orion server, and then back to www.mysite.com  every 
request on www.mysite.com create
GM> a new session.  So my user login, shopping cart won't work!!!
GM>  Is there any one can help me?
GM>   Thanks!

GM>   Jishan Li.



-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: PHP with Orion

2001-09-04 Thread Rafael Alvarez

Hello Marcello,
Yes, it can be done. You need to modify the file global-web-application.xml
in your config directory.There is a servlet used for serving pages
using a CGI interpreter (like php). Below is an example of the servlet
definition I use(change php4 with the path to the php exec)


 php
 com.evermind.server.http.CGIServlet
 
 interpreter
 php4/php
 


It as worked of so far. You can even have jsp and php pages served in
the same app, but there will be separate session for the jsp and php
pages.

Monday, September 03, 2001, 4:44:25 PM, you wrote:

MM> Is it possible to serve PHP pages with Orion ?
MM> If yes, is there any kind of document ?

MM> TIA,
MM>  Marcello





-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re[2]: I think, I will start a support site too....

2001-08-23 Thread Rafael Alvarez

Hello Kevin,

I did a stress-test some time ago. It was a JSP page that made a DB
Query joining 2 tables and used a findByAll method on a entity bean.
Both tables where populated with 5000 items.

I ran Jtest with 2 groups of 10 threads, spacing each http query from the same
thread by 300mls.

The DB server was a IBM Netfinity Single Processor Pentium III 700Mhz,
with 512 megs of RAM running Win 2k. Orion was running in a IBM PC-300GL
Pentium III 600m 256 megs of RAM and Win NT 4 SP 5. Jtest ran on the same
machine. The network was a Ethernet-100. JDK 1.3 and orion 1.2.? (long
time ago, indeed)

>From a clean start (all machines turned off and on), orion ceased to
respond after 6 hours.

Using oracle and orion on the same machine (the PC-300GL), orion
ceased to responde after 1 1/2 hours.

DK> On the note of support, has anyone load-tested the hell out of Orion to see
DK> how much it really can handle before it crawls? I think these are issues
DK> support (or perhaps a white paper) should address.
-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re[2]: ORA-01000: maximum open cursors exceeded Exception

2001-08-15 Thread Rafael Alvarez

Hello Alex,

Not a long time ago I ran with that problem using orion 1.4.5. It was
at the university, and we were using a central DB server for all the
courses. The problem was that I was using a lot of EJB (25+) in an
implementation of TPC-W benchmark (a e-commerce like app), but the DBA
configured ORACLE to allow a maxium number of open cursors that was
less that the number I needed.

So, contact your DBA.

BTW, if you are working with oracle, is very useful to subscribe into
otn.oracle.com. You can find all the manuals online. My most used link
is http://technet.oracle.com/doc/server.815/a67785/toc.htm (Oracle
Errors). Is for 8.1.5, but is still current.

Tuesday, August 14, 2001, 5:58:47 PM, you wrote:

AP> We are not using any direct connections to the database.  We only use CMP
AP> beans.  So there might be something wrong in the way I am using the beans,
AP> or the could be a bug in Orion which is leaving a lot of cursors open.  Then
AP> again, it could be normal operation and we just need to increase the number
AP> of cursors allowed.






-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: not invoking my finder method?

2001-08-13 Thread Rafael Alvarez

The EJB specs says that if you declare a finder method on the home
interface, the container will generate the apropiate finder. If you
need a custom finder that you cannot express using pure and basic SQL
(like your case) use a (stateles) session bean to declare the finder.



-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: multiple instances of a servlet?

2001-08-09 Thread Rafael Alvarez



Here is a clue:
--
Servlet 2.2 Specs:
For a servlet not implementing SingleThreadModel and not hosted in a distributed
environment (the default), the servlet container must use only one instance
per servlet declaration.


A servlet declaration is part of the deployment descriptor of the web
 application containing the servlet, as described in Chapter SRV.13, “Deployment
 Descriptor”

m2c

>If you declare the same servlet twice in the web.xml (i.e, different
>name, same class) you get two instances running. Check out your
>web.xml and let us know.

>We've implemented the request-controller pattern using a servlet as
>the entry-point of all our jsp-pages. For some reason Orion creates
>multiple instances of this servlet even though it isn't implementing
>SingleThreadModel and there isn't anything peculiar about it. I have
>the servlet printing to System.out every time init() is run and every
>time it receives a request, it also prints the memory address of the
>instance that's handling it. For some reason with this servlet there
>are multiple instances (up to 3 so far) that handle these requests.
>There doesn't seem to be any larger logic in which instance gets to
>handle the request. It's not a problem per se but I just find it
>rather strange since I assumed that only one instance of a servlet
>would be created. Anyone else ran into this ?

--
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: Session Sharing Again

2001-08-08 Thread Rafael Alvarez

Hello Joseph,
As stated in an obscure mail long time ago (I coundn't find it in my
folder ;) ) you can share sessions only between multiple instances of
the same app, no between apps.

If you need a central repository for info that needs to be accessed by
multiple apps, JNDI is a good idea.

Wednesday, August 08, 2001, 11:14:47 AM, you wrote:

NJF> OK  to not beat a dead horse or anything  cause i have read through
NJF> the previous emails to try and solve hte problem

NJF> BUT ... i baiscally have an EJB App on there that sets sup session variables
NJF> Then I have some jsps and servlets on the regular default site that need to
NJF> read those session variables.

NJF> In my default-web-site.xml I have this:

NJF>  load-on-startup="true" /> 

NJF> AND

NJF>  root="/scope-users" load-on-startup="false" max-inactivity-time="no
shutdown" />> 
-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: Transaction problems

2001-07-13 Thread Rafael Alvarez

Hello Christian,
The  tag in  must match the  in 
or . Also, specify a .

Try putting this in your ejb-jar.xml:


  
MyLogEnt
*
Required
  
  
 MyEntUtente
 *
 Required
  






-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: Registering EJB's on the fly

2001-07-10 Thread Rafael Alvarez

Hello K.J.,

Yes, it's possible.
If your bean is in "ejb/BeanB" and you want to put it in "ejb/BeanC"
use:

 javax.naming.Context ctx=new javax.naming.InitialContext();
 BeanBHome b = (BeanBHome) ctx.lookup("ejb/BeanB"); // ok, fine
 ctx.bind("ejb/BeanC",b);

 now:
 BeanBHome c = (BeanBHome) ctx.lookup("ejb/BeanC");
 should work.

 Note: If you want to change the Object bound to a name, use
 ctx.rebind instead.
 
KKJ> Dear All,

KKJ> I'm wondering how I can register EJB's on the fly in Orion. Say I have a
KKJ> bean that is registered and known. As the program runs I decide I also want
KKJ> it registered under a different name in the JNDI registry.

KKJ> thus, in pseudo code:
KKJ> BeanBHome b = lookup("ejb/BeanB"); // ok, fine
KKJ> BeanBHome c = lookup("ejb/BeanC"); // *agk!* fails
KKJ> jndi.register("ejb/BeanC", BeanBHome);
KKJ> BeanBHome c = lookup("ejb/BeanC"); // ah, now it works!

KKJ> Kees Jan


-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: Documents and dynamic web pages

2001-07-02 Thread Rafael Alvarez

Hello Kemp,
As you're using Oracle, think about exploring the
Intermedia features.

Hope this help.

Friday, June 29, 2001, 6:57:12 PM, you wrote:

KR> I am aiding a department that is using a two tier
KR> application design, with a JSP engine and Oracle, to
KR> build a dynamic web site.  It's easy to deal with
KR> images, by either using a URL link, or a BLOB field in
KR> Oracle.  Now I wonder how to deal with documents.  Is
KR> it best to store them as BLOBS, or perhaps PDF files,
KR> and use software such as www.pdflib.com to transform
KR> them.  Any suggestions on the best approach.

KR> __
KR> Do You Yahoo!?
KR> Get personalized email addresses from Yahoo! Mail
KR> http://personal.mail.yahoo.com/




-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: CMP-mapping: object properties

2001-06-25 Thread Rafael Alvarez

Hello Oliver,

Try deleting the orion-ejb.jar.xml in the application-deployments dir.
this will force orion to copy it again.
Monday, June 25, 2001, 6:55:33 AM, you wrote:

OS> Hi!

OS> Until now I hav been quite happy developing with oc4j  but this is
OS> becoming frustrating:
OS> according to orionsupport.com
OS> (http://orionsupport.com/articles/complex-or.html) the server should map
OS> CMP fields that are compound objects property by property (Strings) to
OS> db-columns if I put an orion-ejb-jar containing
OS> 
OS> 
OS> 
OS> into my ear. The directory where I have to put this file seems to have
OS> changed somewhere around the oracle-licensing but neither putting it in
OS> "myjar\META-INF" nor "myjar\orion" seems to affect the file created in
OS> the server-dir under "application-deployments". The server every time
OS> generates just
OS>  persistence-name="userDataObject" />
OS> and it maps my object to: "userDataObject LONG RAW null"

OS> The really bad thing about this is even the example from orionsupport is
OS> deployed this way.

OS> Did I oversee any option that controlls this mapping behaviour?

OS> Thank you in advance

OS> Oliver






-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






response.sendRedirect problem

2001-06-13 Thread Rafael Alvarez

Hi all,

this is the scenary: I have a 2 jsp pages and 2 servlet. The flow is:

pag1.jsp -->(via Post)-->
  -->servlet1 -->(via forward) -->
  -->servlet2 -->(via response.sendRedirect) -->
  --> pag2.jsp

when viewed using some browsers in Mac (IE and Netscape alike), the
redirect sends the url
http://hostname/servlet/servlet2/http//hostname/servlet/servlet2

and I got a 400 Bad Request Error, no matter which url I use in the
response.sendRedirect (as I recall, my last was "foobar/whatever")


On windows and unix browsers works fine.

Any ideas?

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: Force Logon after X minutes

2001-06-13 Thread Rafael Alvarez

Hello Smith,

Create a class that implements HttpSessionBindingListener.
In the valueUnbound(HttpSessionBindingEvent event) put whatever code
you need to logout .

When you create the session, store an object of that class, so when
the session expires the user logout.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Jay's posting

2001-06-11 Thread Rafael Alvarez

I'm posting this as a favor to Jay Amstrong

Karl,

Thanks for responding.  This is already a long message, so I'll try to
keep it short.

I've been wrong before and, if that's the case now, then please forgive
me.  Lest anyone think I'm out to bash Orion, please refer to my vigorous
and lengthy defense of Orion (e.g., "Subject: Re: SV: Not authorized to
view this page" 16Feb2001).

There have been several threads on orion-interest about lack of response
from Evermind/Ironflare.  Topics like "Anyone heard from evermind?" didn't
appear without reason.  Your response to that particular thread explained
the transition from Evermind to Ironflare, which, in turn, spawned many
concerns about the future of Orion (pricing, etc).  Still, there were other
subsequent threads about lack of response, especially regarding bug fixes.

Several weeks ago, I notified you directly of an unauthorized production
user.  There was very little interest.  In fact, there has been no follow
up to let me know whether or not anyone even verified it.  I assumed that
there was so little interest in a few $1,500 production licenses because
Ironflare was too busy trying to sign with Oracle.  

I also recently requested comments from you and Magnus for a live web
presentation I am doing next week about J2EE on a budget.  Again, no response.

Since we don't know the details of the deal with Oracle, it's hard for me
to comment on the value of the deal.  What we do know is that other J2EE
products  (e.g., WebLogic, WebSphere, IPlanet, etc) sell for upwards of
$10,000 per CPU.

In the past, on this site, I have stated that I hope you an Magnus become
millionaires.  I'm not asking now, nor will I ever ask, how many licenses
Ironflare has sold or the specifics of the contract with Oracle.  That's
your business.  But I do know what Oracle's competitors charge, and
Ironflare's possible revenue from this is theoretically enormous.  Again,
I'm happy for you.

The reaction I've gotten on this agreement from other
Orion users is that they're very happy about it, and
You may wish to consider that many Orion users are trying to learn J2EE,
have absolutely no experience with big business, etc are fearful of being
banned from this and the Orion site.

In a sense, I'm happy, too.  Like many users, I am concerned about the
future of Orion.  I doubt Ironflare has an army of lawyers or a mountain of
cash -- Oracle does.  It may be increasingly difficult to allow Orion to be
free for development, because Oracle's long-term business strategy is
probably not to allow that.  There is no getting around the fact that
comments from users to this site have helped refine a product that is now
directly benefitting a Fortune 50 company.

I am definitely happy for you and Magnus.  I've gained a lot more from
Orion than I've given.  

I am somewhat encouraged by your comments, though still doubtful about the
future.  Maybe I'm just too cynical.  Maybe I've dealt with too many big
companies.

Jay

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re[2]: Oracle deal gag

2001-06-11 Thread Rafael Alvarez

Hello Jay,

First off all, don't take this as an attack. I'll just point a weak
spot in your arguments.
JA> - Neither Ironflare nor Oracle have ever really "announced" their
JA> relationship.  It's not "announced" at www.orionserver.com.  Go to
JA> http://www.oracle.com and look at their JavaOne pages and search for
JA> "Orion".  It's buried in the user manual, but not "announced".


Orion, indeed, announced the relationship with oracle  (check the right
column ,under news, right after the place that says "Experimental:
1.5.2"). It's dated 06/05/2001

Also, Oracle has a press release, not saying "We Use Orion", but
saying that they use code from Ironflare. (follow the link fron
orionserver)

Check theserverside.com
(http://www.theserverside.com/home/thread.jsp?thread_id=7063)

Also, I don't see nothing wrong serving as a free tester from Ironflare
for it producs, given the minium price it charges for Orion. It gave
our startup company a good economic relief on times where other cheap
options where not nearly as good as Orion was (and is). Forte for Java
has more or less the same aproach: Free tester using netbeans and
Forte Comunity Edition Early Access Program, and charges 500$+ for the
full product. I think that if both parties got benefits is ok. I mean,
Ironflare got free testers, and we got an excelent, but cheap, J2EE
container. If they know what they're doing, they will continue the
orion development and give each stable version to Oracle.

BTW, if you want, send me the mail you're trying to post and I'll try
to post it.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: ATM example and Oracle

2001-05-29 Thread Rafael Alvarez

Hello Mustafa,
You need to put the JNDI location of the Datasource. Check out
data-sources.xml.html in the docs. This locations does NOT support
connection pooling and transactions.

Tuesday, May 29, 2001, 3:22:36 PM, you wrote:

MC> I am trying to deploy and run the ATM example using
MC> Oracle as database.  Below is the data-sources.xml, I
MC> anticipate a problem in the file since orion is not
MC> finding the data source:

MC>  class="oracle.jdbc.driver.OracleDriver"
MC> name="Oracle"
MC>  --->   location=""
   
MC> connection-driver="oracle.jdbc.driver.OracleDriver"
MC> username="scott"
MC> password="tiger"
MC> url="jdbc:oracle:oci8:@ora816"
MC> inactivity-timeout="30"
MC> />
MC> What does the location should be?

MC> Any help is appreciated.

MC> Thanks,
MC> Mustafa

MC> __
MC> Do You Yahoo!?
MC> Yahoo! Auctions - buy the things you want at great prices
MC> http://auctions.yahoo.com/




-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: Taglib bug?

2001-05-14 Thread Rafael Alvarez

Hello Mikko,

I'm using 1.4.5 and everything is working fine. Perhaps is a problem
in deployment files?

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






A taglib question

2001-05-04 Thread Rafael Alvarez

Hello!

While using the well-known  tag I got this error:

Attribute of type 'java.util.Collection' must be a request time attribute

The code that reproduce it:
 My.jsp
<%@ taglib uri="mtags" prefix="mtags"  %>



Display details



- com.enkamino.SomeClass
package com.enkamino;

public class SomeClass {
   public SomeClass() {
   }
   
   public static Collection someFunction(int someParameter) throws Exception {
Vector vector = new Vector();
return vector;
}


I'm using the modified version that was posted some time ago. It works
ok in every other place.

Thanks in advance.


-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: Interests sake

2001-05-04 Thread Rafael Alvarez


Win NT 4.0 SP 5 on development, staging and production

At 15:53 03.05.2001 , you wrote:

>Hi all,
>
>For interests sake, what OS is everyone on the list running orion on?
>
>Windows 2000?
>WinNT
>Linux?

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: How to avoid serialization of sessions on the server?

2001-05-04 Thread Rafael Alvarez

Hello Ismael,
Orion doesn't serialize the session unless explicity told to do so.
(We got problems with our shopping cart because of that)

Why you think this is affecting the performance? It's done only at
server shutdown.

(I'm working with 1.4.5 too)

Thursday, May 03, 2001, 3:40:13 AM, you wrote:

I> On the application-deploytment\yourapp\ there is a orionweb.xml file that 
I> is used by Orion to define
I> data about how the server will work.

I> There is an option that define on which folder the server will serialize 
I> the session. This way if a the server
I> does down then when it is restarted it is able to load the sessions it had 
I> running.

I> Is there a way to avoid this behavior. I mean, I think this is slowing 
I> down  the overall performance and it is a feature
I> that I do not need. Then I would like to remove this feature.

I> Is this possible?

I> I am working with orion 1.4.5 .





-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: Have you clustered orion successfully? Please contact mchristoff@eldan.com

2001-04-29 Thread Rafael Alvarez

Hello Michael,

Just a suggestion (I never tried clustering before). Instead of
modify the default-web-app orion-web.xml try modifying the
orion-web.xml of the app you want to cluster. Also try to use URL
rewriting so the session id is always in the url. Just in  case.

Hope this work.
-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re[2]: orion not replicating session state - relatively urgent

2001-04-26 Thread Rafael Alvarez

Hello Mike,

Did you follow the instructions in the http-clustering how to
document?

And, as far as I can understant (haven't tried clustering yet) you
need to explicity pass the jsessionid in the url.


-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: orion not replicating session state - relatively urgent

2001-04-26 Thread Rafael Alvarez

Hello Mike,

Try using this orion-web.xml.
The persistence-path is not specified by default, so you need to
declare it. This is the place where sessions are persisted across
server restarts.




Thursday, April 26, 2001, 12:20:39 PM, you wrote:

MNC> subject: orion not replicating session information

MNC> Hello.  We have been experimenting with clustering orion servers and were 
initially successful.  We started the load balancer, got our servers registered with 
it, and tested it using the
MNC> servlet/SessionServlet program.  Everything worked as it should.  We modified the 
SessionServlet app to print the ip of the server it was running from.  We had it count 
to 5, then we shut down
MNC> the server, clicked refresh and the servlet went up to 6 on a different server.  
Perfect.

MNC> The problem is that when we moved the session servlet to one of our other 
application directories, it no longer updated to 6, it started at 1 again.  Why does 
orion replicate state only for
MNC> applications in the default-web-app directory and not anywhere else?  We tried 
adding  to the orion-web.xml file (in the application-deployment 
directory) of our other apps and
MNC> it still doesn't work.  Here is a snip of our default-web-site.xml file:

MNC> 
MNC>  
MNC>  
 
MNC>  

MNC>  
MNC>  
MNC>  
MNC>  

MNC> We have installed orion at a client site and need to get clustering working 
correctly within the next week.  Anyone else successfully set up clustering.  Any 
tips?  See anything we're missing? 
MNC> We will provide any info you require.


MNC> Thanks for your time.

MNC> Michael N. Christoff
MNC> Developer, Eldan Software, Ltd.
MNC> Toronto, Canada




-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: EJB Passivation problem

2001-04-26 Thread Rafael Alvarez

Hello James,

Did you modified the orion-ejb-jar.xml in the $(APPDEPLOY)/$(EJBMODULE)
directory or in the $(APPHOME)/$(EJBMODULE)/orion directory
($(APPHOME)/$(EJBMODULE)/META-INF in 1.4.8)? In the later case you need
to delete the one in $(APPDEPLOY)/$(EJBMODULE) to force a complete
re-deploy.

Also, check if you put the file in the wrong place (note that the
directory for orion-ejb-jar.xml has changed in 1.4.8)

Hope this help.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: Orion CLASSPATH

2001-04-23 Thread Rafael Alvarez

Hello Geoffrey,
from the orion.jar manifest, the classpath is:
 xerces.jar ejb.jar
 jndi.jar jdbc.jar jta.jar parser.jar jaxp.jar xalan.jar
 tools.jar jsse.jar jnet.jar jcert.jar activation.jar mail.jar
 saxon.jar

After that comes (globally)
  $(ORIONHOME)/lib

and inside each app
$(APPHOME)/$(EJB-MODULES)
$(APPHOME)/$(WEB-MODULES)/WEB-INF/lib
$(APPHOME)/$(WEB-MODULES)/WEB-INF/classes

The order in the EJB-MODULES and WEB-MODULES is something I haven't
defined yet.

Hope this help.

Monday, April 23, 2001, 12:29:31 PM, you wrote:

GM> Hello all!

GM> Can anyone tell me what Orion is doing with the CLASSPATH.  I suspect it 
GM> is building
GM> its own or adding to mine simply because it knows how to find certain 
GM> jars that I have not specified anywhere.

GM> Any info appreciated...

GM> --

GM> Geoffrey W. MarshallDirector of Development
GM> ---
GM> t e r r a s c o p ephone (415) 951-4944
GM> 54 Mint St #110   direct (415) 625-0349
GM> San Francisco, CA  94103 fax (415) 625-0306
GM> ---




-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re[2]: parsing error

2001-04-20 Thread Rafael Alvarez

Hello doggie,
Thanks for pointing it out. I misses it entirely!

I found something interesting in the Specs:
###
# Extracted from JavaServer Pages Specification Version 1.1
###
7 JSP Pages as XML Documents
The JSP page to XML document mapping is not visible to JSP 1.1
containers; it will receive substantial emphasis in the next releases
of the JSP specification. Since the mapping has not received great
usage, we particularly encourage feedback in this area.

==

###
# Extracted from JavaServer Pages Specification Version 1.2
###
2.1.2 XML Document for a JSP Page
  All JSP pages have an equivalent XML document. This equivalent
  XML document is the view of the JSP page that is exposed to the
  translation phase (see below).

  A JSP page can also be written directly as its equivalent XML document.
  Unlike in JSP 1.0 and JSP 1.1 containers, the XML document itself can be
  delivered to a JSP container for processing.

  It is not valid to intermix “standard syntax” and XML syntax inside the
  same source file. A JSP page (in either syntax) can include via a directive
  a JSP page in either syntax.



As I understood (please, correct me if I'm wrong) the JSP 1.1
container is not forced to accept the XML representation.
But Orion is suppose to implement JSP 1.2 features, so I don't know.
Perhaps they left it out because there is not sure if it will be in
the final draft.



Best Regards  mailto:[EMAIL PROTECTED]
Rafael Alvarez






Re: parsing error

2001-04-20 Thread Rafael Alvarez

Hello doggie,
I can't find the  tag anywhere in the spec, but it
sounds like the <%! %> directive.
Try using:
<%!
 private static final String[] toStringArray(int[] ori_array){
 String [] str_array = new String[ori_array.length];
 for (int i = 0; i < ori_array.length; i++){
 str_array[i] = String.valueOf(ori_array[i]);
 }
 return str_array;
 }
%>

> It seems that orion ignored the jsp tag  completely.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: deployment.cache and wrapper classes

2001-04-20 Thread Rafael Alvarez

Hello Adam,

This is a VERY dirty trick. Make orion use the SLOWEST java compiler you
can find, and force a re-deploy of the EJB module. All the wrapper's java
files will appear during deployment in the orion home dir. If you're
fast enough you can copy them before they disappear.

Hope this help.

Thursday, April 19, 2001, 10:34:31 PM, you wrote:


AC> Hey guys,

AC> I desperately need to have a look what's going on inside of orion's
AC> wrapper classes. How can I access them? Previously on the list it is
AC> mentioned that they are in the deployment.cache file, however when
AC> I attempt to unjar that file, I only get one or two classes, not the
AC> entire lot.



-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re[2]: AW: autoreload of jsp files failed while working hard on a single jsp

2001-04-12 Thread Rafael Alvarez


Orion autoreload features have worked very well al the time, either in
development, integration and production enviroments, EXCEPT when we
got a problem of date synchronization between our integration and
production servers (our integration server have a date greater that
the production one).

Anyway, you can force reload deleting the
$(ORIONHOME)/application-deployments/$(APP)\$(WEBMODULE)\persistence
directory, where all the jspCache file are stored.

And just a tougth. For all of you who have lots of  EJB in their apps,
I suggest you to use a faster compiler for orion. We use fastjavac
which comes with Forte CE, and it REALLY cut down the restarting
time. In our case, it cut it from 1 min 45 sec to 15 sec!

Hope this help.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re[2]: A modification to ejbtags.jar

2001-04-06 Thread Rafael Alvarez

Isn't it wonderful the opensource world? :)

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: A modification to ejbtags.jar

2001-04-06 Thread Rafael Alvarez

Ok. that resolve it :)
I made two mistakes:
1) This mail was intended for Karl, but I misclicked in my email
manager.
2) The version I sent is not a working one. I just realized that I
lost the last version in the last crash of our CVS... Mea culpa not
having a backup.

Anyway, here is the working version.


I'm interested in performance metrics, since it uses reflection...


-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]
 mtags.jar


A modification to ejbtags.jar

2001-04-06 Thread Rafael Alvarez

Hello Karl,

I made a modification to the ejbtags.jar you published in the website.
I modified the Iterate tag so it accept an optional field that defines
an ordering in the iteration over the collection. The question is:
should I publish it to the list or you guys check it out and decide?



-- 
Best regards,

Rafael Alvarez  [EMAIL PROTECTED]
 mtag.jar


Re: ORMI port

2001-04-03 Thread Rafael Alvarez

Hello Jeremy,

Yes, the ORMI port in orion is 23791 by default, and you can configure
it in the config/rmi.xml file.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re[4]: Removal of SBs from expiring HTTP sessions ...

2001-03-15 Thread Rafael Alvarez

Hello Mike,

I have to thank you. I wasn't sure of that, so I check it. I write
something like:

public interface test extends java.io.Serializable, javax.ejb.EJBObject {
   void dummy();
}

And the compiler throwed and error (fastjavac from Forte CE 2.0). So I stated that it 
couldn't be done.
But now, after a crash and hour ago or so, I checked again and voila!,
it compiled OK.

I want to apologize.


Thank again,

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re[2]: Removal of SBs from expiring HTTP sessions ...

2001-03-15 Thread Rafael Alvarez

Hello Mike,

Thursday, March 15, 2001, 7:31:23 PM, you wrote:

MCB> Can't you just make the SB a HttpSessionBindingListener and implement
MCB> valueUnbound() ?

Nope. For that to work you need your Remote interface to extend
HttpSessionBindingListener, but it already extends EJBObject.
There is a workaround, is to tedios that it's not worth the effort.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: Removal of SBs from expiring HTTP sessions ...

2001-03-15 Thread Rafael Alvarez

Hello Gerald,

You can create an object that implements HttpSessionListener
interface and override the valueUnbound method to call the
remove method or whatever you need to to with the SB.

Put it in the session, and when the session expires the
valueUnbound method is invoked. Be sure to implement the
java.io.Serializable interfaz to allow session persistence across
server restarts.

We use this technique for our Shopping Cart, and it has worked
pretty well so far.

Here is the class we use:

import javax.servlet.*;
import javax.servlet.http.*;
import java.io.*;
import com.enkamino.cart.*;

/**
 *
 * @author  Rafael Alvarez
 * @version 1.1
 */

public class ControlSesion implements HttpSessionBindingListener,java.io.Serializable{
ShoppingCart cart; // This hold the reference to the SB, becuse
   // you can't access to the session to retrieve
   //it.
/** Creates new ControlSesion */
public ControlSesion(ShoppingCart cart) throws java.rmi.RemoteException{
this.cart = cart;
}

public void valueUnbound(final javax.servlet.http.HttpSessionBindingEvent be) {
try {
this.cart.clear();
} catch (Exception e) {
java.rmi.RemoteException re = new
java.rmi.RemoteException("Error clearing the Cart ",e);
re.printStackTrace();
}
   
}
public void valueBound(final javax.servlet.http.HttpSessionBindingEvent be) {
}
}


GG> I posted this msg this morning, but I haven't seen it appear on the list 
GG> yet. I'm reposting in case it was lost ...

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: Colombo Java mystery -- the case of the unrecognized Parser jar

2001-03-13 Thread Rafael Alvarez

Hello Kemp,

Try putting Parser.jar in the orion directory, or in the WEB-INF/lib.

It seems that Orion doesn't use the CLASSPATH, because I need to put
the jar files in the right place for them to work.
-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: How about the latest xerces.jar and xalan.jar?

2001-03-09 Thread Rafael Alvarez

Hello Kevin,

Friday, March 09, 2001, 1:42:59 PM, you wrote:

DK> Secondly, why is it when xerces.jar is in the Orion folder, Orion
DK> does NOT use the version I have in the WEB-INF/lib folder? I thought (sorry
DK> if I don't recall what the specs say on this) that libraries in the
DK> WEB-INF/lib of a web-app override the ones in a server dir?

Yes.. and no. The problem is that orion ADD /lib and WEB-INF/lib to
the classpath, but if you look at the manifest file in orion.jar you
can see that xerces.jar in the root dir is declared to be in the
classpath at the beginning of orion execution, so if you refer to
classes in xerces.jar it will use the ones in the root dir because
they are the first found.




-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: Case insensitive primary keys

2001-03-09 Thread Rafael Alvarez

Hello Jeff,

You can do two things:
.- In the EJBCreate change the user name to Upper or Lower case  when
setting it. Also in the PK class change it to Upper or Lower case.
.- Override the PK class equal() method, to compare the username in
Upper(Lower)case.

Thursday, March 08, 2001, 7:30:39 PM, you wrote:

JS> I have a primary key which is a string (user's name), and I would like
JS> it to be case-insensitive.  That is, if there is already a "bob" entity,
JS> trying to create a "Bob" entity should throw a DuplicateKeyException.
JS> Is there a way I can do this with Orion?
 
JS> I vaguely recall reading something in the documentation about this, but
JS> now I can't seem to find it.  I'm starting to think that I imagined it.
 
JS> Thanks,
JS> Jeff

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: https second session problems...

2001-03-06 Thread Rafael Alvarez

Oops, I missed it in my last post...
I got the same problem. What I did (and it worked, even as it seems
that it shouldn't) was to store a session reference in the application
context in the last non-secure page, and then retrieve it in the first
secure page. Every object that was store in the session was retrieved.
It's been working fine for over a month. Only be sure that you use a
unique identifier to store it, and to remove the reference after you
use it.

It's not as clean as I wish it to be, but works...

Final Note: I have the shared=true tag set, it suppose that Sessions
are shared too, but they're not.


Tuesday, March 06, 2001, 1:30:18 PM, you wrote:

GM> First, a thank-you to Jay Armstrong for his SimplePortTester.  Indeed,
GM> Apache had port 443 locked up even though I thought I had stopped Apache.

GM> Here's the problem of the day:

GM> I'm only using JSP and Beans. It seems when I switch between http and https,
GM> Orion crreates a 'second session'.  I have inserted a System.err.println in
GM> EVERY method of my SessionBean which has a single boolean property:
GM> loggedOn. My comments (//)

GM> Is this a bug or a feature?  If it's a bug or a feature, is there a
GM> work-around?  It makes no sense to me why you would want to create a second
GM> 'session'.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re[2]: SV: How to set orion to perform a timely task..

2001-03-06 Thread Rafael Alvarez

If you put the code at the init function, you can force the servlet to
load at startup by putting the tag

priorityNumber

in the servlet description in web.xml. priorityNumber defines the
order in which the servlets will be loaded at startup.
-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: Session listener redirect

2001-03-06 Thread Rafael Alvarez

Hello Ron,
Two ideas:

.- Use an include in all your pages to check for some value in the
session to see if the user enters from the start page.
.- Use a servlet mapped to jsp and html. Where a user request a jsp or
html the servlet is invoked. Then you can check  the request referer
and act acordingly.

Check the documentation of the web.xml file to see how servlet mapping
is defined.

To get the referer from the request, use
   request.getHeader("Referer")
   
Tuesday, March 06, 2001, 7:33:01 AM, you wrote:

RQ> I have created the following session listener class which works but now I
RQ> want to redirect the client to the start page of the application if they are
RQ> trying to enter the application from another page.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: non-secure and secure site

2001-03-06 Thread Rafael Alvarez

Hello Greg,
To prevent the code duplication use the same app in both sites, and
use the shared="true" flag so the ServletContext is shared over all
the instances of the apps.

Sometimes the session gets invalidate when going from secure to
non-secure. We found a workaround to that, but it's a little tricky.
Just store a reference to the session on the non-secure site in the
ServletContext and retrieve it on the secure one.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: https problems...

2001-03-06 Thread Rafael Alvarez

Hello Geoff,
Check that there is no other process using the port you specified (or
443 by default for SSL). Also, if you're running a WinNT or Win2k
machine stop the IIS web sites. By some mystical reason it seems to
use the  port 443 even wheren there is no certificate installed.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: configuring an application

2001-03-02 Thread Rafael Alvarez

Hello G.L.,

you need to put the following in your server.xml:




And create an application.xml file in /u/build/META-INF


http://java.sun.com/j2ee/dtds/application_1_2.dtd">


   C.A.I.S
   Application description
   
 
cais-web
 
   



-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: Using your own web-site.xml instead of default-web-site.xml

2001-02-27 Thread Rafael Alvarez

Hello Matt,

Monday, February 26, 2001, 8:46:34 PM, you wrote:

MK> 
MK>  load-on-startup="true" />
MK> 
MK> 
The root parameter has no meaning in the default-web-app tag. It
always points to /.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: problem in accessing ejb from a bean in web-inf/classes directory .

2001-02-27 Thread Rafael Alvarez

Hello Prabahkar,

Monday, February 26, 2001, 7:38:40 PM, you wrote:

Try using
Object hdrObj = cntx.lookup("B2BOrderHeader");

I think I remember vagely a thread in this list about java:comp/,
but that was 3000 messages ago :). Anyway, this works fine for me.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re[2]: What documentation?

2001-02-27 Thread Rafael Alvarez

Hello Danut.
Monday, February 26, 2001, 8:14:16 PM, you wrote:

NN> At 05:37 PM 2/26/01 -0600, you wrote:
>>A few weeks ago after I asked some questions and posted some opinion I was 
>>sent by some guys to RFM.
Very inpolite

>>Well, I still have the same problems and I am asking the same question: 
>>why is not possible to use a GUI tool to specify all I want for deploying 
>>my application?
You need to code it yourself, because there are lot of orion-specific
things, and they haven't code a good deployment tool for that.

>>Speaking about documentation and RFM please go into 
>>"The deployment info for a J2EE-application. Manually created or
>>automatically produced when auto-deploying a J2EE-application (.ear). It 
>>extends and substitutes the assembly info found in the "
application.xml file

If you want that orion uses your own orion-application.xml (and fill
the blanks you left) put it under $(APP-HOME)/orion directory. You can
do that for the orion-ejb-jar.xml (  $(APP-HOME)/$(EJB-MODULE)/orion
), and I think you can do it for orion-web.xml but I'm not sure where
it goes. At some place in the archives of this list is a message with
the whole dir structure.


-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re[2]: Beginner...

2001-02-23 Thread Rafael Alvarez

Hello Luis,

Friday, February 23, 2001, 10:53:26 PM, you wrote:

LJB> 1) How can I simply test a JSP?
Put it under default-web-app/web directory on a fresh unziped
orion distribution. After that, just run orion and point the browser
to http://localhost/.jsp

It can get a lot more complicated (building apps, etc) but not more
difficult.

LJB> 2) Where can I learn to use EJB?? (Urgent!! : ) )
First, I recommend you the book:
Enterprise Javabeans by Richard Monson-Haefel (the O'Reilly book)

Also, check out the developer's connection at java.sun.com


Hope this help-










-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: configuring jdbc with oracle...

2001-02-23 Thread Rafael Alvarez

Hello Paul,

A stack trace would be useful. That way it's easier to find the
error.






Re: http 500 errors

2001-02-22 Thread Rafael Alvarez

Hello Vaskin,

Thursday, February 22, 2001, 3:39:33 PM, you wrote:

VK> I keep getting internal server errors (HTTP 500), where do I go to debug
VK> this? Which log file has this stuff?  I need a stacktrace! It's not popping up on 
the console, and I couldn't find it in any of the obvious .log files.

VK> Thanks in advance...

Try in
$(ORION-DEPLOYMENT)/$(APPNAME)/application.log
For example:
If orion is installed at /usr/bin/orion and your applications
is named BogusApp, the log is in

/usr/bin/orion/application-deployments/BogusApp/application.log

There you can find every error thrown by your app.

or you can tweak orion-application.xml in the same dir, under the
 flag to specify some other file, even configure your app to send
you an email in case of exceptions.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re[2]: How can I use Application session?

2001-02-22 Thread Rafael Alvarez

hi Huibert,


to expire a session use the invalidate() function:

HttpSession s = request.getSession(true);

// To expire it
s.invalidate();


You can set the session timeout in the  web.xml

15


Sets the timeout to 15 min.


Hope this help






Re: Inactive application-scope bean problem

2001-02-22 Thread Rafael Alvarez

Hello Geoff,

GM> If I don't use the application for some period of time and then try to hit
GM> the index page, I get this error, which only restarting Orion seems to
GM> fix...

GM> 500 Internal Server Error

GM> java.lang.ClassCastException: db.AppBean
GM> at /Gold/home.jsp._jspService(/Gold/home.jsp.java:33)
GM> at com.orionserver.http.OrionHttpJspPage.service(JAX)
GM> at com.evermind.server.http.HttpApplication.xj(JAX)
GM> at com.evermind.server.http.JSPServlet.service(JAX)
GM> at com.evermind.server.http.d3.sw(JAX)
GM> at com.evermind.server.http.d3.su(JAX)
GM> at com.evermind.server.http.ef.s1(JAX)
GM> at com.evermind.server.http.ef.do(JAX)
GM> at com.evermind.util.f.run(JAX)

GM> ... any ideas

Have you modified the class at some point between each hit? That
errors happen sometimes when the class in disk is different from the
class in memory.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: ms access & Orion?

2001-02-15 Thread Rafael Alvarez

Hello faisal,

If you use the jdbc.odbc bridge, yes.

But, why do you want to use Ms Access (just curiosity)
Wednesday, February 14, 2001, 11:55:05 PM, you wrote:

f> does ms access  work with Orion 
f> ?



-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Faster EJB Deployment using fastjavac

2001-02-15 Thread Rafael Alvarez


I have tried the java compiler that comes with Forte For Java CE 2.0
(fastjavac) and it cut the deployment time of 50 EJB (a mix of
entity and sessions) from 1 minute to 15 secs!

I'm developing under win 2k, orion 1.3.8.
Some one can test it under unix?

My 2 cents






Re: Orion and SSL

2001-02-13 Thread Rafael Alvarez

Hello Daniel,
Sorry for the delay in the answer.
I had the same trouble migrating a certificate from IIS to orion.

Did you generate the request to Verisign using the keystore where
you're importing it? If not, you need to request a new certificate.
Check Verisign to see how that can be done.

Hope this help.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re[2]: R: R: frustrated - jdbc: No suitable driver

2001-02-04 Thread Rafael Alvarez

Hello Allen,
DataSources gives you one advantage on the client side: Security.

If you use a direct JDBC connection to a Database, your username,
password and URL have to be placed in your class. A Datasource hides
all those details, so if some one decompile your class (even JAXed
classes are not totally safe) only the JNDI Datasource name will be
found. It's up to you to set a security schema for the connection with
the app server, but at least is one problem less to solve.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re[2]: large field bug ??

2001-01-11 Thread Rafael Alvarez

Hello Juan,

Thursday, January 11, 2001, 3:53:41 AM, you wrote:

JLC> had that problem

JLC> it's a mapping problem... (oracle-schema)


JLC> Strings get Mapped to varchars(size)...

JLC> They get chopped at size chars...
JLC> the only solution is to declare the field as java.lang.Object
JLC> then use it as string

Or you can edit orion-ejb-jar.xml and change the type of the field in
the DB. The schema set it to varchar(255), but you can change it to
any oracle type you want. look for a line like

change that and voila!

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: JSP vs PHP

2001-01-10 Thread Rafael Alvarez

Hello Frank,
Check this article from JGuru

http://www.jguru.com/jguru/faq/view.jsp?EID=10596

Wednesday, January 10, 2001, 5:28:44 AM, you wrote:

FE> Hi,

FE> I just ran into a discussion regarding PHP vs. JSP (and ASP). A claim was 
FE> made that PHP was the better alternative as it is quicker in development 
FE> and gives you a better runtime performance. I have no hands-on PHP experience.
FE> Can anyone explain me the benefits of PHP over JSP (and vice versa of course).
FE> I'm bit reluctant to rely solely on marketing speak.
FE> Thanks,
FE> FE

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: Accessing multiple databases in the same application

2001-01-05 Thread Rafael Alvarez

Hello Michael,

Check the docs for the orion-ejb-jar.xml.

In the entry for entity beans ()
you can specify the datasource and table to be used using the
parameters data-source and table.

You can find the file in $(APP-DEPLOYMENT-DIR)/$(APP-NAME)/ejb

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re[2]: class cast exception

2000-12-03 Thread Rafael Alvarez

Hello!

ML> This makes no difference. The exception is thrown, too. 
ML> But I found a solution: The Exception is thrown everytime after redeploying 
ML> my application. When I restart the server after redeploying everything is ok. 
ML> But I can't restart the server everytime something changes

I found that problem with servlets and javabeans. Looking at the code
from a compiled jsp (in the javabeans case) I found that the problem
is in the JavaBean instantiation (Beans.instantiate), and it happens
when the .class is changed. What puzzles me is that sometimes it
happens, and sometimes it don't.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: Orion slow startup

2000-11-29 Thread Rafael Alvarez

Hello scott,

Check how many EJB are being deployed. Orion slows down startup when
it's deploying EJB, because it involves generating the java sources of the
skel and stub for the home and remote, and compiling them.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Deprecated function message while deploying stateful session bean

2000-11-24 Thread Rafael Alvarez

Hello everybody,

After deploying a stateful session bean and restarting orion I get the
following message:

Auto-deploying ejb-jar (ejb-jar.xml had been touched since the previous deployme
nt)... Note: CarritoCompras_StatefulSessionBeanWrapper0.java uses or overrides a
 deprecated API.  Recompile with "-deprecation" for details.
1 warning

I checked my code and there are no deprecated function.

I'm using Orion 1.3.8 with sun jdk1.3 under win2000. This combo has
been working fine so far.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






The way to use EJB?

2000-11-07 Thread Rafael Alvarez

Hello!

This can sound a little off-topic, but is an interesting matter that
we have been discusing at work.

I'm currently working in two paralell projects. On one of them ( the
first one) we designed the tables and used JDBC, until we decided to
migrate to EJB 1.1. At that point we create one CMP EJB per table.
Later we had to create BMP EJB to manage some complex relationships.

The second project uses a lot of code from he first one, and the
persistence need is the same ( same data). At that time I start to
wonder that perhaps we were designing the wrong way.
It looks like we were designing Objects FROM Tables, and EJB is a way to
create tables FROM Objects. And most of the troubles of the first
project were because of that. I mean, we create objects tha
represented tables, rather than tables representing objects.

Any comments?

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Question about jndi and Datasources

2000-10-31 Thread Rafael Alvarez

Hi!
Is there a way to use orion as my connection manager, using jndi to
perform a lookup for a Datasource, from an stand-alone app (not a
client-app). I set up the following properties:

 java.naming.factory.initial=com.evermind.server.ApplicationClientInitialContextFactory
 java.naming.provider.url=ormi://myhostname/
 java.naming.security.principal=username
 java.naming.security.credentials=password

 but when I try to set the initial context, I get the following:
javax.naming.NamingException: META-INF/application-client.xml resource not found
   at com.evermind.server.ApplicationClientInitialContextFactory.getInitialContext(JAX)
   at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:668)
   at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:246)
   at javax.naming.InitialContext.init(InitialContext.java:222)
   at javax.naming.InitialContext.(InitialContext.java:198)
   at com.enkamino.login.deploy.DeployLogin.(DeployLogin.java:24)
   at com.enkamino.login.deploy.DeployLogin.main(DeployLogin.java:35)



Thanks in advance.

Rafael Alvarez






Re: Oracle on Orion

2000-10-19 Thread Rafael Alvarez

Hi!
Is there any error message during deploy? Orion stops the
auto-creation process if there is any SQLException.

I also found that Orion don't create tables for beans that where
already deployed, even if you drop them.


-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






test. Sorry for the inconvenience

2000-10-11 Thread Rafael Alvarez

This is a test, 'cause I didn't receive a mail from this list since 8
hours ago!






test. Sorry for the inconvenience

2000-10-11 Thread Rafael Alvarez

This is a test, 'cause I didn't receive a mail from this list since 8
hours ago!






Re: EJB vs Servlets

2000-10-10 Thread Rafael Alvarez

Hello Reddy,

I agree with you in some points. Yes, complex OR mapping is solved in
2.0, but as you said is a draft.  I won't risk put it into production
right now (we have to finish the project by Octuber 17).

About SQL, again I agree with you. I was using BMP EJB until I found
out that Orion 1.3.6 generates automatically  the findByAll() and
findByXXX().  That way I have a better control over the beans I need.

There is something I left out from the last mail. Because EJB1.1
complex O-R mapping is impossible (you need a workaround), sometimes I
need a BMP Entity because I need a complex query.


And for me, the myth was true. The migration from HyperSonic SQL to
Oracle was transparent for the application. I just had to redeploy the
application, and volia!, all the tables and constraints where there.
The mass import was a little more tricky, (we used JDBC and SQL, query
one place, insert in the other).

Two side notes about independance from tables and databases: If you
relay on triggers, multiple-field primary keys, foreign key for
consistency, etc..., you have to stick into you RDMBS. And remember:
never, ever, use a RDBMS that don't support multiple-field primary
keys. They only give you headaches.

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re: Performance

2000-10-10 Thread Rafael Alvarez

Hi,

This mail is useful only if you're using entity EJBs.
Because EJB is RMI on steroids (is more than that, but let's keep it
simple), if you need more that one entity to get the data you need for
the presentation layer  you end up opening a lot of rmi connections,
with the overhead it implies.
The solution is simple, yet elegant: Create a Session Bean, collect
all the data (raw data, not the remotes) from the Entity Beans and use
that for the presentation. That way you use only one rmi connection.


Hope this help.


-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re[2]: EJB vs Servlets

2000-10-09 Thread Rafael Alvarez

I'm currently developing a big project using EJBs,a backend for a
one-hour delivery company. In fact, I'm using CMP EJB for the data and
a fakade object for processing.There were few factors that influenced the
choice:
.- You don't have to code in SQL. That says a lot on easy manteinance.
.- Don't need to understand, as a programmer, the how of inner working of
   your RDMBS.
.- If you have a RDBMS for development and another for production, you
don't need to write SQL Scripts to recreate the table structure.
.- The migration of data from one RDMBS to another is very easy.
.- You can leave the transaction processing to the App Server.


We encounter only 2 main disadvantages:
.- Complex OR-Mapping are nor possible, and the ejbLoad-ejbStore
   method is not trustworthy.
.- For each object you need to create AT LEAST 3 classes

The first issue is solved using a Fakade class (see Fakade Pattern, I
don't have the URL rigth now).
The second issue is being solved by using a home made automated tool
that generates the required classes.


Anyway, EJB vs Servlets is a topic for a lng discusion.


-
Best Regards

Rafael Alvarez mailto:[EMAIL PROTECTED]






Re: 2nd post, please help

2000-10-09 Thread Rafael Alvarez

Did you set all the properties you need to access the jndi tree in
orion? You need to set these for a program outside orion access the
orion JNDI tree:

java.naming.factory.initial=com.evermind.server.ApplicationClientInitialContextFctory
java.naming.provider.url=ormi://:/
java.naming.security.principal=
java.naming.security.credentials= 

(Taken from www.orionserver.com documentation)

Hope this help
-Original Message-
GD> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
GD> Sent: Monday, October 09, 2000 2:52 AM
GD> To: Orion-Interest
GD> Subject: 2nd post, please help

GD> I have created a stand alone admin component outside the orion server, which
GD> use the MailerEJB functions to send emails. An exception will be thrown in
GD> MailHelper when I start running the stand-alone admin program, which is
GD> "java:com\env\mail\MailSession not found".

-- 
Best regards,
 Rafaelmailto:[EMAIL PROTECTED]






Re[2]: Stopping the Server

2000-10-09 Thread Rafael Alvarez

>> Hi, Any ideas why I get this when issuing the command to stop the
>> server? Error: javax.naming.NamingException: Lookup error:
>> java.io.StreamCorruptedException: Caught EOFException while reading
>> the stream header; nested exception is:
>> java.io.StreamCorruptedException: Caught EOFException while
>> reading the stream header Thanks.--

This error happened to me a lot, until I found that the ormi port that
orion is using is defined in rmi.xml(23791 by default). So, to restart
orion you need to use something like:

java -jar admin.jar ormi://localhost:23791/   -shutdown

change 23791 with the port specified in rmi.xml

I couldn't read the original message, so I don't know which is the
line that he used.

-- 
 Rafaelmailto:[EMAIL PROTECTED]