repost: FYI/PATCH: Log4j bug masks part of Orion's stack traces

2002-03-26 Thread Geoff Soutter

Seems the original went missing, again.

 -Original Message-
 From: Geoff Soutter [mailto:[EMAIL PROTECTED]] 
 Sent: Tuesday, 26 March 2002 3:46 PM
 To: 'Orion Interest List'
 Cc: [EMAIL PROTECTED]
 Subject: FYI/PATCH: Log4j bug masks part of Orion's stack traces
 
 
 Hi there,
 
 I've been having a weird problem with parts of my stack 
 traces disappearing.
 
 After a few hours mucking around I've tracked it down to a 
 bug in log4j that I thought you may all wish to be aware of.
 
 This shows up when you attempt to log an OrionRemoteException 
 in an application client which has been thrown from a session bean.
 
 If I call System.out.printStackTrace() I get:
 
 at com.evermind.server.ejb.EJBUtils.getUserException(.:207)
 at 
 mySessionBean_StatelessSessionBeanWrapper3.mySessionBeanMet
 hod(mySe
 ssionBean_StatelessSessionBeanWrapper3.java:153)
 at java.lang.reflect.Method.invoke(Native Method)
 at com.evermind._dq._fs(.:79)
 at com.evermind._bt.run(.:62)
 at connection to localhost/127.0.0.1 as admin
 at
 com.evermind._dn.EXCEPTION_ORIGINATES_FROM_THE_REMOTE_SERVER(.:1447)
 at com.evermind._dn.invokeMethod(.:1370)
 at com.evermind._yp.invoke(.:53)
 at __Proxy2.mySessionBeanMethod(Unknown Source)
 
 But if I log the same exception through log4j I get only:
 
 at
 com.evermind._dn.EXCEPTION_ORIGINATES_FROM_THE_REMOTE_SERVER(.:1447)
 at com.evermind._dn.invokeMethod(.:1370)
 at com.evermind._yp.invoke(.:53)
 at __Proxy2.mySessionBeanMethod(Unknown Source)
 
 Turns out the reason for this is that there is a bug in the 
 way log4j deals with stack traces. In log4j, stace track 
 formatting is handled by a class called ThrowableInformation. 
 It contains a subclass of PrintWriter called VectorWriter 
 which only overrides the println() - all the other methods 
 are effectively disabled. This class is passed into 
 Throwable.printStackTrace(). Unfortunately, Orion's implementation of
 OrionRemoteException.printStackTrace() is calling print() rather than
 println() to pass part of the remote part of the stack trace 
 across. Thus, this part of the stack trace is simply thrown 
 away. Ouch.
 
 This is a bug which impacts Orion and potentially any other 
 user of log4j which, in general, wishes to override the way that
 printStackTrace() works. It has been reported before on the 
 log4j developers list
 (http://www.mail-archive.com/log4j-dev@jakarta.apache.org/msg0
 0926.html)
 , but it appears Ceki is too busy to fix it :-).
 
 Note, I'm using log4j 1.x at the moment but I had a quick 
 check of the CVS repository and it appears the bug is in 
 latest stuff as well.
 
 I created a simplistic new version of 
 ThrowableInformation.getThrowableStrRep(), which sucks the 
 entire stack trace into a buffer and then parses it into 
 individual lines. It's probably kinda slow compared to the 
 old version, but at least it fixes the bug. I've included it 
 if you are interested.
 
   public
   String[] getThrowableStrRep() {
 if(rep != null) {
   return (String[]) rep.clone();
 } else {
   // NOTE: This is not particularly fast. This probably 
 needs to be
   // re-architected to use JDK1.4's new parsed stack 
 trace stuff anyway,
   // so I consider this to be only a temporary solution.
 
   // First, obtain the _entire_ stack trace as a string
   CharArrayWriter caw = new CharArrayWriter();
   PrintWriter pw = new PrintWriter(caw);
   throwable.printStackTrace(pw);
   pw.flush();
   String trace = caw.toString();
   // Parse it into individual lines.
   // This should handle both Win32 and Unix EOL markers 
 (hopefully).
   StringTokenizer tok = new StringTokenizer(trace, \r\n);
   Vector v = new Vector();
   while (tok.hasMoreTokens()) {
   v.add(tok.nextToken());
   }
   // Convert the result into an array, without using an 
 1.2 functionality
   int len = v.size();
   rep = new String[len];
   for(int i = 0; i  len; i++) {
 rep[i] = (String) v.elementAt(i);
   }
   return rep;
 }
   }
 
 Cheers
 
 Geoff
 
 
 --
 To unsubscribe, e-mail:   
 mailto:log4j-dev- [EMAIL PROTECTED]
 For 
 additional commands, 
 e-mail: mailto:[EMAIL PROTECTED]
 
 





RE: OC4J 9.0.3

2002-03-26 Thread Geoff Soutter

Presumably this is based on 1.5.4?

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED]] On Behalf Of sana
 Sent: Wednesday, 27 March 2002 2:05 PM
 To: Orion-Interest
 Subject: OC4J 9.0.3
 
 
 Hi,
 
 Oracle released OC4J 9.0.3 Developer Preview.
 
   http://otn.oracle.com/tech/java/oc4j/content_preview.html
 
 It supports most of J2EE 1.3 features.
 
  http://otn.oracle.com/tech/java/oc4j/htdocs/oc4j-feature-list.html

Regards,
sana


__
Do You Yahoo!?
Yahoo! BB is Broadband by Yahoo!
http://bb.yahoo.co.jp/







RE: idea=$395.00USD was: RE: Java IDE?

2002-03-24 Thread Geoff Soutter

Go Shane! 

This is one of the few sensible posts on IDE religion I've ever read!
:-) Theres nothing like a little common sense to distinguish the smart
developer from the average developer... :-)

Anyway, my .2c (apart from what shane said) - I'd recommend any of these
tools depending on the task at hand...

- IDEA (best all round, brilliant for XP, reasonable price, no GUI or
wizard hand-holding)
- Together (if you have _lots_ of $ and you _must_ use UML)
- JBlunder Enterprise (if you have _lots_ of $ and you really can't deal
with J2EE without a Wizard to hold your hand)
- CodeGuide (if you don't like NetBeans and you can't afford IDEA)
- Netbeans (if you like the price and can handle the clunky interface)
- Emacs / vi (if you are a Linux freak and bone-headed :-)
- Textpad (if you are a Win32 user and if all else fails :-)

Geoff

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED]] On Behalf Of 
 Shane Whitehead
 Sent: Monday, 25 March 2002 8:21 AM
 To: Orion-Interest
 Subject: RE: idea=$395.00USD was: RE: Java IDE?
 
 
 I believe it comes down to the individual requirements of the 
 developer. You can discuss it till your blue in the face, but 
 if it doesn't fill comfortable, then, like most users, you 
 won't use it.  Go with what feels right for you and don't be 
 to swayed with what other people think.
 
 I've been lucky that most of the places I've worked at have 
 allowed me to use the editor of my choice and personally I 
 prefer netbeans, but that's more to do with the fact that I 
 was required to use at Uni and at the time their was only a 
 hand full of editors and all of them (except Netbeans) seemed 
 to use a propriety VM - but that's ancient history.
 
 Most of the experience is in Swing and I hand code 99% of all 
 my UI, I've yet to meet a UI designer that can cut it.
 
 Essentially, try a few, find the one you like and hope it's 
 not to expensive, but at the end of the day, if you can't 
 live without it, you're going to have to pay for it...
 
 Good hunting!
 
 Shane
 
 
 





RE: OK, here's Real World: was: idea=$395.00USD was: RE: Java IDE?

2002-03-24 Thread Geoff Soutter

And don't forget we'll all be using Drag and Drop Visual tools to do
coding soon, so we won't even need tools like IDEA. I guess this will
make Computer Science degrees irrelevant as well?

LOL

Geoff


 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED]] On Behalf Of The Boss
 Sent: Monday, 25 March 2002 10:27 PM
 To: Orion-Interest
 Cc: Jarrod Roberson
 Subject: OK, here's Real World: was: idea=$395.00USD was: RE: 
 Java IDE?
 
 
 Hi Jarrod,
 
 I would like to share some IBM insights with you relevant to some of 
 your comments  ...
 
  So anyone that chants the FREE mantra keep using Tomcat and Vi and
  all  the other free crap because in the end it will cost you 
  HUNDREDS TIMES  more than buying a proper tool and saving 
 money over 
  the long haul. Then  again if you are lowballing jobs, and 
 working on 
  crappy little projects all  this is moot, why are you using Orion 
  then, why not use JBoss or any of the  other FREE EJB containers. I 
  mean you COULD move a mountian with a  plastic spoon, 
 hell they are 
  FREE at every fast food joint, but would'nt a  sane and reasonable 
  person spend the money on real earth moving equipment  and 
 get the job 
  done quickly so they could move on to the next paying job  
 moving the 
  next mountain.
 
 Some time ago I was involved in IBM's San Fransisco project, about 
 which you may know. This enterrpise level tool was
 very large and free for development I understand. Various tool makers 
 came up with ways of enhancing the development
 process including the integration of the Rational suite of 
 products. OK. 
 That was the story from the West. It turned out that
 the most productive developers of San Fransisco applications were NOT 
 the people who used fancy, expensive Yankee IDE's
 or tools, but the teams of hundreds of Indian programmers 
 around Mumbai. 
 The Indian software houses could not afford to
 pay guys like you, and provide guys like you with tools to make you 
 productive, and save you time, so you could be with your 
 family. No. They could afford to hire hundreds of developers 
 and provide 
 them with cheap development tools, like 'vi' ;), and
 let them loose on a task. So from this International competitive 
 perspective your comments are way off the mark, the kind
 of productivity you speak about, (great design guys, large scale 
 projects, etc) are irrelevant in the global domain. It 
 doesn't matter in the end how productive you are, or what 
 tools you use, you will NEVER 
 be able to compete with the developer farms of
 countries like India, and just wait till China comes on line! 
  I guess 
 the same thing that happened to the Western clothing
 industry WILL happen to the Western software development 
 business - it 
 will be moved off-shore into countries that have
 large volumes of super-cheap educated labour, using free 
 development tools.
 
 Unfortunately your comments sound like those of an ageing 
 Western prima 
 donna whose tunes are increasingly less
 popular. Sure tools like Idea were built for prima donna Western 
 software developers ... but with developer farms coming
 on line ... prima donnas and the tools that support them are becoming 
 less and less of a good business proposition.
 
 Perhaps you could start a crappy little project that could 
 make you a 
 lot of money, so you could retire early?
 ;)
 
 Regards
 goffredo
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 





Simple howto for launching application clients using applicationlauncher.jar

2002-03-06 Thread Geoff Soutter

Hi there peeps,

I've spent the last few hours looking at how to best launch application
clients, and I couldn't find any documentation on how to do it nicely
(apart from Joe Ottingers's stuff on auto started application clients -
http://www.orionsupport.com/articles/appclient.html). I then discovered
I was doing it the hard way, and it occurred to me that others may also
be doing it this way, so here's what I discovered...

Previously I was doing something basic like this to launch my
application clients:

java -jar %ORION_HOME%\orion.jar;%ORION_HOME%\many more orion
jars;%ORION_HOME%/lib/log4j.jar;myapp-client.jar com.acme.MyAppClient 

And I had a jndi.properties in the same directory which specified how to
connect to Orion.

This is clunky and requires that you distribute all your jar files to
the machine you wish to run it on. Yuck.

Then, I discovered applicationlauncher.jar (it's not exactly hidden,
it's in the Orion dir :-). This lets you launch application clients
locally, even if they are installed on remote systems. Its seemingly
like an Orion version of java web start.

To use it, you need to ensure that your application client is deployed
properly in a J2EE sense. For me, all I had to do was:
- add a module and java tags to my application.xml like so:

module
javamyapp-client.jar/java
/module

- copy my shared libraries into a lib dir inside my .ear file
- add a manifest for myapp-client.jar with the main class and any shared
libraries like so:

Manifest-Version: 1.0
Main-Class: com.acme.MyAppClient
Class-Path: lib/log4j.jar

Now, I can launch the application client by issuing the command

java -jar c:\apps\orion\154\applicationlauncher.jar
ormi://localhost/myapp/mayapp-client.jar user password

This is cool because I don't have to frig about with the classpath or
jndi.properties at launch time, presumably I could launch it on a remote
machine if I wanted with similar ease (!). Presumably all you would need
on the remote machine would be applicationlauncher.jar and orion.jar
(rather than all your applications jar files), but I've not tested it...

Anyone have any comments on this?

Cheers

Geoff





Orion doesn't pass stack traces from server to application client?

2002-02-28 Thread Geoff Soutter

Hi there,

I just noticed that the application client that I wrote for Orion is
printing stack traces like so:

javaxejbDuplicateKeyException: Entity already exists
at
comevermind_dnEXCEPTION_ORIGINATES_FROM_THE_REMOTE_SERVER(:1446)
at comevermind_dninvokeMethod(:1369)
at comevermind_ydinvoke(:53)
at __Proxy2my method(Unknown Source)

Which presumably means it is not passing the stack trace information
across from the server to the client 

This means I can't see the part of the stack trace on the server, which
is really annoying

Is there a way around this? I'm sure lots of people would have this
problem, so I'm probably just missing something obvious

Cheers

Geoff





RE: Orion crashes JVM

2002-02-27 Thread Geoff Soutter

If you are on windows, try pressing Ctrl-Break on the Orion window
(can't remember the kill number on unix). The JVM will print out a stack
dump of all the threads. That should help you to see if there is a
deadlock or something like that.

Geoff

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED]] On Behalf Of 
 Juan Fuentes
 Sent: Thursday, 28 February 2002 4:19 AM
 To: Orion-Interest
 Subject: Orion crashes JVM
 
 
 Hi list!
 
 After few moments of orion (1.5.2) been started, the cpu 
 usage of the JVM that runs orion drops to 0%.
 
 Obviously, orion stops answering requests.
 
 We are trying to find the problem. Don't know if it's in our 
 application (it runs OK in other machines with the same orion 
 server), in the orion itself, or even in the operating system.
 
 Any idea??
 
 Thanks.
 -- 
 ..
 Juan Fuentes Nieto   Essi Projects
 [EMAIL PROTECTED]t +34 977 221 182
 http://www.essiprojects.com  f +34 977 230 170
 ..
 
 





RE: Uploading files to Orion webserver with MultipartParser API

2002-02-27 Thread Geoff Soutter

Just be aware, MS don't number each release of their browser like NS do.
For example, the original release of 5.5 was very buggy, but it's had at
least a couple of Service Packs since then (5.5.1, 5.5.2, if you like). 

You need to indicate which service pack and which OS you are running on
before you can really compare IE versions properly.

You may also wish to ensure there are no proxies or anything like that
in the middle between IE and Orion, as they can change the HTTP stream.
Also, have you configured IE to use HTTP 1.0 or 1.1?

Try running the same example code on Tomcat 4.x, with your different
browsers. If that works you can pretty much blame Orion.

Geoff

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED]] On Behalf Of 
 Joan Josep Iglesias
 Sent: Thursday, 28 February 2002 3:14 AM
 To: Orion-Interest
 Subject: Re: Uploading files to Orion webserver with 
 MultipartParser API
 
 
 Hi again Justine,
 
   I've just prove it with an IE 5.5 and I have'nt got any 
 problem... I don't 
 know what problem you can have... If you want, you can try to 
 read the upload 
 file byte by byte... the way I token (by the moment).
 
   Good luck Justine!!
 
   Joan
 
 
 On Wednesday 27 February 2002 10:17 am, you wrote:
  Hi
 
  Thanks for that, I wasn't aware of those classes, I gave them a go. 
  Similar problem. Different error, but its occasionally 
 failing. I also 
  tried the non-brand-specific UploadServlet.java, similar results.
 
  However, I have gotten closer. It was failing on Internet Explorer 
  5.5. I tried Netscape 4.7, and it seemed fine. I tried it 
 on 5.0 and 
  IE 6 and it seemed fine. So it appears that it is a problem with IE 
  5.5. Very strange...
 
 
  Thanks for the help, much appreciated.
  Justin
 
  P.S. this is my second attempt at posting this, it appears the list 
  does not pick up everything that is posted.
 
  -Original Message-
  From: Joan Josep Iglesias [mailto:[EMAIL PROTECTED]]
  Sent: 22 February 2002 09:33
  To: Orion-Interest
  Subject: Re: Uploading files to Orion webserver with 
 MultipartParser 
  API
 
 
  Hi,
 
  I'm trying to upload files to my server, but I'm  using 
 the orion 
  libreries to do it
 
  
 http://kb.atlassian.com/content/orionsupport/a
rticles/fileupload.html
 
 
  Why don't you try with those libraries?
 
 
  Joan
 
 





RE: jndi.properties and ApplicationClientInitialContextFactory

2002-02-26 Thread Geoff Soutter

That'd be cool.

Geoff

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED]] On Behalf Of 
 Magnus Rydin
 Sent: Wednesday, 27 February 2002 10:22 AM
 To: Orion-Interest
 Subject: SV: jndi.properties and 
 ApplicationClientInitialContextFactory 
 
 
 Hi there,
 
 You would pay for the 1 server and not for the 10 clients.
 
 Hopefully we will find time to generate a small client.jar to 
 use instead of the larger jar files in the near future.
 
 WR
 Magnus Rydin
 IronFlare
 
 -Ursprungligt meddelande-
 Från: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]] För Brendan McKenna
 Skickat: den 26 februari 2002 09:06
 Till: Orion-Interest
 Ämne: Re: jndi.properties and ApplicationClientInitialContextFactory 
 
 
 Hi,
 
   Does the requirement to install orion.jar with every instance of
 
 the client application mean that you have to (in a commercial
 environment) 
 purchase an Orion license for each seperate instance of the 
 client you 
 want to run.  In other words, if I want to run 10 instances 
 of my client, plus 1 of the server itself, how many licenses 
 do I need to buy, 1 or 11?
 
 
 
   Brendan
 -- 
 Brendan McKenna   [EMAIL PROTECTED]
 Senior Partner
 Hallway Software Design Corp.
 
 
 
 





RE: A nonfatal internal JIT (3.10.107(x)) error ??

2002-02-24 Thread Geoff Soutter
Title: Message



By 
definition, it'sa JVM bug. There is no possible Java which may validly 
cause the VM to crash. (well, apart from Java which calls native 
code).

Try 
turning off the JIT. It will be slower but at least it won't crash. Also, try 
different VMs, eg IBM, or JDK1.4.

geoff


  
  -Original Message-From: 
  [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED]] On Behalf Of David 
  TunkransSent: Monday, 25 February 2002 2:34 AMTo: 
  Orion-InterestSubject: Re: A nonfatal internal JIT (3.10.107(x)) 
  error ??
  No. JDK1.3.x
  
- Original Message - 
From: 
daniele rizzi 
To: Orion-Interest 
Sent: Friday, February 22, 2002 4:50 
PM
Subject: R: A nonfatal internal JIT 
(3.10.107(x)) error ??


do 
you use jdk1.2.2?
d.


  -Messaggio originale-Da: [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED]]Per conto di David 
  TunkransInviato: venerdì 22 febbraio 2002 11.51A: 
  Orion-InterestOggetto: A nonfatal internal JIT (3.10.107(x)) 
  error ??
  Anyone know what this could be?
  
  $ java -jar orion.jar
  A nonfatal internal JIT (3.10.107(x)) error 
  'Relocation error: NULL relocation ta 
  'org/apache/crimson/parser/Parser2.maybeComment (Z)Z': Interpreting 
  method. Please report this error in detail to http://java.sun.com/cgi-bin/bugreport.cgi


RE: Uploading files to Orion webserver with MultipartParser API

2002-02-21 Thread Geoff Soutter

Hi there,

Did you read the http://www.servlets.com/cos/faq.html?

Cheers

Geoff

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED]] On Behalf Of 
 Justin Crosbie
 Sent: Friday, 22 February 2002 3:22 AM
 To: Orion-Interest
 Subject: Uploading files to Orion webserver with MultipartParser API
 
 
 Hi,
 
 I'm wondering if this has anything to do with the Orion 
 webserver. I am using the 
 com.oreilly.servlet.multipart.MultipartParser to upload files 
 to my servlet. If you try the same file several times, it 
 will sometimes work and sometimes fail with a Corrupt form 
 data: no leading boundary IOException.
 
 It fails because normally it expects to see a valid boundary 
 in the HttpServletRequest obj, but some of the time the 
 Header is being sent with the content. So where it expects to 
 see something like 
 12012133613061, it finds a POST 
 url... HTTP1.1 etc
 
 It is strange that it sometimes works and sometimes not. Is 
 there anything I can set on the webserver side to ensure that 
 the content is as is expected?
 
 Thanks,
 Justin
 
 





(repost) FW: A word of warning: SwiftMQ and Resource providers.

2002-02-19 Thread Geoff Soutter

Argh. Mailing lists that are not reliable annoy the  out of me.

-Original Message-
From: Geoff Soutter [mailto:[EMAIL PROTECTED]] 
Sent: Tuesday, 19 February 2002 9:32 AM
To: 'Orion-Interest'
Subject: RE: A word of warning: SwiftMQ and Resource providers.


Hi Magnus,

All I did was follow the instructions in the resource providers document
(http://www.orionserver.com/docs/resource-providers/resource-providers.x
ml)

As soon as I added the resource-provider tag you quoted below, and
restarted orion, I got:

C:\apps\orion\154java -jar orion.jar
Error deploying file:/C:/temp/newsfeed/build/newsfeed/newsfeed-ejb.jar
homes: JMS Error: Queue 'testtopic' is not local! Can't create a
Consumer on it!
2002-02-19 09:23:14,435 INFO   StartupServlet - startup completed
Orion/1.5.4 initialized

Which is exactly the same error as originally reported below.

Cheers,

Geoff

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of Magnus Rydin
Sent: Monday, 18 February 2002 7:35 PM
To: Orion-Interest
Subject: RE: A word of warning: SwiftMQ and Resource providers.


Geoff,

It IS fixed in 1.5.4, so please let us know what fails for you. Here is
a sample setup:

1. Set up and start SwiftMQ.

2. In your /config/application.xml have a setup like the following:
resource-provider
class=com.evermind.server.deployment.ContextScanningResourceProvider
display-name=SwiftMQ resource name=SwiftMQ  
description 
SwiftMQ resource provider. 
/description 
property name=java.naming.factory.initial
value=com.swiftmq.jndi.InitialContextFactoryImpl / 
property name=java.naming.provider.url value=smqp://localhost:4001
/ 
property name=resource.names
value=testtopic,testqueue@router1,plainsocket@router1 / 
/resource-provider

3. Start Orion, deploy the ATM sample (it uses a MDB with a topic)

4. Configure the ATM sample to use your resource provider with something
like the following in your orion-ejb-jar.xml: message-driven-deployment
name=mainLogger
destination-location=java:comp/resource/SwiftMQ/testtopic
connection-factory-location=java:comp/resource/SwiftMQ/plainsocket@rout
er1
ejb-ref-mapping name=ejb/mainLog /
/message-driven-deployment

Could you please let me know where/how this fails for you?

WR


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of Geoff Soutter
Sent: den 18 februari 2002 02:50
To: Orion-Interest
Subject: RE: A word of warning: SwiftMQ and Resource providers.

FYI, this was not fixed in 1.5.4. 

Naughty Magnus! :-)

Geoff


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of Ray Harrison
Sent: Monday, 14 January 2002 8:50 AM
To: Orion-Interest
Subject: Re: A word of warning: SwiftMQ and Resource providers.


According to Magnus R, the problem will be fixed in the next release. I
don't know if you can use SwiftMQ / Topics with the Oracle code base
(OC4J), but maybe worth a shot. Hopefully soon from the good folks at
Orion!
--- Graham Bennett [EMAIL PROTECTED] wrote:
 On Tue, Nov 20, 2001 at 12:29:54PM +0200, Lachezar Dobrev wrote:
 Recently looking at the Resource-Providers docs, and EAGER to use
 an external JMS for my MDBs I and a colleague decided to run the
 demos.  As quite a surprise the demo run ok. The MDB did
everything
 when a message was sent to the Queue.
  
 The BIG disappointment was, when we tried to do the same with the
 topic.  In short: It does not work.
 
  Error deploying 
  file:/D:/Temp/Orion/applications/Orion2SwiftMQ/Orion2SwiftMQ.jar
  homes: JMS Error: Queue 'testtopic' is not local! Can't create a
  Consumer on it!
 
 has this now been fixed?  I'm getting the same error with SwiftMQ and 
 the latest build.
 
 cheers,
 
 --
 Graham Bennett
 [EMAIL PROTECTED]
 


__
Do You Yahoo!?
Send FREE video emails in Yahoo! Mail! http://promo.yahoo.com/videomail/







RE: (repost) FW: A word of warning: SwiftMQ and Resource providers.

2002-02-19 Thread Geoff Soutter

Hmm. Strange. 

I'm definitely using 1.5.4, you can see it in the console output I
included below. I tried doing an autoupdate and trying it again, made no
difference. I even did a recursive diff against the .zip version and the
autoupdate version and they are identical (despite the fact autoupdate
claimed it was overwriting most of the files).

There must be a logical explanation ... but I can't see it ...

I'm using jdk 1.3.1_02 and SwiftMQ 2.1.3. Is that the versions you guys
are using?

geoff

PS, I'm not using Topics myself, I was only providing a FYI for those
that cared... 

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of Ray Harrison
Sent: Wednesday, 20 February 2002 10:04 AM
To: Orion-Interest
Cc: [EMAIL PROTECTED]
Subject: Re: (repost) FW: A word of warning: SwiftMQ and Resource
providers.


Interesting - I *don't* get that error any longer with 1.5.4, though I
did with 1.5.3.
--- Geoff Soutter [EMAIL PROTECTED] wrote:
 Argh. Mailing lists that are not reliable annoy the  out of me.
 
 -Original Message-
 From: Geoff Soutter [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, 19 February 2002 9:32 AM
 To: 'Orion-Interest'
 Subject: RE: A word of warning: SwiftMQ and Resource providers.
 
 
 Hi Magnus,
 
 All I did was follow the instructions in the resource providers 
 document 

(http://www.orionserver.com/docs/resource-providers/resource-providers.x
 ml)
 
 As soon as I added the resource-provider tag you quoted below, and 
 restarted orion, I got:
 
 C:\apps\orion\154java -jar orion.jar
 Error deploying file:/C:/temp/newsfeed/build/newsfeed/newsfeed-ejb.jar
 homes: JMS Error: Queue 'testtopic' is not local! Can't create a 
 Consumer on it!
 2002-02-19 09:23:14,435 INFO   StartupServlet - startup completed
 Orion/1.5.4 initialized
 
 Which is exactly the same error as originally reported below.
 
 Cheers,
 
 Geoff
 
 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]] On Behalf Of Magnus 
 Rydin
 Sent: Monday, 18 February 2002 7:35 PM
 To: Orion-Interest
 Subject: RE: A word of warning: SwiftMQ and Resource providers.
 
 
 Geoff,
 
 It IS fixed in 1.5.4, so please let us know what fails for you. Here 
 is a sample setup:
 
 1. Set up and start SwiftMQ.
 
 2. In your /config/application.xml have a setup like the following: 
 resource-provider 
 class=com.evermind.server.deployment.ContextScanningResourceProvider
 display-name=SwiftMQ resource name=SwiftMQ 
 description 
 SwiftMQ resource provider. 
 /description 
 property name=java.naming.factory.initial
 value=com.swiftmq.jndi.InitialContextFactoryImpl / 
 property name=java.naming.provider.url
value=smqp://localhost:4001
 / 
 property name=resource.names
 value=testtopic,testqueue@router1,plainsocket@router1 / 
 /resource-provider
 
 3. Start Orion, deploy the ATM sample (it uses a MDB with a topic)
 
 4. Configure the ATM sample to use your resource provider with 
 something like the following in your orion-ejb-jar.xml: 
 message-driven-deployment name=mainLogger 
 destination-location=java:comp/resource/SwiftMQ/testtopic
 connection-factory-location=java:comp/resource/SwiftMQ/plainsocket@ro
 ut
 er1
   ejb-ref-mapping name=ejb/mainLog /
   /message-driven-deployment
 
 Could you please let me know where/how this fails for you?
 
 WR
 
 
 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]] On Behalf Of Geoff 
 Soutter
 Sent: den 18 februari 2002 02:50
 To: Orion-Interest
 Subject: RE: A word of warning: SwiftMQ and Resource providers.
 
 FYI, this was not fixed in 1.5.4.
 
 Naughty Magnus! :-)
 
 Geoff
 
 
 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]] On Behalf Of Ray 
 Harrison
 Sent: Monday, 14 January 2002 8:50 AM
 To: Orion-Interest
 Subject: Re: A word of warning: SwiftMQ and Resource providers.
 
 
 According to Magnus R, the problem will be fixed in the next release. 
 I don't know if you can use SwiftMQ / Topics with the Oracle code base

 (OC4J), but maybe worth a shot. Hopefully soon from the good folks at 
 Orion!
 --- Graham Bennett [EMAIL PROTECTED] wrote:
  On Tue, Nov 20, 2001 at 12:29:54PM +0200, Lachezar Dobrev wrote:
  Recently looking at the Resource-Providers docs, and EAGER to
use
  an external JMS for my MDBs I and a colleague decided to run
the
  demos.  As quite a surprise the demo run ok. The MDB did
 everything
  when a message was sent to the Queue.
   
  The BIG disappointment was, when we tried to do the same with
the
  topic.  In short: It does not work.
  
   Error deploying
   file:/D:/Temp/Orion/applications/Orion2SwiftMQ/Orion2SwiftMQ.jar
   homes: JMS Error: Queue 'testtopic' is not local! Can't create a
   Consumer on it!
  
  has this now been fixed?  I'm getting the same error with SwiftMQ 
  and
  the latest build.
  
  cheers,
  
  --
  Graham Bennett
  [EMAIL PROTECTED

RE: Orion MDB reverses message order with SwiftMQ as well as OrionJMS (was RE: fyi: 1.5.4 still stacks rather than queues JMS messages)

2002-02-18 Thread Geoff Soutter

Hi there,

Actually I didn't read the EJB spec as I had guessed it was a JMS bug
originally, so thanks for pointing that out. Very lazy of me. However,
section 15.4.6 Concurrency of Message Processing of the EJB 2.0 spec
says: 

the container should attempt to deliver messages in order when it does
not impair the concurrency of message processing.

I have max-instances set to 1, which means that there is _no_
concurrency. Thus, the container ought to deliver messages in order.
Note also that the JMS spec mentions that messages ought to be delivered
in order as well.

Geoff


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of Poop
Sent: Tuesday, 19 February 2002 12:11 AM
To: Orion-Interest
Subject: Re: Orion MDB reverses message order with SwiftMQ as well as
OrionJMS (was RE: fyi: 1.5.4 still stacks rather than queues JMS
messages)


Well, I just tested an MDB with SwiftMQ, and Orion still stuffs up the
message ordering.  --Geoff Soutter

Please read the EJB2.0 spec before recording this as a bug.  Message
order is not guaranteed in MDB's.


- Original Message -
From: Geoff Soutter [EMAIL PROTECTED]
To: Orion-Interest [EMAIL PROTECTED]
Sent: Sunday, February 17, 2002 10:45 PM
Subject: Orion MDB reverses message order with SwiftMQ as well as
OrionJMS (was RE: fyi: 1.5.4 still stacks rather than queues JMS
messages)


 Well, I just tested an MDB with SwiftMQ, and Orion still stuffs up the

 message ordering. Presumably this means it's broken in the MDB 
 implemenation rather than in Orion's JMS code, which is a pity.

 So, for all those using Orion MDBs, and relying on message ordering 
 being preserved (if there are any apart from me :-), please check out 
 bug 729 in Bugzilla. It contains demo code to demonstrate the problem 
 under both Orion JMS and SwiftMQ.

 http://bugzilla.orionserver.com/bugzilla/show_bug.cgi?id=729

 Cheers,

 Geoff

 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]] On Behalf Of Geoff 
 Soutter
 Sent: Monday, 18 February 2002 9:18 AM
 To: Orion-Interest
 Subject: RE: fyi: 1.5.4 still stacks rather than queues JMS messages


 Hi Mike,

 I didn't see that comment. Unfortunately this list is so flakey that I

 only get about 75% of the messages.

 I just checked the JMS 1.02 spec, here's what it has to say about 
 message order (in 4.4.10.1 Order of Message Receipt):

 JMS defines that messages sent by a session to a destination must be 
 received in the order in which they were sent (see Section 4.4.10.2, 
 Order of Message Sends, for a few qualifications).

 So it seems that, contrary to what that someone said, message order 
 _is_ important with JMS.

 Cheers,

 Geoff
 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]] On Behalf Of Mike 
 Cannon-Brookes
 Sent: Saturday, 16 February 2002 8:43 AM
 To: Orion-Interest
 Subject: Re: fyi: 1.5.4 still stacks rather than queues JMS messages


 Geoff,

 Also as someone said on this list just a few days ago - as per the JMS

 spec there is no guarantee that your messages turn up in the sequence 
 you sent them.

 Cheers,
 Mike

 Mike Cannon-Brookes
 [EMAIL PROTECTED]

 Atlassian :: www.atlassian.com
 Supporting YOUR world


 On 16/2/02 12:55 AM, Stephen Davidson ([EMAIL PROTECTED]) 
 penned the words:

  Geoff Soutter wrote:
 
  Re the problem reported a couple weeks back by Jorge Jimenez and 
  confirmed by myself, I tested 1.5.4 to see if they had fixed this 
  problem, but it's still there. Just set max-instances to 1 and load

  up with a lot of messages, it works just like a stack. Doh.
 
  Maybe I'll have time to put this into Bugzilla next week...
 
  Is _everyone_ using a third party JMS with Orion?
 
  geoff
 
 
 
 
 
  I am using the Orion JMS, but the way the code is set up, it does 
  not care about the order the messages arrived.  I had never noticed 
  the Out of Order issue, as it was not applicable.
 
  -Steve









_
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com







RE: fyi: 1.5.4 still stacks rather than queues JMS messages

2002-02-17 Thread Geoff Soutter

Hi Mike,

I didn't see that comment. Unfortunately this list is so flakey that I
only get about 75% of the messages. 

I just checked the JMS 1.02 spec, here's what it has to say about
message order (in 4.4.10.1 Order of Message Receipt):

JMS defines that messages sent by a session to a destination must be
received in the order in which they were sent (see Section 4.4.10.2,
Order of Message Sends, for a few qualifications).

So it seems that, contrary to what that someone said, message order _is_
important with JMS.

Cheers,

Geoff
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of Mike
Cannon-Brookes
Sent: Saturday, 16 February 2002 8:43 AM
To: Orion-Interest
Subject: Re: fyi: 1.5.4 still stacks rather than queues JMS messages


Geoff,

Also as someone said on this list just a few days ago - as per the JMS
spec there is no guarantee that your messages turn up in the sequence
you sent them.

Cheers,
Mike

Mike Cannon-Brookes
[EMAIL PROTECTED]

Atlassian :: www.atlassian.com
Supporting YOUR world


On 16/2/02 12:55 AM, Stephen Davidson ([EMAIL PROTECTED])
penned the words:

 Geoff Soutter wrote:
 
 Re the problem reported a couple weeks back by Jorge Jimenez and 
 confirmed by myself, I tested 1.5.4 to see if they had fixed this 
 problem, but it's still there. Just set max-instances to 1 and load 
 up with a lot of messages, it works just like a stack. Doh.
 
 Maybe I'll have time to put this into Bugzilla next week...
 
 Is _everyone_ using a third party JMS with Orion?
 
 geoff
 
 
 
 
 
 I am using the Orion JMS, but the way the code is set up, it does not 
 care about the order the messages arrived.  I had never noticed the 
 Out of Order issue, as it was not applicable.
 
 -Steve







Orion MDB reverses message order with SwiftMQ as well as OrionJMS (was RE: fyi: 1.5.4 still stacks rather than queues JMS messages)

2002-02-17 Thread Geoff Soutter

Well, I just tested an MDB with SwiftMQ, and Orion still stuffs up the
message ordering. Presumably this means it's broken in the MDB
implemenation rather than in Orion's JMS code, which is a pity. 

So, for all those using Orion MDBs, and relying on message ordering
being preserved (if there are any apart from me :-), please check out
bug 729 in Bugzilla. It contains demo code to demonstrate the problem
under both Orion JMS and SwiftMQ.

http://bugzilla.orionserver.com/bugzilla/show_bug.cgi?id=729

Cheers,

Geoff

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of Geoff Soutter
Sent: Monday, 18 February 2002 9:18 AM
To: Orion-Interest
Subject: RE: fyi: 1.5.4 still stacks rather than queues JMS messages


Hi Mike,

I didn't see that comment. Unfortunately this list is so flakey that I
only get about 75% of the messages. 

I just checked the JMS 1.02 spec, here's what it has to say about
message order (in 4.4.10.1 Order of Message Receipt):

JMS defines that messages sent by a session to a destination must be
received in the order in which they were sent (see Section 4.4.10.2,
Order of Message Sends, for a few qualifications).

So it seems that, contrary to what that someone said, message order _is_
important with JMS.

Cheers,

Geoff
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of Mike
Cannon-Brookes
Sent: Saturday, 16 February 2002 8:43 AM
To: Orion-Interest
Subject: Re: fyi: 1.5.4 still stacks rather than queues JMS messages


Geoff,

Also as someone said on this list just a few days ago - as per the JMS
spec there is no guarantee that your messages turn up in the sequence
you sent them.

Cheers,
Mike

Mike Cannon-Brookes
[EMAIL PROTECTED]

Atlassian :: www.atlassian.com
Supporting YOUR world


On 16/2/02 12:55 AM, Stephen Davidson ([EMAIL PROTECTED])
penned the words:

 Geoff Soutter wrote:
 
 Re the problem reported a couple weeks back by Jorge Jimenez and
 confirmed by myself, I tested 1.5.4 to see if they had fixed this 
 problem, but it's still there. Just set max-instances to 1 and load 
 up with a lot of messages, it works just like a stack. Doh.
 
 Maybe I'll have time to put this into Bugzilla next week...
 
 Is _everyone_ using a third party JMS with Orion?
 
 geoff
 
 
 
 
 
 I am using the Orion JMS, but the way the code is set up, it does not
 care about the order the messages arrived.  I had never noticed the 
 Out of Order issue, as it was not applicable.
 
 -Steve









RE: fyi: 1.5.4 still stacks rather than queues JMS messages

2002-02-17 Thread Geoff Soutter

Hi Russ,

What exactly do you mean by stored/retrieved? Is there a reference in
the spec you can point out?

Cheers

Geoff


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of Russ White
Sent: Monday, 18 February 2002 11:47 AM
To: Orion-Interest
Subject: RE: fyi: 1.5.4 still stacks rather than queues JMS messages


Yes, they should be received in order, but not necessarily
stored/retrieved in order.

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]On Behalf Of Geoff Soutter
Sent: Sunday, February 17, 2002 5:18 PM
To: Orion-Interest
Subject: RE: fyi: 1.5.4 still stacks rather than queues JMS messages


Hi Mike,

I didn't see that comment. Unfortunately this list is so flakey that I
only get about 75% of the messages.

I just checked the JMS 1.02 spec, here's what it has to say about
message order (in 4.4.10.1 Order of Message Receipt):

JMS defines that messages sent by a session to a destination must be
received in the order in which they were sent (see Section 4.4.10.2,
Order of Message Sends, for a few qualifications).

So it seems that, contrary to what that someone said, message order _is_
important with JMS.

Cheers,

Geoff
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of Mike
Cannon-Brookes
Sent: Saturday, 16 February 2002 8:43 AM
To: Orion-Interest
Subject: Re: fyi: 1.5.4 still stacks rather than queues JMS messages


Geoff,

Also as someone said on this list just a few days ago - as per the JMS
spec there is no guarantee that your messages turn up in the sequence
you sent them.

Cheers,
Mike

Mike Cannon-Brookes
[EMAIL PROTECTED]

Atlassian :: www.atlassian.com
Supporting YOUR world


On 16/2/02 12:55 AM, Stephen Davidson ([EMAIL PROTECTED])
penned the words:

 Geoff Soutter wrote:

 Re the problem reported a couple weeks back by Jorge Jimenez and 
 confirmed by myself, I tested 1.5.4 to see if they had fixed this 
 problem, but it's still there. Just set max-instances to 1 and load 
 up with a lot of messages, it works just like a stack. Doh.

 Maybe I'll have time to put this into Bugzilla next week...

 Is _everyone_ using a third party JMS with Orion?

 geoff





 I am using the Orion JMS, but the way the code is set up, it does not 
 care about the order the messages arrived.  I had never noticed the 
 Out of Order issue, as it was not applicable.

 -Steve










RE: Debugging using JPDA, FATAL ERROR

2002-02-14 Thread Geoff Soutter

No worries, mate. I blame sun, the error message is hopeless.

geoff

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of
[EMAIL PROTECTED]
Sent: Thursday, 14 February 2002 6:54 PM
To: Orion-Interest
Subject: RE: Debugging using JPDA, FATAL ERROR


Thanks Geoff, you were right.
Tibor

-Original Message-
From: Geoff Soutter [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, February 13, 2002 11:34 PM
To: Orion-Interest
Subject: RE: Debugging using JPDA, FATAL ERROR


Hmm, I seem to remember this one as well. Make sure you are using the
java.exe from the JDK directory rather than the JRE, as in the latest
1.3.1 revision only the JDK java.exe seems to have access to JPDA (or at
least, that's what I remember, YMMV)

Geoff


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of
[EMAIL PROTECTED]
Sent: Wednesday, 13 February 2002 8:10 PM
To: Orion-Interest
Subject: Debugging using JPDA, FATAL ERROR


Hi, 

I'd need some urgent help on starting Orion with JDPA remote debugging
enabled.

I read through the docs and followed the instructions to start this way:

java -classic -Xdebug -Xnoagent -Djava.compiler=NONE
-Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=8000 -jar
orion.jar


But it came up with a FATAL ERROR :

Transport dt_socket failed to initialize, rc = 509.
FATAL ERROR in native method: No transports initialized abnormal program
termination

In case you have some ideas, share them with me.

Thanks, 

Tibor








fyi: 1.5.4 still stacks rather than queues JMS messages

2002-02-14 Thread Geoff Soutter

Re the problem reported a couple weeks back by Jorge Jimenez and
confirmed by myself, I tested 1.5.4 to see if they had fixed this
problem, but it's still there. Just set max-instances to 1 and load up
with a lot of messages, it works just like a stack. Doh. 

Maybe I'll have time to put this into Bugzilla next week...

Is _everyone_ using a third party JMS with Orion?

geoff





RE: System Date.

2002-02-12 Thread Geoff Soutter
Title: Message



I've 
had problems with Java timezones before. As I remember, Unix inherits timezone 
settings from it's environment. Did you run your java test class with the same 
environment as Orion (eg the same user)? 

geoff

  
  -Original Message-From: 
  [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED]] On Behalf Of Troy 
  GibsonSent: Wednesday, 13 February 2002 6:00 AMTo: 
  Orion-InterestSubject: System Date.
  Having trouble with system Date. In Orion 
  our application converts dates based on our users time zone. For some reason 
  our application is producing incorrect date times. The same piece of code when 
  ran on its own as a Java class produces correct time conversions. Are there 
  environment variables that Orion uses that may cause it to interprets the 
  system date differently than what the system date really is? We use a staging 
  and production instances of Orion running on two different Unix boxes. Both 
  boxes have the same system date, the application running on staging produces 
  correct dates, the one on production does not, further evidence that maybe the 
  problem lies with the Orion instance and not the code or the 
  servers.
  Thanks for any ideas you may have. 
  


[announce] Log4J Appender for Orion's application.log

2002-02-06 Thread Geoff Soutter

Hi there,

I've hacked up an Orion Appender to allow you to log to the
application.log file, via the Logger instance that Orion installs at
java:comp/Logger. Here it is in all it's glory, use it however you wish.

Cheers

Geoff

PS, did anyone figure out if it's possible to get orion to roll it's log
files when they get too big? ;-)

import com.evermind.util.LogEvent;
import com.evermind.util.Logger;
import org.apache.log4j.AppenderSkeleton;
import org.apache.log4j.Layout;
import org.apache.log4j.PatternLayout;
import org.apache.log4j.spi.ErrorCode;
import org.apache.log4j.spi.LoggingEvent;
import org.apache.log4j.spi.ThrowableInformation;

import javax.naming.Context;
import javax.naming.InitialContext;
import javax.rmi.PortableRemoteObject;

/*
Example Test Code

Deploy OrionAppender with log4j in the Orion lib directory,
then add this code to an EJB or JSP and execute it.

Note it doesn't seem to be able to find a Logger instance when
running
in an application client, so in this case use a normal log4j
Appender.

Category log = Category.getInstance(for.bar.Category);
BasicConfigurator.resetConfiguration(); // for jsp reloading
BasicConfigurator.configure(new OrionAppender());
log.info(A test INFO message);
NDC.push(demo-ndc);
log.warn(A test WARN message with NDC);
NDC.pop();
log.fatal(A test FATAL message with exception, new
Exception(fatal));
*/

public class OrionAppender extends AppenderSkeleton {

// NOTE: Most simple layouts are not useful for this Appender
because
// the design of log4j is such that Layouts are responsible for
adding
// line endings, and we require that the Layout not add line
endings.
// This is IMHO a design flaw in log4j...

// NOTE: Orion includes a 2/5/02 5:46 PM format date in each log
entry.
// NOTE: Orion doesn't generate unique names for each thread, so the
thread
// name pattern entry is not much use.

// NOTE: Using a hardcoded layout now, can make this configurable
later.
// Basically it's priority category [ndc]: message
private static final Layout sLayout = new PatternLayout(
%-5p %c{1} [%x]: %m);

private Logger iLogger;

public OrionAppender() {
try {
Context lContext = new InitialContext();
Object lBoundObject = lContext.lookup(java:comp/Logger);
iLogger = (Logger) PortableRemoteObject.narrow(lBoundObject,
Logger.class);
} catch (Exception e) {
errorHandler.error(Error finding Orion Logger for appender
[ +
name + ]., e, ErrorCode.GENERIC_FAILURE);
}
}

public boolean requiresLayout() {
// Tell the configurator we have our own hardcoded layout.
// See PropertyConfigurator for how this method is used.
return false;
}

protected void append(LoggingEvent event) {
if (iLogger == null) {
errorHandler.error(No Logger for appender [ + name +
].);
return;
}
try {
LogEvent lEvent = null;
String lMessage = sLayout.format(event);
ThrowableInformation lInfo =
event.getThrowableInformation();
if (lInfo == null) {
lEvent = new LogEvent(lMessage);
} else {
lEvent = new LogEvent(lMessage, lInfo.getThrowable());
}
iLogger.log(lEvent);
} catch (Exception lEx) {
errorHandler.error(Could not log message in appender [ +
name
+ ]., lEx, ErrorCode.GENERIC_FAILURE);
}
}

public synchronized void close() {
iLogger = null;
}
}





Log4j appender for logging to application.log

2002-02-04 Thread Geoff Soutter

Hi there,

I've been doing some research about how to log using log4j with Orion. I
was thinking that I'd like to have the log written to the Orion
application log file so that you can see the order that things happen
in. You can see other people have done similar things for other app
servers, eg weblogic (see the source posted at
http://www.geocrawler.com/lists/3/Web/8359/0/7380790/ and
http://theserverside.com/discussion/thread.jsp?thread_id=2194).

I noticed some discussion on the list about logging using log4j to the
application.log file by writing an OrionAppender class which logs via
the com.evermind.util.Logger and LogEvent which are supposedly located
at java:comp/Logger
(http://www.mail-archive.com/orion-interest@orionserver.com/msg11512.htm
l,
http://www.mail-archive.com/orion-interest@orionserver.com/msg06399.html
,
http://www.mail-archive.com/orion-interest@orionserver.com/msg06502.html
).

Has anyone attempted to implement such logger? 

If not, I'm thinking of having a hack myself...

Cheers

Geoff





RE: Questionnaire

2002-02-03 Thread Geoff Soutter

I was wondering what the (BS) stood for :-)

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of Robb (BS)
Sent: Sunday, February 03, 2002 8:10 AM
To: Orion-Interest
Cc: [EMAIL PROTECTED]
Subject: Re: Questionnaire


If you cannot control your weblist from people who deploy viruses, how
in the hell can you make a decent app server

Please remove me from your list ASAP!!
- Original Message - 
From: chen.hui 
To: Orion-Interest 
Sent: Saturday, February 02, 2002 9:31 AM
Subject: Questionnaire





RE: TX Was Null

2002-01-29 Thread geoff

Hmm.  You potentially have a good point about the transaction retries, I
hadn't considered that.  I wouldn't have expected the application server to
retry with an application-level exception is thrown, though.  Do you know
that to be the case?

I like to keep the validation within the OM for a stronger OOP design,
wherein the objects cannot be loaded with invalid data.  That said, I've had
to make a number of tradeoffs for EJB already, this may be another.  I've
seen a number of postings where people put snapshots in the value objects,
but when you get to that point, EJB just seems as if you're using it for a
really clumsy persistence layer instead of true enterprise objects.

Our validation helper classes are already re-usable, so I wouldn't gain much
there.  We also have a CompositeValidationException class with a map of
validation errors--interesting to see you went with a similar approach.

- Geoffrey

: -Original Message-
: From: Manuel De Jesus [mailto:[EMAIL PROTECTED]]
: Sent: Tuesday, January 29, 2002 2:11 AM
: To: Orion-Interest
: Subject: RE: TX Was Null
: 
: 
: I don't think that relying on your Entity Beans for front line data
: validation is a good design. As a rule of thumb to get the 
: best performance
: in applications you want to validate as early as you can to 
: save the trouble
: of having to process all the steps for a transaction only to 
: find the data
: is invalid when you want to save things and use this to throw 
: an error. In
: most app servers you usaully set transaction retries to at 
: least 2 (incase
: there was a network/temporary error on the first attempt this 
: increases the
: reliablity) - by throwing data validation exceptions at the 
: EJB level you
: are looking at doing a TX twice before reporting the error 
: ... terrible
: performance.
: 
: What I have done in projects is to abstract validation to a set of
: Validation classes that are normal java classes which can 
: be used on the
: jsp/ejb etc etc tier. These classes interact with the 
: database via singleton
: caches allowing for dynamic validation updates (worth their 
: weight in gold).
: This also means that the stand alone validation objects can 
: be easily reused
: in other projects, expecially the rules that are generic enough :).
: 
: Using a separate set of validation classes I would suggest:
: 1) Validate the TX at the point where it starts right up 
: front if you are
: using jsp etc if this is an option.
: 2) Validate the TX in the actual session bean. We use a 
: custom exception
: with a Vector of string mappings that allows us to complain 
: about more than
: one error etc.
: 3) If you are really paranoid/have mutiple update points you can also
: validate at the entity bean and even a littel at the db level 
: (not null,
: size etc).
: 
: Since you are using a shared validation library, changing the 
: validation is
: done in one place. In addition your application = 100 times 
: faster since you
: are not rolling back transactions a million times over. And 
: the big bonus is
: it will work on 99% of app servers.
: 
: Regards,
: Manuel
: 
: 
: -Original Message-
: From: [EMAIL PROTECTED]
: [mailto:[EMAIL PROTECTED]]On Behalf Of
: [EMAIL PROTECTED]
: Sent: Monday, January 28, 2002 5:13 PM
: To: Orion-Interest
: Cc: [EMAIL PROTECTED]
: Subject: TX Was Null
: 
: 
: We're coming up on our deployment date, so we're considering 
: our deployment
: options (notably, at this point, JBoss and Orion).
: 
: The system is running and working under JBoss, and I've been 
: re-porting it
: to Orion so that we can do some testing, try and resolve some 
: issues we had
: under Orion (for which we got some help from Atlassian that 
: we haven't had a
: chance to try out yet).  In the process, we've re-adjusted 
: most or all of
: the finders, and fixed a few bugs here and there between what 
: JBoss does and
: what Orion does.  It's been enlightening, as usual.
: 
: That said, we've run up against a brick wall.  One of our 
: transactional
: saves uses a session bean to save two entities in a combined 
: declarative
: transaction.  Each of these beans can throw validation exceptions when
: passed data that's meant to save.  We have two unit tests, 
: one which throws
: invalid data into the first object, and another which throws 
: invalid data
: into the second object.
: 
: The second object is relatively easy -- if it has problems, 
: the session bean
: sets the transaction to rollback only, and lets the server do 
: the rest of
: the work.  This works under both Orion and JBoss as expected.
: 
: If the first object fails, though, there are larger issues -- 
: we still want
: to find out if there's a problem with the data being passed 
: to the second
: object.  Under JBoss, if we tried to do this in the same 
: transaction, it
: complained that the transaction was already rolled back, 
: which is sensible.
: So we put the validation method into a 'requires new' transaction.  On

RE: Container leaving Dirty Connection in CMP with container-managed transactions

2002-01-29 Thread Geoff Soutter

You could try using your own wrappers on the JDBC classes ala this
article

http://www.onjava.com/lpt/a/onjava/2001/12/05/optimization.html

Then, you can see exactly what Orion is calling. At least that helps
track the bug down a bit. 

Actually, maybe you could use this method to force Oracle to clean
itself up better? That is, to enforce the contract of the
Connection.close() method (as pointed out in Avi's email that you
forwarded to the list). Actually, if what he says is true, maybe all us
Oracle users could use some wrappers like that! :-)

Cheers

geoff

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of Jeff Hubbach
Sent: Wednesday, January 30, 2002 3:44 AM
To: Orion-Interest
Subject: Container leaving Dirty Connection in CMP with
container-managed transactions


If an exception is thrown in a CMP entity bean with container-managed
transactions, a Dirty Connection is left behind that is never cleaned up
(or at least in 15 minutes). We've set inactivity-timeout in the
data-sources and tweaked with all the transaction settings, all to no
avail. Is anyone experiencing this?

It does this with Oracle (running Oracle's driver as well as Merant's),
PostgreSQL, and SQL Server (running Merant's driver).

The biggest issue is that the dirty connection in Oracle and SQL Server
is holding a lock to the row that caused the exception, preventing any
further access, actually deadlocking the server (in PostgreSQL, further
updates to that row go through just fine). Or at least this is what we
_think_ is happening, as there's no better explanation that we've found.

Jeff.





TX Was Null

2002-01-28 Thread geoff

We're coming up on our deployment date, so we're considering our deployment
options (notably, at this point, JBoss and Orion).

The system is running and working under JBoss, and I've been re-porting it
to Orion so that we can do some testing, try and resolve some issues we had
under Orion (for which we got some help from Atlassian that we haven't had a
chance to try out yet).  In the process, we've re-adjusted most or all of
the finders, and fixed a few bugs here and there between what JBoss does and
what Orion does.  It's been enlightening, as usual.

That said, we've run up against a brick wall.  One of our transactional
saves uses a session bean to save two entities in a combined declarative
transaction.  Each of these beans can throw validation exceptions when
passed data that's meant to save.  We have two unit tests, one which throws
invalid data into the first object, and another which throws invalid data
into the second object.

The second object is relatively easy -- if it has problems, the session bean
sets the transaction to rollback only, and lets the server do the rest of
the work.  This works under both Orion and JBoss as expected.

If the first object fails, though, there are larger issues -- we still want
to find out if there's a problem with the data being passed to the second
object.  Under JBoss, if we tried to do this in the same transaction, it
complained that the transaction was already rolled back, which is sensible.
So we put the validation method into a 'requires new' transaction.  On
JBoss, if the first object fails, the second one tests its data in a new
transaction, gathers the validation errors, and rolls back.  On Orion, this
seems to create an exception:

Testcase: testProgramRollback took 4.703 sec
Caused an ERROR
Transaction was rolled back: Error in transaction: java.lang.InternalError:
TX was null; nested exception is: 
java.lang.InternalError: TX was null
com.evermind.server.rmi.OrionRemoteException: Transaction was rolled back:
Error in transaction: java.lang.InternalError: TX was null
at
TransactionalSaver_StatelessSessionBeanWrapper176.saveProgramAndCaseStudy(Tr
ansactionalSaver_StatelessSessionBeanWrapper176.java:104)
at java.lang.reflect.Method.invoke(Native Method)
at com.evermind._dh._gc(Unknown Source)
at com.evermind._if.run(Unknown Source)
at connection to localhost/127.0.0.1 as thesquareUser
at
com.evermind._cd.EXCEPTION_ORIGINATES_FROM_THE_REMOTE_SERVER(Unknown Source)
at com.evermind._cd.invokeMethod(Unknown Source)
at com.evermind._dn.invoke(Unknown Source)
at __Proxy7.saveProgramAndCaseStudy(Unknown Source)
at
com.mediumone.thesquare.ejb.transactionalSaver.liveTest.TransactionalSaverTe
st.testProgramRollback(TransactionalSaverTest.java:69)
at java.lang.reflect.Method.invoke(Native Method)
at junit.framework.TestCase.runTest(TestCase.java:166)
at junit.framework.TestCase.runBare(TestCase.java:140)
at junit.framework.TestResult$1.protect(TestResult.java:106)
at junit.framework.TestResult.runProtected(TestResult.java:124)
at junit.framework.TestResult.run(TestResult.java:109)
at junit.framework.TestCase.run(TestCase.java:131)
at junit.framework.TestSuite.runTest(TestSuite.java:173)
at junit.framework.TestSuite.run(TestSuite.java:168)
at
org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.run(JUnitTestRu
nner.java:231)
at
org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.main(JUnitTestR
unner.java:409)

Nested exception is:
java.lang.InternalError: TX was null
at com.evermind.server.ejb.EntityEJBObject.endTransaction(Unknown
Source)
at
com.evermind.server.ApplicationServerTransactionSynchronization._vib(Unknown
Source)
at com.evermind.server.ApplicationServerTransaction._vib(Unknown
Source)
at
com.evermind.server.ApplicationServerTransactionSynchronization.afterComplet
ion(Unknown Source)
at com.evermind.server.ApplicationServerTransaction._end(Unknown
Source)
at com.evermind.server.ApplicationServerTransaction.end(Unknown
Source)
at
TransactionalSaver_StatelessSessionBeanWrapper176.saveProgramAndCaseStudy(Tr
ansactionalSaver_StatelessSessionBeanWrapper176.java:100)
at java.lang.reflect.Method.invoke(Native Method)
at com.evermind._dh._gc(Unknown Source)
at com.evermind._if.run(Unknown Source)
at connection to localhost/127.0.0.1
at com.evermind.server.rmi.OrionRemoteException._os(Unknown Source)
at com.evermind._cd._mx(Unknown Source)
at com.evermind._cd.run(Unknown Source)
at java.lang.Thread.run(Thread.java:484)

I'm basically unable to diagnose why this error would occur.  Does anyone
have any suggestions?

- Geoffrey
__
Geoffrey Wiseman: Internet Applications Manager
Medium One : 

RE: Job Scheduler pattern

2002-01-28 Thread Geoff Soutter

Hmm, want us to write it for you? 

But seriously, there are commercial apps for J2EE scheduling if that's
the kind of thing you are after, just use google...

Geoff

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]] On Behalf Of Justin
Crosbie
Sent: Saturday, January 26, 2002 2:49 AM
To: Orion-Interest
Subject: RE: Job Scheduler pattern


Yes I have seen that, it is very bare-bones. It doesn't even use the
Timer classes. I need to know how to make this robust.

Thanks,
Justin

-Original Message-
From: Joseph B. Ottinger [mailto:[EMAIL PROTECTED]]
Sent: 25 January 2002 12:04
To: Orion-Interest
Subject: Re: Job Scheduler pattern


The www.orionsupport.com site has a sample scheduler that can easily be
converted to do something like this.

On Fri, 25 Jan 2002, Justin Crosbie wrote:

 Hi,
 
 I'm not sure if I've asked this before, or if I should be asking on a 
 general EJB list.
 
 I'd like to implement a job scheduler in J2EE. This would shcedule the

 execution of EJB methods at a specified time in the future. It would 
 have
to
 be persistent, and jobsd would be rescheduled upon appserver restart.
 
 Is it as simple as using the Timer and TimerTask in java.util to 
 implement an app that is started with the client-module tag?
 
 Does it matter as far as Orion goes whether I use a java.util.Timer as

 a daemon or not?
 
 What can I do if the app, or the Timer object dies at any stage?
 
 I've had problems where after some time something goes wrong I get a
strange
 Remote Exception, and the only solution is to restart the VM. What 
 might cause this?
 
 Any opinions on this? How do I make this solution robust is what I am 
 asking.
 
 Thanks for any help,
 Justin
 

---
Joseph B. Ottinger   [EMAIL PROTECTED]
http://adjacency.org/ IT Consultant






RE: Integrating LOG4J into Orion...

2002-01-21 Thread Geoff Soutter

It probably depends on how you have it configured. The main thing to
remember is that J2EE uses multiple classloaders and each classloader
can potentially have it's own version of a singleton.

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED]] On Behalf Of 
 Justin Crosbie
 Sent: Monday, 21 January, 2002 8:13 PM
 To: Orion-Interest
 Subject: RE: Integrating LOG4J into Orion...
 
 
 Hi,
 
 We have wrapped Log4J in a singleton, so the first call to it 
 initialises it. I'm not sure if this is a good idea or not 
 though, but we've had no problems so far. Any opinions?
 
 -Justin 
 
 -Original Message-
 From: Romen Law [mailto:[EMAIL PROTECTED]]
 Sent: 20 January 2002 23:05
 To: Orion-Interest
 Subject: Re: Integrating LOG4J into Orion...
 
 
 ello,
 
 What I did was to have a initialising SLSB and let the 
 startup servlet call it. It works for me.
 
 cheers
 romen
 
 - Original Message -
 From: Alex Paransky [EMAIL PROTECTED]
 To: Orion-Interest [EMAIL PROTECTED]
 Sent: Saturday, January 19, 2002 12:34 PM
 Subject: FW: Integrating LOG4J into Orion...
 
 
  One more time, the last one did not show up
 
  -Original Message-
  From: Alex Paransky [mailto:[EMAIL PROTECTED]]
  Sent: Thursday, January 17, 2002 11:09 AM
  To: Orion-Interest
  Subject: Integrating LOG4J into Orion...
 
 
  I have a full EJB/JSP application running with Orion.  Is there a
 preferred
  method of initializing LOG4J in this situation?
 
  Looking at the LOG4J documentation, they mention using a startup 
  servlet
 to
  do the initialization.  I am concerned as to how this would 
 work with 
  the CLASSLOADER hierarchy.  If I initialize my LOG4J at the servlet 
  (WEB)
 layer,
  will the EJB's be able to see the initialized LOG4J or will they 
  attempt
 to
  re-initialize due to the different classloader?
 
  Thanks.
  -AP_
 
 
 
 
 





RE: stateful bean error

2002-01-20 Thread Geoff Soutter

By definition, if the jvm crashes, it's a JVM bug (Unless you have
loaded classes which use native code (like the Oracle OCI jdbc drivers).

I'd suggest you try the latest Sun JVM with and without hotspot, and if
that fails have a go with the IBM JVM.

Cheers

Geoff

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED]] On Behalf Of SeaWolf
 Sent: Monday, 21 January, 2002 10:47 AM
 To: Orion-Interest
 Subject: stateful bean error
 
 
 Hi...
 
 can anybody explain it to me, what is this all about..
 
 atjava.io.DataOutputStream.writeUTF
 DataOutputStream.java(CompiledCode))
 at
 java.io.ObjectOutputStream.writeUTF(ObjectOutputStream.java:1529)
 at 
 com.evermind.server.ejb.StatefulSessionObjectInfo.writeExterna
 l(StatefulSession
 ObjectInfo.java:31)
 at 
 java.io.ObjectOutputStream.outputObject(ObjectOutputStream.jav
 a(Compiled
 Code))
 at 
 java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java
 (Compiled
 Code))
 at 
 com.evermind.server.rmi.RMIOutputStream.writeType(RMIOutputStr
 eam.java(Compiled
 Code))
 at 
 com.evermind.server.rmi.RMICallHandler.run(RMICallHandler.java
 (Compiled
 Code))
 at 
 com.evermind.util.ThreadPoolThread.run(ThreadPoolThread.java(Compiled
 Code))
 
 My application server crash(segmentation violation)
 when i invoke the stateful session bean.
 
 seawolf
 
 __
 Do You Yahoo!?
 Send FREE video emails in Yahoo! Mail! 
 http://promo.yahoo.com/videomail/
 





RE: IronFlare bug fixing policy

2002-01-17 Thread Geoff Soutter

Doh! Sorry. Well at least I figured out what happens when one reports a
bug...

Thanks to all who helped...

Any ideas when the new release might be available?

Geoff

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED]] On Behalf Of 
 Magnus Rydin
 Sent: Wednesday, 16 January, 2002 8:26 PM
 To: Orion-Interest
 Subject: SV: IronFlare bug fixing policy
 
 
 Hi Geoff,
 
 your bug report 695 seems to be a copy of bug 670 which has 
 already been fixed (not released though).
 
 WR
 Magnus Rydin
 
  -Ursprungligt meddelande-
  Från: [EMAIL PROTECTED]
  [mailto:[EMAIL PROTECTED]]För Geoff Soutter
  Skickat: den 16 januari 2002 07:06
  Till: Orion-Interest
  Kopia: Orion Interest List
  Ämne: RE: IronFlare bug fixing policy
 
 
  Hi there EW,
 
  Thanks for the response.
 
  The one I've reported (so far) is 695 
  (http://bugzilla.orionserver.com/bugzilla/show_bug.cgi?id=695).
 
  It doesn't include an .ear file or anything, but it seems to be it 
  would be pretty trivial to track it down _if you had access to the 
  source code_ - since I included the buggy portion of the generated 
  wrapper it's clear to see where the bug is.
 
  In fact, I just did a search on the class files and I found 
 the likely 
  location of the bug. It's probably in _ql.class, since it's 
 the only 
  class which contains response.iterator() and it's this 
 line which is 
  throwing the NullPointerException. Grrr - closed source 
 things annoy 
  me!!
 
  So, seems like you're saying theres not much propect of bugs being 
  fixed till the refactoring is over? Did they mention when this is 
  likely to be? RSN I suppose :-)
 
  Cheers,
 
  Geoff
 
  BTW, seems like bugzilla is down at the moment?
 
   -Original Message-
   From: The elephantwalker [mailto:[EMAIL PROTECTED]]
   Sent: Wednesday, 16 January, 2002 4:03 PM
   To: Orion-Interest; [EMAIL PROTECTED]
   Subject: RE: IronFlare bug fixing policy
  
  
   Geoff,
  
   Magnus Rydin told me that what they need are good 
 examples for each 
   bug so that they are absolutely reproducible. If you look 
 at some of 
   the bugs that are still open, these bugs don't have iron clad 
   examples that are reproducible.
  
   So each of these bugs needs to be cleared...which means Magnus R. 
   has to work on reproducing them (if they aren't immediately 
   reproducible), which of course takes time.
  
   What he didn't say but reported on the list is a major 
 refactoring 
   going on now in Orion to bring it into compliance with j2ee 1.3. 
   This includes EJB 2.0, Servlet 2.3 (not just the draft), and JSP 
   1.2, Connections, etc.
  
   As we all know, fixing bugs which are going to disappear in a 
   refactoring is a bit of a waste of time. Of course, if its a bug 
   that affects you directly, you may feel differently.
  
   Which bug numbers did you report?
  
   regards,
  
   the elephantwalker
   www.elephantwalker.com
  
  
   -Original Message-
   From: [EMAIL PROTECTED]
   [mailto:[EMAIL PROTECTED]]On Behalf Of Geoff 
   Soutter
   Sent: Tuesday, January 15, 2002 4:55 PM
   To: Orion-Interest
   Subject: IronFlare bug fixing policy
  
  
   Hi there,
  
   I reported a bug on BugZilla a few days back. It's reasonably 
   serious - basically the generated wrapper for the finder 
 method of 
   an EJB is throwing NullPointerException when the EJB throws an 
   exception, hiding the real cause of the problem. (And I 
 just found 
   another bug - ServletExceptions constructed with (string, 
 exception) 
   are reported without the String originally passed.)
  
   I haven't heard anything and the bug has not been touched 
   apparently.
  
   Does anyone know what IronFlare's policy is regards 
 fixing bugs? Do 
   they tend to fix them quickly, or are they likely to just 
 ignore bug 
   reports?
  
  
   The reason I ask is that I'm happy to use something without much 
   support, but if they refuse to fix bugs then I think I'll have to 
   give up and try elsewhere...
  
   Cheers
  
   Geoff
  
  
 
 
 





RE: IronFlare bug fixing policy

2002-01-16 Thread Geoff Soutter

Hi there EW,

Thanks for the response.

The one I've reported (so far) is 695
(http://bugzilla.orionserver.com/bugzilla/show_bug.cgi?id=695).

It doesn't include an .ear file or anything, but it seems to be it would
be pretty trivial to track it down _if you had access to the source
code_ - since I included the buggy portion of the generated wrapper it's
clear to see where the bug is. 

In fact, I just did a search on the class files and I found the likely
location of the bug. It's probably in _ql.class, since it's the only
class which contains response.iterator() and it's this line which is
throwing the NullPointerException. Grrr - closed source things annoy
me!!

So, seems like you're saying theres not much propect of bugs being fixed
till the refactoring is over? Did they mention when this is likely to
be? RSN I suppose :-)

Cheers,

Geoff

BTW, seems like bugzilla is down at the moment?

 -Original Message-
 From: The elephantwalker [mailto:[EMAIL PROTECTED]] 
 Sent: Wednesday, 16 January, 2002 4:03 PM
 To: Orion-Interest; [EMAIL PROTECTED]
 Subject: RE: IronFlare bug fixing policy
 
 
 Geoff,
 
 Magnus Rydin told me that what they need are good examples 
 for each bug so that they are absolutely reproducible. If you 
 look at some of the bugs that are still open, these bugs 
 don't have iron clad examples that are reproducible.
 
 So each of these bugs needs to be cleared...which means 
 Magnus R. has to work on reproducing them (if they aren't 
 immediately reproducible), which of course takes time.
 
 What he didn't say but reported on the list is a major 
 refactoring going on now in Orion to bring it into compliance 
 with j2ee 1.3. This includes EJB 2.0, Servlet 2.3 (not just 
 the draft), and JSP 1.2, Connections, etc.
 
 As we all know, fixing bugs which are going to disappear in a 
 refactoring is a bit of a waste of time. Of course, if its a 
 bug that affects you directly, you may feel differently.
 
 Which bug numbers did you report?
 
 regards,
 
 the elephantwalker
 www.elephantwalker.com
 
 
 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]]On Behalf Of 
 Geoff Soutter
 Sent: Tuesday, January 15, 2002 4:55 PM
 To: Orion-Interest
 Subject: IronFlare bug fixing policy
 
 
 Hi there,
 
 I reported a bug on BugZilla a few days back. It's reasonably 
 serious - basically the generated wrapper for the finder 
 method of an EJB is throwing NullPointerException when the 
 EJB throws an exception, hiding the real cause of the 
 problem. (And I just found another bug - ServletExceptions 
 constructed with (string, exception) are reported without the 
 String originally passed.)
 
 I haven't heard anything and the bug has not been touched apparently.
 
 Does anyone know what IronFlare's policy is regards fixing 
 bugs? Do they tend to fix them quickly, or are they likely to 
 just ignore bug reports?
 
 
 The reason I ask is that I'm happy to use something without 
 much support, but if they refuse to fix bugs then I think 
 I'll have to give up and try elsewhere...
 
 Cheers
 
 Geoff
 
 





RE: Simple question re caching/pooling of BMP Entity Beans

2002-01-10 Thread Geoff Soutter

Hi Sergey,

Thanks for the reply. I didn't explain it very clearly did I? What I
meant was:

However, it appears that it goes to the database (i.e. calls _ejbLoad_
in the Entity Bean's implementation) for every call to findByPrimaryKey,
regardless of whether it has previously read the instance with the
specified key before.

Have you been able to get pooling of BMP entity beans working?

Geoff

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED]] On Behalf Of 
 Sergey G. Aslanov
 Sent: Thursday, 10 January, 2002 6:29 PM
 To: Orion-Interest
 Subject: Re: Simple question re caching/pooling of BMP Entity Beans
 
 
 Hi Geoff
 
 Loading of beans have these stages:
 1. calling ejbFindBy... to get the primKeys of the entities;
 2. checking if entities with such keys are already pooled;
 3. for every key checking: if not pooled - call ejbLoad, else 
 - get instance from pool;
 
 As you see, ejbFindBy... are called always independently of 
 entity is pooled or not.
 
 Thursday, January 10, 2002, 2:01:37 AM, you wrote:
 
 GS Hi there,
 
 GS I'm teaching myself how to use Orion and I've got a 
 simple question 
 GS about caching/pooling of BMP Entity Bean instances.
 
 GS I've created a simple app which lets me read a BMP Entity Bean 
 GS through a Session Bean. I would expect that when I call 
 GS findByPrimaryKey on my Entity Bean's home interface, Orion caches 
 GS the instance it creates so that next time I call findByPrimaryKey 
 GS for the same key, it just returns the instance it already 
 has rather 
 GS than creating a new one. However, it appears that it goes to the 
 GS database (i.e. calls ejbFindByPrimaryKey in the Entity Bean's 
 GS implementation) for every call to findByPrimaryKey, regardless of 
 GS whether it has previously read the instance with the 
 specified key 
 GS before.
 
 GS I checked the list archive and it appears that someone 
 has reported 
 GS a similar problem a while back but there were no replies 
 GS 
 (http://www.mail-archive.com/orion-interest@orionserver.com/ms
g17359
GS .htm
GS l).

GS I also checked the documentation and for orion-ejb-jar.xml it states

GS that exclusive-write-access is true by default, and since I am not 
GS setting it I presume it's defaulting to true which should allow 
GS Orion to cache the entity beans.

GS So, can anyone shed any light on how whether/how I can get Orion to 
GS cache BMP entity beans?

GS Cheers

GS Geoff


--
Sergey G. Aslanov,
CBOSS Group,
Web-technologies department
mailto:[EMAIL PROTECTED]
tel: +7 095 7555655






RE: Simple question re caching/pooling of BMP Entity Beans

2002-01-10 Thread Geoff Soutter

Hmm. Seems I am really getting myself confused. :-). I think I've got it
now... I'm mistaking the db call in ejbFindByPrimaryKey with the db call
in ejbLoad. Doh.

So, the first time I call findByPrimaryKey, Orion calls
ejbFindByPrimaryKey which goes to the database basically only to confirm
the row hasn't been deleted. Then Orion calls ejbLoad which goes the the
database again to load in the actual contents of the row. So, the row in
question is accessed twice. 

Then, the second time, Orion still calls findByPrimaryKey, but avoids
the ejbLoad. 

The thing is here, exclusive-write-access is set to true (by default),
so why is Orion bothering to call findByPrimaryKey? Can't it just keep
an internal primary key - ejb map and return the ejb instance directly?
After all, if exclusive-write-access is on, the row can only be deleted
by Orion itself...

Geoff


 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED]] On Behalf Of 
 Geoff Soutter
 Sent: Friday, 11 January, 2002 9:09 AM
 To: Orion-Interest
 Subject: RE: Simple question re caching/pooling of BMP Entity Beans
 
 
 Hi Sergey,
 
 Thanks for the reply. I didn't explain it very clearly did I? 
 What I meant was:
 
 However, it appears that it goes to the database (i.e. calls 
 _ejbLoad_ in the Entity Bean's implementation) for every call 
 to findByPrimaryKey, regardless of whether it has previously 
 read the instance with the specified key before.
 
 Have you been able to get pooling of BMP entity beans working?
 
 Geoff
 
  -Original Message-
  From: [EMAIL PROTECTED]
  [mailto:[EMAIL PROTECTED]] On Behalf Of 
  Sergey G. Aslanov
  Sent: Thursday, 10 January, 2002 6:29 PM
  To: Orion-Interest
  Subject: Re: Simple question re caching/pooling of BMP Entity Beans
  
  
  Hi Geoff
  
  Loading of beans have these stages:
  1. calling ejbFindBy... to get the primKeys of the entities; 2. 
  checking if entities with such keys are already pooled; 3. 
 for every 
  key checking: if not pooled - call ejbLoad, else
  - get instance from pool;
  
  As you see, ejbFindBy... are called always independently of
  entity is pooled or not.
  
  Thursday, January 10, 2002, 2:01:37 AM, you wrote:
  
  GS Hi there,
  
  GS I'm teaching myself how to use Orion and I've got a
  simple question
  GS about caching/pooling of BMP Entity Bean instances.
  
  GS I've created a simple app which lets me read a BMP Entity Bean
  GS through a Session Bean. I would expect that when I call 
  GS findByPrimaryKey on my Entity Bean's home interface, 
 Orion caches 
  GS the instance it creates so that next time I call 
 findByPrimaryKey 
  GS for the same key, it just returns the instance it already 
  has rather
  GS than creating a new one. However, it appears that it goes to the
  GS database (i.e. calls ejbFindByPrimaryKey in the Entity Bean's 
  GS implementation) for every call to findByPrimaryKey, 
 regardless of 
  GS whether it has previously read the instance with the 
  specified key
  GS before.
  
  GS I checked the list archive and it appears that someone
  has reported
  GS a similar problem a while back but there were no replies
  GS 
  (http://www.mail-archive.com/orion-interest@orionserver.com/ms
 g17359
 GS .htm
 GS l).
 
 GS I also checked the documentation and for 
 orion-ejb-jar.xml it states
 
 GS that exclusive-write-access is true by default, and since I am not
 GS setting it I presume it's defaulting to true which should allow 
 GS Orion to cache the entity beans.
 
 GS So, can anyone shed any light on how whether/how I can 
 get Orion to
 GS cache BMP entity beans?
 
 GS Cheers
 
 GS Geoff
 
 
 --
 Sergey G. Aslanov,
 CBOSS Group,
 Web-technologies department
 mailto:[EMAIL PROTECTED]
 tel: +7 095 7555655
 
 
 





Anyone got old orionsupport sample application client / scheduler?

2002-01-10 Thread Geoff Soutter

You can see it described in googles cache

http://www.google.com/search?q=cache:4nkQslt9AjsC:www.orionsupport.com/a
rticles/appclient.html+orion+application+clienthl=en

If anyone has the source jar file, I'd really appreciate a copy!

Cheers

Geoff





Simple question re caching/pooling of BMP Entity Beans

2002-01-09 Thread Geoff Soutter

Hi there,

I'm teaching myself how to use Orion and I've got a simple question
about caching/pooling of BMP Entity Bean instances.

I've created a simple app which lets me read a BMP Entity Bean through a
Session Bean. I would expect that when I call findByPrimaryKey on my
Entity Bean's home interface, Orion caches the instance it creates so
that next time I call findByPrimaryKey for the same key, it just returns
the instance it already has rather than creating a new one. However, it
appears that it goes to the database (i.e. calls ejbFindByPrimaryKey in
the Entity Bean's implementation) for every call to findByPrimaryKey,
regardless of whether it has previously read the instance with the
specified key before. 

I checked the list archive and it appears that someone has reported a
similar problem a while back but there were no replies
(http://www.mail-archive.com/orion-interest@orionserver.com/msg17359.htm
l). 

I also checked the documentation and for orion-ejb-jar.xml it states
that exclusive-write-access is true by default, and since I am not
setting it I presume it's defaulting to true which should allow Orion to
cache the entity beans.

So, can anyone shed any light on how whether/how I can get Orion to
cache BMP entity beans?

Cheers

Geoff







RE: Very Long Deployment Time

2001-12-18 Thread geoff



Like 
others on this list, I don't share your problem. I redeploy the entire EAR 
using Ant, and the redeploy process for our project takes less than ten 
seconds. Your project might be larger than mine, at this point, but not so 
much that it should cause the kind of delay you're finding.

I 
don't know much about JDeveloper, but once your project is compiled, you should 
be able to place it in the applications directory and have Orion deploy it 
rapidly, without restarting Orion, assuming Orion's configured 
appropriately.

 - Geoffrey

  -Original Message-From: Gustavo Comba 
  [mailto:[EMAIL PROTECTED]]Sent: Monday, December 17, 2001 
  11:34 AMTo: Orion-InterestSubject: Very Long Deployment 
  Time
  Hello,
  
   I'm deployinga little 
  project with a Client Application Module and a EJB Module with several EJB 
  (about 30 Entity and 5 Session Beans). I'm using JDeveloper 9i Release 
  Cantidate to develop/deploy my project.
  
   My project compiles very fast, 
  but when I do the deployment, it take a very long time (about 10 minutes). I'm 
  debugging now, and I'm deploying continously, and it's very 
  anoying!
  
   There is something I can do to 
  accelerate the deployment proccess? Can I copy the .ear file directly into the 
  "applications" directory and start the server again? Help me 
  please!
  
   Thanks in 
advance,
  

   Gustavo 
  Comba_This 
  message has been checked for all known viruses by the MessageLabs Virus 
  Scanning Service. For further information visithttp://www.messagelabs.com/stats.asp


_
This message has been checked for all known viruses by the 
MessageLabs Virus Scanning Service. For further information visit

http://www.messagelabs.com/stats.asp




RE: Persistance between HTTP and HTTPS

2001-12-06 Thread geoff



Don't 
know if it's related, but we've found that while we're using HTTPS on Orion, the 
sesions would, seemingly at random, sometimes vanish on us. Reasons 
unknown, and we haven't tracked it down yet.

 - Geoffrey

  -Original Message-From: Steve Best 
  [mailto:[EMAIL PROTECTED]]Sent: Wednesday, December 05, 2001 
  8:07 PMTo: Orion-InterestSubject: Persistance between 
  HTTP and HTTPS
  Greetings, we are currently experiencing what 
  appears to be a lack of persistance between HTTP and HTTPS, when moving 
  between the two on our site, and only in-frequently. Has anyone ever 
  experienced this problem before?
  
  Thanks,Steve BestSystems 
  AdministratorSimple Devices415-637-9651 (cell)
  
  "A little nonsense now and then, is relished by 
  the wisest 
  men." 
  Willy 
  Wonka_This 
  message has been checked for all known viruses by the MessageLabs Virus 
  Scanning Service. For further information visithttp://www.messagelabs.com/stats.asp


_
This message has been checked for all known viruses by the 
MessageLabs Virus Scanning Service. For further information visit

http://www.messagelabs.com/stats.asp




RE: Client application connection.

2001-12-05 Thread geoff



I had 
a number of troubles getting this set up, but unfortunately I don't remember 
what mose of them were. I'm assuming your admin has rmi:login enabled, and 
disabled="false"?

 - Geoffrey

  -Original Message-From: JoseMa 
  [mailto:[EMAIL PROTECTED]]Sent: Tuesday, December 04, 2001 9:35 
  AMTo: Orion-InterestSubject: Client application 
  connection.
  
  
  Hi,
  
   We have created a client application which connect to 
  EJB in Orion Server. For connecting I have a jndi.properties file with the 
  next parametres:
  
   
  java.naming.factory.initial=com.evermind.server.ApplicationClientInitialContextFactory 
  java.naming.provider.url=ormi://server/application 
  java.naming.security.principal=admin 
  java.naming.security.credentials=123
  
  
  BothHOME_ORION/application-deployments/application/principals.xml 
  andHOME_ORION/config/principals.xml 
  have defined the user admin.
  
  
   When I executed the client 
  application I look the next exception:
  

  Message:Invalid username/password foraplicacion 
  (admin)
  
  
   Could help me anybody?
  
   Thanks.
  _This 
  message has been checked for all known viruses by the MessageLabs Virus 
  Scanning Service. For further information visithttp://www.messagelabs.com/stats.asp


_
This message has been checked for all known viruses by the 
MessageLabs Virus Scanning Service. For further information visit

http://www.messagelabs.com/stats.asp




RE: Debugging JSP

2001-11-28 Thread geoff

Wow, some of those debugging pages have a lot more information on debugging
under Orion than I previously thought was available.  Nice to know.

When I tried this about six months ago, it seemed to work under javac, but
not jikes.  Anyone know if that's still the case, or if it was just a fluke
on my part?  I haven't had to debug a JSP under Orion recently, so I haven't
tested this out.

Also, under Tomcat and JRun, there are ways to precompile JSPs--a quick
search in the KB didn't bring up anything obvious.  Is there a way to
accomplish this under Orion?  I don't need to be able to use these
precompiled JSPs anywhere, I just like to be able to make JSP compilation a
part of the build process so that I don't have to build over and over to fix
bugs in JSPs when I have to do extensive JSP modifications.

- Geoffrey

: -Original Message-
: From: Scott Farquhar [mailto:[EMAIL PROTECTED]]
: Sent: Wednesday, November 28, 2001 3:25 AM
: To: Orion-Interest
: Subject: Re: Debugging JSP
: 
: 
: Herman,
: 
: A quick search on the knowledge base reveals a few pages that 
: may be of 
: interest:
:http://kb.atlassian.com/search.jsp?query=debugging
: 
: One in particular is:
:http://kb.atlassian.com/content/orion/docs/debugging.html
: 
: which has links to:
:http://kb.atlassian.com/content/orion/docs/development-mode.html
: 
: What you need to do is change global-web-application.xml to 
: include the 
: tag parameter development=true.  It is fully described in 
: the link above.
: 
: Cheers,
: Scott
: 
: -- 
: Scott Farquhar :: [EMAIL PROTECTED]
: 
: Atlassian :: http://www.atlassian.com
:   Supporting YOUR J2EE World
: 
: 
: 
: 
: Herman Rashid wrote:
: 
:  Hi all,
:  
:  How do you debug jsp using Orion ?
:  
:  I have managed to get debugging going for
:  servlets/ejb, but not JSP since I don't know the
:  internal of Orion's JSP..
:  
:  All help appreciated.
:  
:  __
:  Do You Yahoo!?
:  Yahoo! GeoCities - quick and easy web site hosting, just 
: $8.95/month.
:  http://geocities.yahoo.com/ps/info1
:  
:  
:  
: 
: 
: 
: 
: _
: This message has been checked for all known viruses by the 
: MessageLabs Virus Scanning Service. For further information visit
: http://www.messagelabs.com/stats.asp
: 




FW: [JBoss-user] Redux of Performance Issues

2001-11-27 Thread geoff

Wow.  I know people have complained about this list being a little slow, but
if this is what I get from the lead developer of JBoss on how to fix up
JBoss performance to compare to Orion's, then ... well ... perhaps I should
be spending more time on this list.  I'm a little disappointed.  I have some
interest in both JBoss and Orion, and it's frustrating to get this kind of a
response from a key player in the JBoss community.

- Geoffrey

: -Original Message-
: From: marc fleury [mailto:[EMAIL PROTECTED]]
: Sent: Tuesday, November 27, 2001 2:34 PM
: To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
: Subject: RE: [JBoss-user] Redux of Performance Issues
: 
: 
: look dude,
: 
: get the integrated jboss-tomcat stack you are running 
: non-optimized out of
: stack, period.
: 
: come back when you have set it up, or don't we don't care,
: 
: marcf
: 
: |-Original Message-
: |From: [EMAIL PROTECTED]
: |[mailto:[EMAIL PROTECTED]]On Behalf Of
: |[EMAIL PROTECTED]
: |Sent: Tuesday, November 27, 2001 2:09 PM
: |To: [EMAIL PROTECTED]
: |Subject: [JBoss-user] Redux of Performance Issues
: |
: |
: |For reasons unknown, this message hasn't been going out to the
: |list.  Trying
: |again.
: |
: |--
: |
: |Okay, I've clearly managed to piss off a few people by my 
: concerns about
: |JBoss performance.
: |
: |Let me start out by saying that I'd be more than happy to get my
: |application
: |working speedily under JBoss.  Orion's documentation is poor 
: at best, and
: |JBoss is fully open-source.  I have a great deal of respect 
: for some of
: |JBoss's technology (the verifier and deployer are probably 
: the best I've
: |seen), and where it's coming from.  I chose JBoss for the initial
: |development because of its reputation and my own interests.
: |
: |That said, if the performance I'm getting out of JBoss is 
: the best I can
: |expect, or, at least, the best I can manage to get, then I
: |absolutely cannot
: |use it.  Not because I think it 'sucks rocks', because it 
: doesn't, but
: |simply because it will not support the user load I need it to in
: |any sort of
: |cost-effective manner.  Some of you would probably be just 
: as happy to see
: |me go somewhere else, from the tone of your emails, but I'd 
: personally
: |rather find a way to get the performance out of JBoss, for 
: this or other
: |projects.
: |
: |And, ultimately, it seems as if the performance I'm asking for is
: |relatively
: |reasonable.  I expect a certain amount of overhead in EJB 
: performance, and
: |I'm not asking to duplicate the speed of a bean-only 
: implementation.  But
: |supporting a maximum of 25 concurrent users on a decent (if 
: not maxed-out)
: |server seems ... suspiciously slow.
: |
: |It may be that I've missed some settings to speed things up.  It
: |may be that
: |our application's architecture is better suited to Orion 
: than to JBoss.
: |Whatever it is, I'd like to find out.  So I've joined the 
: JBoss list, and
: |I'm here to ask some questions.  I'm not trying to promote 
: Orion, or insult
: |JBoss.  I like bits of both of them, and the reasons for 
: that, I can get
: |into another day.  Ultimately, however, I'd rather support 
: JBoss as an
: |open-source appserver, if I can.
: |
: |--
: |
: |Now, on to the details.  Some of you pointed out, and 
: rightly so, that I
: |hadn't provided much in the way of details of what I've 
: tried, which is
: |true.  I wanted to start off by finding out if the kind of 
: numbers I was
: |talking about seemed realistic or not, based on the 
: experience of people
: |who'd spent more time with JBoss than I have, but it's 
: probably fair to say
: |that you couldn't really say without knowing a lot more about my
: |application.  So let's get into a few details.
: |
: |Let's start with versions.  I did some of my original EJB
: |experimentation on
: |JBoss-2.4.1.  We started developing a project on 
: JBoss-2.4.1a w/ Embedded
: |Tomcat, which was the latest JBoss/Tomcat grouping at the 
: time.  We started
: |noticing performance concerns then.  When Tomcat 4 came out, 
: we moved to
: |JBoss-2.4.3 w/ Embedded Catalina, so that we could try a few 
: things, and
: |found it not to be slower, so we stayed with it.
: |
: |After we reached a point where we needed to see better 
: performance, we did
: |some optimizing of our app with a profiler, and tried JBoss 
: 2.4.3 w/ Resin,
: |which we already knew to be fast.  That gave us a minor speed
: |boost, but not
: |very much, leading me to believe that JBoss might be the 
: cause of some of
: |our performance.  By comparison, Orion 1.5.2 seems to be 
: very much faster.
: |
: |All of this is running on Windows 2000.  The versions of 
: Tomcat are 3.2.3
: |and 4.0, as far as I know.  The version of Resin is the latest
: |version as of
: |a few weeks ago, I'd have to go check.  If it's important, I will.
: |
: |Processor speed depended, but developers are working, largely, on
: |PIII-700MHzs, and we did most of our 

RE: orion-ejb-jar and other such descriptors

2001-11-22 Thread geoff

Hrm.  That's unfortunate.  Our Ant build script largely works unmodified on
a number of different application servers thus far, but now I'll have to
have an orion-specific extra clean step, since removing the EAR does not, in
and of itself, clear out the rest of the application as it does elsewhere.

Thanks,

- Geoffrey

: -Original Message-
: From: Mike Cannon-Brookes [mailto:[EMAIL PROTECTED]]
: Sent: Wednesday, November 21, 2001 6:00 PM
: To: Orion-Interest
: Subject: Re: orion-ejb-jar and other such descriptors
: 
: 
: Geoffrey,
: 
: This is the expected behaviour. The deployment descriptors are only
: copied from the EAR after a clean deploy. Otherwise Orion might
: overwrite deployment descriptors that you had edited.
: 
: Cheers,
: Mike
: 
: -- 
: Mike Cannon-Brookes :: [EMAIL PROTECTED]
: 
: Atlassian :: http://www.atlassian.com
:  Supporting YOUR J2EE World
: 
: 
: On Thu, 2001-11-22 at 07:03, [EMAIL PROTECTED] wrote:
:  I've put an orion-ejb-jar.xml in the EJB Jar's META-INF.  
: If I clean out the
:  Orion/application-deployment and Orion/applications versions of the
:  application, and deploy to Orion, the file copies into the 
: appropriate place
:  and takes effect.  If I deploy on top of an existing EAR, 
: the redeploy
:  process doesn't seem to replace the existing 
: orion-ejb-jar.xml file.  I
:  suspect this is probably happening with other descriptors, 
: but this is the
:  one that I just tested thoroughly recently, to ensure that I wasn't
:  imagining that.
:  
:  Is there any way to ensure that the file does get deployed 
: along with the
:  rest of the EAR?  Am I missing something?
:  
:  - Geoffrey
:  __
:  Geoffrey Wiseman: Internet Applications Manager
:  Medium One
:  t. 416.977.2101 x. 529
:  http://www.mediumone.com/
:  __
:  Think it.  Build it.  Work it.
:  
:  
:  
: 
: 
: 




Deployment Exception

2001-11-21 Thread geoff

I'm having issues with my EAR deployment all of a sudden -- when Orion
attempts to unpack and deploy the EAR, it throws an exception:

Auto-deploying thesquare-ejb.jar (ejb-jar.xml had been touched since the
previou
s deployment)... java.lang.IllegalArgumentException: Cannot convert from
class j
ava.lang.Object to class java.lang.String
at com.evermind._bz._ldb(Unknown Source)
at com.evermind._ql._lvb(Unknown Source)
at com.evermind._qk._lvb(Unknown Source)
at com.evermind._ao._bb(Unknown Source)
at com.evermind._pw._bb(Unknown Source)
at com.evermind._px._bb(Unknown Source)
at com.evermind._au._bb(Unknown Source)
at com.evermind._dq._qzb(Unknown Source)
at com.evermind._ck._qzb(Unknown Source)
at com.evermind._ck._at(Unknown Source)
at com.evermind.server.ApplicationServer._as(Unknown Source)
at com.evermind.server.ApplicationServer._wl(Unknown Source)
at com.evermind.server.ApplicationServer._at(Unknown Source)
at com.evermind._in.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
at com.evermind._if.run(Unknown Source)

With no way to diagnose this, I'm largely stuck.  Suggestions?

- Geoffrey Wiseman

__
Geoffrey Wiseman: Internet Applications Manager
Medium One
t. 416.977.2101 x. 529
http://www.mediumone.com/
__
Think it.  Build it.  Work it.






orion-ejb-jar and other such descriptors

2001-11-21 Thread geoff

I've put an orion-ejb-jar.xml in the EJB Jar's META-INF.  If I clean out the
Orion/application-deployment and Orion/applications versions of the
application, and deploy to Orion, the file copies into the appropriate place
and takes effect.  If I deploy on top of an existing EAR, the redeploy
process doesn't seem to replace the existing orion-ejb-jar.xml file.  I
suspect this is probably happening with other descriptors, but this is the
one that I just tested thoroughly recently, to ensure that I wasn't
imagining that.

Is there any way to ensure that the file does get deployed along with the
rest of the EAR?  Am I missing something?

- Geoffrey
__
Geoffrey Wiseman: Internet Applications Manager
Medium One
t. 416.977.2101 x. 529
http://www.mediumone.com/
__
Think it.  Build it.  Work it.






Troubles with https....

2001-07-10 Thread Geoff Marshall

Can anyone explain the principles or theory of operation of https within
Orion?

I have a site running on one machine under Orion that uses https.  No
problem, everything works fine.

I tarballed the whole shebang and expanded it onto machine two. Machine two
has 4 Network Interfaces, thus 4 IP addresses.  I'm running Orion on the
second of 4 IP addresses.  The entire site works, but I can't hit it via
https.  

I don't think it's an Orion configuration issue (since the same config files
work on machine 1) , but in any event, I'm doing exactly what's described on
the orionsupport pages.

Can anyone give me some insight?  I've run out of ideas.

BTW, yes, the versions are the same on the two machines.

Thanks!





Re: orion with mysql?

2001-04-04 Thread Geoff Marshall

Am using MySQL with Orion without it's own db-schema.  No problems, yet.

Be sure to get the MM.MySQL driver...
-- 

-Geoff Marshall, Director of Development

...
t e r r a s c o p e  (415) 951-4944
54 Mint Street, Suite 110 direct (415) 625-0349
San Francisco, CA  94103 fax (415) 625-0306
...

 From: Peter Peltonen [EMAIL PROTECTED]
 Organization: Fivetec Solutions Oy
 Reply-To: Orion-Interest [EMAIL PROTECTED]
 Date: Wed, 04 Apr 2001 19:42:44 +0300
 To: Orion-Interest [EMAIL PROTECTED]
 Subject: orion with mysql?
 
 
 Is it possible to use MySQL with Orion? Does it need a db-schema of it's own?
 
 We tried to use PostgreSQL but JBuilder4 didn't cope with it very well
 (JBuilder isn't able to show Postgre's tables). We also tried Hypersonic, but
 it seems that when both Orion and JBuilder communicate with the db the db gets
 confused. At least the changes we make in JBuilder don't get updated.
 
 Any ideas about a good open-source db that would work with both Orion and
 JBuilder would be appreciated!
 
 Regards,
 Peter
 
 





communication link failure

2001-03-20 Thread Geoff Marshall

Hello all!

I've got an application-level object that grabs a pool of database
connections (MySQL using the mm.mysql JDBC driver).  All works well until
there is not activity for some extended period of time (overnight) and then
all attempts to access the database get "communication link failure" errors.

Is there any way to configure Orion or MySQL to not give up on a database
connection.  Or do I have to move the connections to some other level.

I know the app objects are surviving because I can query them, but just
can't reestablish with the db.

Anyone else have similar problems or any ideas???
-- 

-Geoff Marshall, Director of Development

...
t e r r a s c o p e  (415) 951-4944
54 Mint Street, Suite 110 direct (415) 625-0349
San Francisco, CA  94103 fax (415) 625-0306
...





https second session problems...

2001-03-06 Thread Geoff Marshall

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

Here's the problem of the day:

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

// run orion
[root@daphne orion]# Orion/1.4.5 initialized

// with browser hit my index page in http
// index page instantiates two DataAccess objects, and
// one SessionBean with session scope
DataAccess.DataAccess() - constructing...
DataAccess.DataAccess() - constructing...
SessionBean.SessionBean() - constructing...
SessionBean.getCustId() -
SessionBean.isLoggedOn() - false

// fill out log-on form on index page and log on (re-submits page as https)
DataAccess.DataAccess() - constructing...
DataAccess.DataAccess() - constructing...
SessionBean.SessionBean() - constructing...
// ...there you have it, all three session
// beans are being instantiated again!!!
// EVEN THOUGH my JSESSIONID does not change
// (looked at it in my brower)
SessionBean.getCustId() -
SessionBean.setCustId() -
SessionBean.logOn() -
// cust now logged on in https

// still there on next https page.
SessionBean.isLoggedOn() - true
SessionBean.getCustId() - 2


// switch to http page, and cust is gone.
SessionBean.isLoggedOn() - false

// back to https and cust is there again.
SessionBean.isLoggedOn() - true
SessionBean.getCustId() - 2
SessionBean.isLoggedOn() - false
SessionBean.getCustId() - 2

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

-Geoff Marshall, Director of Development

...
t e r r a s c o p e  (415) 951-4944
54 Mint Street, Suite 110 direct (415) 625-0349
San Francisco, CA  94103 fax (415) 625-0306
...





Re: Capturing the output of a JSP page as HTML

2001-03-02 Thread Geoff Marshall

No problem, write a servelt or other JSP page that does a method='post' to
the JSP in question.  You will have to read the output of the page into a
variable.  Then you can write the variable to both a file and out.println.

The only catch is you will have to have a class that can do a post! See the
attatchment...
-- 

-Geoff Marshall, Director of Development

...
t e r r a s c o p e  (415) 951-4944
54 Mint Street, Suite 110 direct (415) 625-0349
San Francisco, CA  94103 fax (415) 625-0306
...

 From: [EMAIL PROTECTED]
 Reply-To: Orion-Interest [EMAIL PROTECTED]
 Date: Thu, 1 Mar 2001 11:32:25 -0500
 To: Orion-Interest [EMAIL PROTECTED]
 Subject: Capturing the output of a JSP page as HTML
 
 Can anyone tell me if this is possible.  I have a JSP page that contains
 information about an order that was just entered (Essentially a
 confirmation page).  What I want to do is somehow intercept the output
 stream inside the JSP page and write it to a file, as plain html, which I
 will later attach to an email and send to someone.
 
 Thanks,
 Andy
 
 
 



package db;

import java.io.*;
import java.net.*;
import java.util.*;

public class RequestBean
{

private String host;
private Vector args;
private String query;
private String template;
private String NEWLINE;
private String method;

public RequestBean()
{
query = "";
template = "";
NEWLINE = "\n";
method = "post";
host = "";
args = new Vector();
NEWLINE = System.getProperty("line.separator");


System.setProperty("java.protocol.handler.pkgs","com.sun.net.ssl.internal.www.protocol");
}

public void setHost(String s)
{
host = s;
query = "";
}

public String getHost()
{
return host;
}

public void setMethod(String s)
{
method = s;
}

public String getMethod()
{
return method;
}

public void setQuery(String s)
{
query = s;
}

public String getQuery()
{
return query;
}

public void setArgs(Vector vector)
{
args = vector;
}

public Vector getArgs()
{
return args;
}

public void addPair(String s, String s1)
{
args.addElement(s);
args.addElement(s1);
}

public void setTemplate(String s)
{
template = s;
}

public String getTemplate()
{
return template;
}

public String action()
{
if(method.equalsIgnoreCase("get"))
return doGet();
else
return doPost();
}

public String doPost()
{
Object obj = null;
URLConnection urlconnection = null;
String s2 = host;
String s3 = "";
if(query.length()  0)
s2 = s2 + "?" + query;
   
   // Build string of name/value pairs for post
   String s = "";
   Enumeration enumeration = args.elements();
   while(enumeration.hasMoreElements()) 
{
if(s.length()  0)
s = s + "";

s = s + (String)enumeration.nextElement() + "=";
s = s + URLEncoder.encode((String)enumeration.nextElement());
}

try
{
URL url = new URL(s2);
urlconnection = url.openConnection();
urlconnection.setDoOutput(true);
urlconnection.setDoInput(true);
urlconnection.setUseCaches(false);
urlconnection.setRequestProperty("content-type", 
"application/x-www-form-urlencoded");
PrintWriter printwriter = new PrintWriter(urlconnection.getOutputStream());
printwriter.print(s); // send post parms
printwriter.close();
}
catch(Exception _ex)
{
return "EXCEPTION 1:" + _ex;
}

try
{
BufferedReader bufferedreader = new BufferedReader(new 
InputStreamReader(urlconnection.getInputStream()));
String s1;
try
{
while((s1 = bufferedreader.readLine()) != null) 
s3 = s3 + s1 + NEWLINE;
}
catch(Exception _ex) { }
bufferedreader.close();
}
catch(Exception _ex)
{
return "EXCEPTION 2:" + _ex;
}

return s3;
}

public String doGet()
{
Object obj = null;
URLConnection urlconnection = null;
String s = "";
String s2 = host;
String s3 = "";
if(query.length()  0)
s2

Re: need help getting started

2001-03-02 Thread Geoff Marshall

I'm using Orion for only JSP, Beans and Servlets.  It's solid, fast, and
when you're ready to move on, you don't have to move out
-- 

-Geoff Marshall, Director of Development

...
t e r r a s c o p e  (415) 951-4944
54 Mint Street, Suite 110 direct (415) 625-0349
San Francisco, CA  94103 fax (415) 625-0306
...

 From: "johnd" [EMAIL PROTECTED]
 Reply-To: Orion-Interest [EMAIL PROTECTED]
 Date: Thu, 1 Mar 2001 20:59:00 -0800
 To: Orion-Interest [EMAIL PROTECTED]
 Subject: Re: need help getting started
 
 my main reason for switching was that orion is much faster than tomcat.
 Isn't that so?
 
 But, you are right, I had the feeling that it was way over kill...I am also
 looking into resin, I guess that is over kill, too for functionality, but
 like I said I was looking for speed gains.
 
 - Original Message -
 From: "Randahl Fink Isaksen" [EMAIL PROTECTED]
 To: "Orion-Interest" [EMAIL PROTECTED]
 Sent: Thursday, March 01, 2001 2:10 PM
 Subject: RE: need help getting started
 
 
 I would definately *NOT* recommend moving away from Tomcat if you only use
 JSP and servlets. Tomcat is the reference implementation, it is free, and
 unless you need a product with a lot of additional features (GUI helper
 tools, EJBs, remote debugging, etc.) there is no reason to open up a can
 of
 worms.
 I really like the Orion server but that is for its EJB capabilities. I
 think
 the Orion team strives for making it a great EJB server. - The aim is not
 specifically to make it the best JSP/Servlet platform available, so I
 would
 not expect it to be ahead of Tomcat in that sence.
 Orion is a great product, but also a more complicated product, so if you
 can
 use a less complex system and still fulfill your needs, then I sure
 recommend you do so.
 
 However, should you get to the point where you simply don't think using
 just
 a relational database and several truck loads of SQL really makes your
 day,
 THEN JOIN THE CLUB - that is why many of use Orion Server and Enterprise
 Java Beans.
 
 Yours Sincerely
 
 Randahl
 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]]On Behalf Of John de la
 Garza
 Sent: 1. marts 2001 19:01
 To: Orion-Interest
 Subject: need help getting started
 
 
 I have been using tomcat for some time now and am having issues with it...
 
 
 I am thinking about using Orion.  I don't do any ejb stuff and only need a
 servlet container and web server.
 
 I am having trouble using formbased security.  I couldn't get it to work
 with the users set up in the principals file.  When I would go to a
 protected area I would just get a message saying 'not allowed here' or
 something like that but I would not get prompted for a pw username.
 
 
 I actually don't want to use the principals file but have the usernames
 and
 passwds in a data base.
 
 Can anyone here refer me to some documentation on this?
 
 
 
 
 
 





Re: Storing HttpServletRequest Object in Session

2001-03-02 Thread Geoff Marshall

Because when you retrieve the request, the request is over.  The object is
gone.

Set those values at the session level.
-- 

-Geoff Marshall, Director of Development

...
t e r r a s c o p e  (415) 951-4944
54 Mint Street, Suite 110 direct (415) 625-0349
San Francisco, CA  94103 fax (415) 625-0306
...

 From: "Santosh Kumar" [EMAIL PROTECTED]
 Reply-To: Orion-Interest [EMAIL PROTECTED]
 Date: Fri, 2 Mar 2001 14:06:46 +0530
 To: Orion-Interest [EMAIL PROTECTED]
 Subject: Storing HttpServletRequest Object in Session
 
 Hi all,
 I tried to store the implicit request object in session. But when i tried to
 retrieve it.
 
 
 one.jsp
 --
 
 ...
 ...
 
 request.setAttribute("ONE", "1");
 request.setAttribute("TWO", "2");
 ..
 ..
 session.setAttribute("request",request);
 ..
 -- forward to two.jsp
 
 
 two.jsp
 --
 request = (HttpServletRequest)  session.getAttribute("request");
 out.println((String) request.getAttribute("ONE"));
 out.println((String) request.getAttribute("TWO"));
 
 
 Both the print statements are returning null.. i was expecting 1 and 2
 WHY
 
 
 Regards,
 Santosh
 
 
 
 
 
 





Re: Intro to Orion Tutorial

2001-03-01 Thread Geoff Marshall

Awesome, now if someone can translate it into Linux...
-- 

-Geoff Marshall, Director of Development

...
t e r r a s c o p e  (415) 951-4944
54 Mint Street, Suite 110 direct (415) 625-0349
San Francisco, CA  94103 fax (415) 625-0306
...






Re: login security include file

2001-03-01 Thread Geoff Marshall

According to all the books, as soon and you do a jsp:include  / there are
3 things you can't do:

1) redirect
2) mess with your response headers
3) mess with cookies

So all such code must reside before your first jsp:include / in a static
file...

-- 

-Geoff Marshall, Director of Development

...
t e r r a s c o p e  (415) 951-4944
54 Mint Street, Suite 110 direct (415) 625-0349
San Francisco, CA  94103 fax (415) 625-0306
...

 From: "Vaskin Kissoyan" [EMAIL PROTECTED]
 Organization: Lokion
 Reply-To: Orion-Interest [EMAIL PROTECTED]
 Date: Wed, 28 Feb 2001 16:35:44 -0500
 To: Orion-Interest [EMAIL PROTECTED]
 Subject: login security include file
 
 I'm trying to do a response.sendRedirect() from an include file jsp:include
 and wanted to avoid doing a directive.include (preparser),
 
 I keep getting "Response has already been committed, be sure not to write to
 the OutputStream or to trigger a commit due to any other action before calling
 this method."
 
 I have been very careful as to put this include at the very top of the file,
 and to specify autoFlush=false and flush=false on the include tag.
 
 Again, the intention of this include file would be to be place at the top of
 the jsp file to secure it by redirecting to a login page if credentials in a
 session based UserBean do not allow access to the page for some reason.
 
 -Vaskin
 





Inactive application-scope bean problem

2001-02-22 Thread Geoff Marshall

-
Hello all!  I have a simple class that I'm using as a bean.  All it does is
provide a secure and non-secure root url:

package db;

public class AppBean {
private String SecureRootURL, NonSecureRootURL;

public AppBean() {
this.SecureRootURL= "https://mybox.mydomain.com:/whatever/";
this.NonSecureRootURL = "http://mybox.mydomain.com:/whatever/";
}

public void setSecure(String newURL) { SecureRootURL = newURL; }
public String getSecure() { return SecureRootURL; }

public void setNonSecure(String newURL) { NonSecureRootURL = newURL; }
public String getNonSecure() { return NonSecureRootURL; }
}

-
At the top of each JSP page:

jsp:useBean id='ab' scope='application' class='db.AppBean'
type='db.AppBean' 
%
// initialize any application stuff

%
/jsp:useBean


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

500 Internal Server Error

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

... any ideas
-- 

-Geoff Marshall, Director of Development

...
t e r r a s c o p e  (415) 951-4944
54 Mint Street, Suite 110 direct (415) 625-0349
San Francisco, CA  94103 fax (415) 625-0306
...





Re: Inactive application-scope bean problem

2001-02-22 Thread Geoff Marshall

I'm working on the package, but not that class.  Is that the problem
-- 

-Geoff Marshall, Director of Development

...
t e r r a s c o p e  (415) 951-4944
54 Mint Street, Suite 110 direct (415) 625-0349
San Francisco, CA  94103 fax (415) 625-0306
...

 From: Rafael Alvarez [EMAIL PROTECTED]
 Reply-To: Orion-Interest [EMAIL PROTECTED]
 Date: Thu, 22 Feb 2001 09:09:27 -0400
 To: Orion-Interest [EMAIL PROTECTED]
 Subject: Re: Inactive application-scope bean problem
 
 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]
 
 
 
 





Orion doesn't work.

2001-02-15 Thread Geoff Marshall

I've surfed and surfed, and can't find any info on the problem I'm having.
HELP!


All brand new:
Red Hat Linux v7, Sun J2EE 1.2.1, Sun JDK1.3, Orion 1.4.5

[geoff@daphne orion]$cd /usr/local/orion
[geoff@daphne orion]$ java -jar orion.jar
java.lang.NoClassDefFoundError: com/evermind/gui/server/ServiceConsole
at java.lang.reflect.Method.invoke(Method.java:native)
at kaffe.jar.ExecJarName.main(ExecJarName.java:70)
at kaffe.jar.ExecJar.main(ExecJar.java:59)


Obviously, I'm missing some class, but where/what is it?  The JDK/SDK seems
to be working fine i.e. I can compile and run java applications, etc.  Does
some .jar file need to be expanded???

HELP!
-- 

-Geoff Marshall, Director of Development

...
t e r r a s c o p e  (415) 951-4944
54 Mint Street, Suite 110 direct (415) 625-0349
San Francisco, CA  94103 fax (415) 625-0306
...





Re: Problems with a finder method in a cmp

2001-02-12 Thread Geoff Marshall

Please don't laugh at me, but what IS a 'finder method in a CMP'??  Just a
simple explanation or a pointer to more info, please...
-- 

-Geoff Marshall, Director of Development

...
t e r r a s c o p e  (415) 951-4944
54 Mint Street, Suite 110 direct (415) 625-0349
San Francisco, CA  94103 fax (415) 625-0306
...

 From: "mangesh laad" [EMAIL PROTECTED]
 Reply-To: Orion-Interest [EMAIL PROTECTED]
 Date: Fri, 09 Feb 2001 19:49:26 -
 To: Orion-Interest [EMAIL PROTECTED]
 Subject: Re: Problems with a finder method in a cmp
 
 Hi
 All u have to do is just write the findByName as u already have in the
 home interface . While deploying the orion will write the coresponding
 finder query for you in the orion--ejb-jar in its finder-method tag
 
 
 
 From: "fresnaULL" [EMAIL PROTECTED]
 Reply-To: Orion-Interest [EMAIL PROTECTED]
 To: Orion-Interest [EMAIL PROTECTED]
 Subject: Problems with a finder method in a cmp
 Date: Thu, 8 Feb 2001 14:01:28 -
 
 Hi all,
 
 I'm trying to define this finder method in a cmp:
 
 SELECT * FROM people
 WHERE people.name LIKE '%name%'
 
 which is correct in SQL SERVER 7.0
 
 I put the following in the people home interface:
 
 String findByName_query = "people.name like '%$1%'";
 .
 .
 .
 public java.util.Enumeration findByName(String value) throws
 java.rmi.RemoteException, javax.ejb.FinderException;
 
 but it doesn't work. Orion is able to deploy the cmp but when I try to use
 it I only get this
 error message:
 
 500 Internal Server Error
 java.lang.NullPointerException
 at sun.jdbc.odbc.JdbcOdbcPreparedStatement.clearParameter(Unknown Source)
 at sun.jdbc.odbc.JdbcOdbcPreparedStatement.setChar(Unknown Source)
 at sun.jdbc.odbc.JdbcOdbcPreparedStatement.setString(Unknown Source)
 at com.evermind.sql.am.setString(JAX)
 at com.evermind.sql.am.setString(JAX)
 at
 PeopleHome_EntityHomeWrapper72.findByName(PeopleHome_EntityHomeWrapper72.jav
 a:1142)
 at Search.doGet(Search.java:46)
 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)
 at com.evermind.server.http.d1.forward(JAX)
 at com.evermind.server.http.ed.sp(JAX)
 at com.evermind.server.http.ed.so(JAX)
 at com.evermind.util.f.run(JAX)
 
 
 Does anybody know how i can make it work?
 
 Thanks in advance
 
 
 
 
 
 
 _
 Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.
 
 
 





Re: Setting Cookies

2001-02-09 Thread Geoff Marshall

Here's my code.  Seems to work...



import javax.servlet.*;
import javax.servlet.http.*;

public class SessionBean {
private boolean loggedOn;

public SessionBean() {
this.loggedOn = false;
}

// get customer ID from cookie
public String getCustId(HttpServletRequest req) {
Cookie[] cookies = req.getCookies();

if (cookies != null  cookies.length  0) {
for (int i = 0; i  cookies.length; i++) {
Cookie cookie = cookies[i];
if ("cust_id".equals(cookie.getName())) {
String s = cookie.getValue();
s = s==null ? "" : s; // do not return null
return s;
}
}
}
return ""; 
}

// put customer ID into cookie and log on
public void setCustId(HttpServletResponse res, String cust) {
Cookie cookie = new Cookie("cust_id", cust);
res.addCookie(cookie);
logOn();
}

public void logOn() {
this.loggedOn=true;
}
public void logOff() {
this.loggedOn=false;
}
public boolean isLoggedOn() {
return this.loggedOn;
}
}
-- 

-Geoff Marshall, Director of Development

...
t e r r a s c o p e  (415) 951-4944
54 Mint Street, Suite 110 direct (415) 625-0349
San Francisco, CA  94103 fax (415) 625-0306
...

 From: "S.Badrinarayanan" [EMAIL PROTECTED]
 Reply-To: Orion-Interest [EMAIL PROTECTED]
 Date: 9 Feb 2001 07:27:19 +
 To: Orion-Interest [EMAIL PROTECTED]
 Subject: Setting Cookies
 
 Hi
 
 Is there a known problem with adding cookies using orion 1.4.5?  I have the
 following code to set cookies
 
 res.addCookie(new javax.servlet.http.Cookie("1", "one"));
 javax.servlet.RequestDispatcher dis =
 getServletContext().getRequestDispatcher(common.util.Utils.MESSAGE_PAGE);
 dis.forward(req, res);
 
 I am printing out the cookie values in the jsp (forward statement).  But I get
 an empty list.
 
 What am I missing here?
 
 Regards
 sb
 
 
 Chequemail.com - a free web based e-mail service that also pays!!!
 http://www.chequemail.com
 
 





Re: Output Volume

2001-02-06 Thread Geoff Marshall

Check your implicit out object (Type JSPWriter).  You can get the size of
the output buffer from the bufferSize property and you can flush your output
buffers before you hit that size.

e.g.



// output something
out.println("...");

if (out.getRemaining()  someComfortableMargin) {
out.flush();
out.clear();
}

// keep on outputting
out.println("...");
-- 

-Geoff Marshall, Director of Development

...
t e r r a s c o p e  (415) 951-4944
54 Mint Street, Suite 110 direct (415) 625-0349
San Francisco, CA  94103 fax (415) 625-0306
...

 From: "Chandika Mendis" [EMAIL PROTECTED]
 Reply-To: Orion-Interest [EMAIL PROTECTED]
 Date: Tue, 6 Feb 2001 08:21:13 -0800
 To: Orion-Interest [EMAIL PROTECTED]
 Subject: Output Volume
 
 I'm trying to run a very simple JSP that gives a rather large volume of
 output. It loads the first time but fails the second time.(was doing some
 performance comparisons). The same JSP works fine with ServletExec. Any help
 will be appreciated.
 
 
 I've attached the JSP below:-
 
 %@page language="java" import="java.util.* %
 HTML
 BODY
 %
 
 Date st=new Date();
 StringBuffer fullString=new StringBuffer();
 for (int i=0;i1;i++){
 out.println("Some string concatenation blah blah blah "+i+"BR");
 }
 Date end=new Date();
 out.println("Time elapsed :"+(end.getTime()-st.getTime()));
 %
 /BODY
 /HTML
 
 
 
 





Re: HTTPS from Orion Java Bean

2001-02-06 Thread Geoff Marshall

Tim-  

Thanks for responding.  I need to learn to write these messages a little
more clearly.

Basically, I downloaded the JSSE stuff from Sun and tweaked the J2sdkee1.2.1
to allow me access to the SSL routines as per Sun's instructions.  I
compiled the Java class and executed it (see below).  It runs, so I know
it's not the code that has the problem.

When I bring it into Orion as a class instantiated by a jsp:usebean tag, I
then get the error message.

So I'm thinking I need to apply the JSSE stuff to Orion in some way, and I
can find no information on how to do that...
-- 

-Geoff Marshall, Director of Development

...
t e r r a s c o p e  (415) 951-4944
54 Mint Street, Suite 110 direct (415) 625-0349
San Francisco, CA  94103 fax (415) 625-0306
...

import java.io.*;
import java.net.*;
import java.util.*;
import javax.servlet.http.*;
import java.text.*;

// Take a credit card transaction and interact with the authorization
// company.  Get an authorization.  Parse return. Store it in the database.
Handle errors.
// decide which page to display.
// call this with all the parameters on the url...
public class AuthBean {
// authorization object
// consists of information regarding requested transaction
// and response from that transaction.
private String authURL;

public AuthBean() {

System.setProperty("java.protocol.handler.pkgs","com.sun.net.ssl.internal.ww
w.protocol");
this.authURL = "https://www.verisign.com/"
}

public void setGateway(String gateway) {
this.authURL = gateway;
}

public String authorize(String parms) throws Exception {
URL gateway = new URL(this.authURL + "?" + parms);
BufferedReader in = new BufferedReader(new
InputStreamReader(gateway.openStream()));

String inputLine=null, authorization="";

while ((inputLine = in.readLine()) != null)
authorization = authorization + inputLine;

in.close();
return authorization;
}

public static void main(String args[]) {
AuthBean ab = new AuthBean();

try {
System.out.println(ab.authorize("test"));
} catch(Exception e) {
System.out.println("EXCEPTION:" + e);
}
}
}





HTTPS from Orion Java Bean

2001-02-05 Thread Geoff Marshall

Hello all!

I've written a bean that calls a credit card processing gateway from a Java
bean.  It is very simple and executes an https://... request.  Then it reads
the entire contents of the web page.

And it works if I run my AuthBean class from the command line.  But when I
attempt to use AuthBean, calling it from an Orion JSP, I get a runtime
error:

SSL not implemented.

So I looked at all I did to enable the j2sdkee1.2.1 to work with SSL and
tried to somehow apply that to Orion, but I came up blank.

I read through the SSL help page and it doesn't seem to address the problem
I'm having.

Any help would be appreciated!


-- 

-Geoff Marshall, Director of Development

...
t e r r a s c o p e  (415) 951-4944
54 Mint Street, Suite 110 direct (415) 625-0349
San Francisco, CA  94103 fax (415) 625-0306
...





JSP extends directive - has anybody tried it?

2000-06-20 Thread Geoff . Lewis

Hello List,

We are currently trying to port our complete JSP (1.0-style) application to
Orion. For historical reasons our application uses the JSP extends
directive, for example:

%@ page extends="com.finatec.services.servlet.ISecureServlet" %

We have converted our ISecureServlet class so that it itself extends the
Orion implementation class com.evermind.server.http.EvermindHttpJspPage. We
have previously ported our application to Resin, which also has a JSP 1.1
engine, using the same technique.

However, when we now access the containing JSP page it compiles but fails
during processing with the error

"Superclass of the JSP page does not implement HttpJspPage, invalid
extends attribute"

We've traced the problem down to the point (in dn.class) where Orion checks
to see (we believe) whether the generated JSP Servlet class is assignable
(via the Class.isAssignableFrom method) from the class that we are
extending, namely ISecureServlet. The classes are not assignable, hence the
error message.

With this in mind, I have two questions:

1. Is the assignment check the right way around? Shouldn't we instead check
to see if ISecureServlet is assignable from our generated servlet?

2. Otherwise, has anybody successfully used the extends directive? If so,
what class did you inherit, and do you have any other tips that might help
us out?

Regards,
Geoff Lewis
Finatec Financial Software Solutions AG
Tel: +49 9371 97860
Fax: +49 9371 403381
Web: http://www.finatec.com
Email: [EMAIL PROTECTED]