RoleManager: how to log off?

2001-04-17 Thread Taavi Tiirik


It is possible to log into using RoleManager.login( user, password ).
Now, how can I log off?

thanks,
Taavi






DataSourceUserManager article at www.orionsupport.com has an error for oracle users

2001-04-16 Thread Taavi Tiirik

There is an article about setting up DataSourceUserManager
at http://www.orionsupport.com/articles/datasourceusermanager.html

If you use oracle and happen to copy/paste something from
this page then please do not do the same mistake I did.

This example uses column name 'group' which is not something
that should be used. You can easily create table containing a
column with this name and you can even add data into this but
even simplest sql queries do not work. If you are using oracle
dba studio for example then you won't even notice it.

with best wishes,
Taavi






extending DataSourceUserMangaer

2001-04-16 Thread Taavi Tiirik

hello,

What is the quickest way of extending DataSourceUserMangaer to
store encrypted passwords instead of plain text ones into
database?

with best regards,
Taavi






RE: sharing class files between applications

2001-04-15 Thread Taavi Tiirik

> I know this is not the solution you're looking for, but what I do is
> simply define all my packages in /com/domainName/package(s)/classes.
> 
> Then in the /WEB-INF/classes directory for each application, I simply
> make a symbolic link ( ln -s /com com).

Thanks, Geoffrey. I stick for the same solution right now. First I
wasn't aware that symbolic links are something that can be done under
NT. But yes, they can be done with the help of windows resource kit
and there are free utilities available as well.

with best wishes,
Taavi

> > Is there a way to specify classpath for a web application so
> > that instead of having all servlets and other class files
> > int WEB-INF/classes I could share them between different
> > web applications.






platform independent jsp code. how?

2001-04-13 Thread Taavi Tiirik

Hello,

I have still problems getting orion to work with unicode
characters. Here is a jsp page that behaves differently
on different platforms. Could you please help me to find
a way to make it platform independent.

I know that unicode is not something most of you should
pay attention to right now. Still, soon... :-)

My original problem was that without specifing correct
locale information, request.getParameter() returned
something else than expected. So, on solaris platform
I added environment variable LANG=en_US.UTF-8 before
running orion. Good, got it working.

Then, the very same code did not run under win2000. For
some reason specifying character set with a <% @page %>
directive on top of jsp page does not work with win2000.
Why?

So in the meantime the best way I have found around this
problem is to have
<%@ page contentType="text/html; charset=utf-8" %>
on top of every jsp file on solaris platform and NOT
TO HAVE this line under win2000. Why? Is there something
wrong with this line? How should it be written under
win2000?

--- (start of 'utf-8test.jsp') ---
<%@ page contentType="text/html; charset=utf-8" %>








<% String q = request.getParameter( "q" ); %>

query="<%= q %>"






example 1
(asd)
- no wonder this one is working

example 2
(õäöüšž)
- here I am having problems



--- (end of 'utf-8test.jsp') -

On this page there is a text field. Place as complex
characters as you can think of into this field and submit
the form. You shuld see the very same text you entered
and not some garbage in your browser.

And I am speaking about 'solaris' and 'win2000' merely
because I really haven't tried this on other unix and nt
systems.

On both systems I am running jdk1.3 and orion 1.4.5.

Oh and one more thing. Tomcat 3.2.1 does not need
<%@ page contentType="text/html; charset=utf-8" %>
on top of a jsp page. In fact, it can not live with it.
It works without and even without specifying LANG
environment variable. So much about platform
idependency.

I really need to find a solution because I am using
win2000 on my development machine and deploying it
to solaris.

Any ideas?

thank you for your time,
Taavi






www.orionsupport.com

2001-04-12 Thread Taavi Tiirik

I haven't been able to use www.orionsupport.com from this corner
of world for some time now. Is it just me or is it bigger?

It does respond to ping though but http server seems to have problems.
Can anybody pour some light...

thanks,
Taavi







sharing class files between applications

2001-04-12 Thread Taavi Tiirik

Hello,

Is there a way to specify classpath for a web application so
that instead of having all servlets and other class files
int WEB-INF/classes I could share them between different
web applications.

And yes, I still want to use development=true option and have
the class files compiled automatically.

And no, I am not packaging them into jar or whatever archive
yet.

what do you think?

best regards,
Taavi






RE: request.getParameter() not working under solaris?

2001-04-11 Thread Taavi Tiirik

> I had the same problem when loading data from the database ( swedish
> language ). They got messed up on the way. So the resolution in my
case
> was to make sure that the shell running orion supported swedish chars.

Got it working. The solution was to specify environment variable LANG:

export LANG=en_US.UTF-8

And it seems that specifying content type and charset with a meta tag
is not enough. It has to be set using a <%@ page %> directive as well.

Now I have to find out how to define et_EE.UTF-8 for my system.

thanks,
Taavi

:-)

> Hope this helps.
> 
> Johan

it sure did






RE: request.getParameter() not working under solaris?

2001-04-11 Thread Taavi Tiirik


> probably you have to mention the char-set.
> I am not sure how you do this

Specifying char-set does not help. At least, when I add
meta tag like this:





It does not really matter what charset I use.
Whenever I ask (int)request.getParameter( "text" ).charAt( 0 ) It gives
me the very same character code 65533.

Please, any ideas?

with best regards,
Taavi


> I am experiencing strange behaviour of Orion 1.4.5 running on PC
Solaris
> 8
> with jdk1.3.
> 
> I do not get expected results when calling request.getParameter() on a
> jsp page. If I submit certain characters like "ä" for example (ie
> ä)
> then request.getParameter() returns character with a code 65533.
> 
> The same jsp page works with following configurations:
> Orion1.4.5, Win2000, jdk 1.3
> Tomcat3.2.1, the very same Solaris, jdk 1.3
> Tomcat3.2.1, Win2000, jdk 1.3
> 
>  Start of jsp page 
> 
> 
> 
> text="<%= request.getParameter( "text" ) %>"
> 
> 
> 
> 
> 
> 
> 
> 
>  End of jsp page --
> 
> Please, I could really use your help to solve this. If I cannot get
> orion
> working under Solaris I will have to change application server ASAP.
> Any thoughts are welcome.
> 
> with best regards,
> Taavi






request.getParameter() not working under solaris?

2001-04-11 Thread Taavi Tiirik

I am experiencing strange behaviour of Orion 1.4.5 running on PC Solaris
8
with jdk1.3.

I do not get expected results when calling request.getParameter() on a
jsp page. If I submit certain characters like "ä" for example (ie
ä)
then request.getParameter() returns character with a code 65533.

The same jsp page works with following configurations:
Orion1.4.5, Win2000, jdk 1.3
Tomcat3.2.1, the very same Solaris, jdk 1.3
Tomcat3.2.1, Win2000, jdk 1.3

 Start of jsp page 



text="<%= request.getParameter( "text" ) %>"








 End of jsp page --

Please, I could really use your help to solve this. If I cannot get
orion
working under Solaris I will have to change application server ASAP.
Any thoughts are welcome.

with best regards,
Taavi







RE: Connection Pooling

2001-03-27 Thread Taavi Tiirik

Have you tried adding following attributes to your data-source definition:

min-connections=...
max-connections=...

Take a look at http://www.orionserver.com/docs/data-sources.xml.html


regards,
Taavi

> How to specify min number of connections and max number of 
> connections in my
> data base connection pooling.  I am using the following settings 
> currently.
> 
>name="Oracle8" location="jdbc/Challenger"
> connection-driver="oracle.jdbc.driver.OracleDriver" username="vms"
> password="vms" url="jdbc:oracle:thin:@challenger:1521:vmsdev"
> inactivity-timeout="30"/>





RE: problem running oracle with orion: 'oracle.jdbc.driver.OracleDriver' not found!

2001-03-25 Thread Taavi Tiirik

Try following code in your .jsp file:

InitialContext ctx = new InitialContext();
DataSource ds = (DataSource)ctx.lookup("jdbc/Oracle");
Connection conn = ds.getConnection();

Statement stmt = conn.createStatement();
ResultSet rs = stmt.executeQuery("SELECT * FROM dual");

while( rs.next() ){
out.println( rs.getString(1) + "" );
}

conn.close();


with best wishes,
Taavi

> Thanks everybody for helping me with this problems. It works now! 
> However, I
> could not have the jsp example code work!