[JBoss-user] RE: Asking about Schedular Servlet in JBoss

2002-12-31 Thread Barney Rubble
Timer service was added to EJB 2.1 specification:

http://www2.theserverside.com/resources/article.jsp?l=MonsonHaefel-Column4

JMX compliant timer service is also available:

http://www.jboss.org/online-manual/HTML/ch11s55.html


- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, December 30, 2002 7:46 AM
Subject: JBoss-user digest, Vol 1 #3560 - 9 msgs


> Send JBoss-user mailing list submissions to
> [EMAIL PROTECTED]
>
> To subscribe or unsubscribe via the World Wide Web, visit
> https://lists.sourceforge.net/lists/listinfo/jboss-user
> or, via email, send a message with subject or body 'help' to
> [EMAIL PROTECTED]
>
> You can reach the person managing the list at
> [EMAIL PROTECTED]
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of JBoss-user digest..."
>
>
> Today's Topics:
>
>1. RE: http session status = broken? (Sacha Labourey)
>2. Asking about Schedular Servlet in JBoss (Thaer Hani Al-Ibaisi)
>3. Re[2]: [JBoss-user] Question about CMP/CMR (Alex Loubyansky)
>4. Re: How to INSERT after ebjPostCreate versus ejbCreate
(Jonathan.O'[EMAIL PROTECTED])
>5. RE: Re[2]: [JBoss-user] Question about CMP/CMR (Panagiotis Korros)
>6. Scheduler MBean Information (Thaer Hani Al-Ibaisi)
>7. Re[4]: [JBoss-user] Question about CMP/CMR (Alex Loubyansky)
>8. Re: Date and jboss (Dain Sundstrom)
>9. RE: Asking about Schedular Servlet in JBoss (Brian Topping)
>
> --__--__--
>
> Message: 1
> From: "Sacha Labourey" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Date: Mon, 30 Dec 2002 08:55:27 +0100
> Subject: RE: [JBoss-user] http session status = broken?
> Reply-To: [EMAIL PROTECTED]
>
> It is intended to work. If it doesn't, make us know that. Take a fresh CVS
> snapshot (module jboss-3.0 from Branch_3_0).
>
> Cheers,
>
>
> Sacha
>
> > -Message d'origine-
> > De : [EMAIL PROTECTED]
> > [mailto:[EMAIL PROTECTED]]De la part de Dan K.
> > Envoye : dimanche, 29 decembre 2002 18:53
> > A : [EMAIL PROTECTED]
> > Objet : [JBoss-user] http session status = broken?
> >
> >
> >
> > Hi everyone,
> >
> > I'm a new user to jboss and am trying to figure out how to setup jboss
> > clustering, with http session replication.  I've scanned the mail
archive
> > for this list and it appears to be broken?
> >
> > Can I get a confirmation from people if it's really broken or if a
> > particular setup is?  However, if there is a way to get anything to
work,
> > I'd like to try it.  I'm using jboss 3.0.4 and tried 3.0.5 rc2 from cvs
> > Branch_3_0.
> >
> > Many thanks in advance!
> >
> > Regards,
> > Dan
> >
> >
> > ---
> > This sf.net email is sponsored by:ThinkGeek
> > Welcome to geek heaven.
> > http://thinkgeek.com/sf
> > ___
> > JBoss-user mailing list
> > [EMAIL PROTECTED]
> > https://lists.sourceforge.net/lists/listinfo/jboss-user
> >
>
>
>
> --__--__--
>
> Message: 2
> From: Thaer Hani Al-Ibaisi <[EMAIL PROTECTED]>
> To: [EMAIL PROTECTED]
> Date: Mon, 30 Dec 2002 10:48:03 +0200
> Subject: [JBoss-user] Asking about Schedular Servlet in JBoss
> Reply-To: [EMAIL PROTECTED]
>
> This message is in MIME format. Since your mail reader does not understand
> this format, some or all of this message may not be legible.
>
> --_=_NextPart_001_01C2AFE0.2C6FF3A0
> Content-Type: text/plain;
> charset="iso-8859-1"
>
> Hi all,
>
> I was deploying my application under JRun 3.1 Web server, and I was using
> the "allaire.jrun.scheduler.CronService" servlet class that comes with
JRun
> library, this servlet works as a schedular to call a URL every part of
time
> that you specify, (I was using it, to control sending a Batch email
> functionality every two hours).
>
> So, any one know a substitute in JBoss that could help me to get the same
> functionality as JRun servlet class.
>
> Quick help is very thanked.
>
>
>
>
>
> --_=_NextPart_001_01C2AFE0.2C6FF3A0
> Content-Type: text/html;
> charset="iso-8859-1"
>
> 
> 
> 
>
>
> 
> 
> Hi
> all,
>  class=875473808-30122002> 
> I was
deploying my
> application under JRun 3.1 Web server, and I was using the
> "allaire.jrun.scheduler.CronService" servlet class that comes with JRun
library,
> this servlet works as a schedular to call a URL every part of time that
you
> specify, (I was using it, to control sending a Batch email functionality
every
> two hours).
>  class=875473808-30122002> 
> So, any one
know a
> substitute in JBoss that could help me to get the same functionality as
JRun
> servlet class.
>  class=875473808-30122002> 
> Quick help is
very
> thanked.
>  class=875473808-30122002> 
>  class=875473808-30122002> 
>  class=875473808-30122002> 
>  class=875473808-30122002> 
>
> --_=_NextPart_001_01C2AFE0.2C6FF3A0--
>
>
> --__--__--
>
> Message: 3
> Date: Mon, 30 Dec 2002 12:19:04 +0200
> From: Alex Loubyansky <[EMAIL PROTECTED]>
> To: "Langelage, Frank" <[EMAIL PROTECTED]>
> S

[JBoss-user] RE: Using CMR with PK-Field as FK

2002-12-31 Thread Rod Macpherson
It appears these CMR access and foreign key constraint issues can be
resolved in a specficiation compliant and portable manner by implementing
the INSERT after ejbPostCreate returns. As it stands we have to change our
schema to defer referential integrity checks until we commit. Those building
J2EE applications on top of legacy database structures (perhaps a
significant percentage) will find that a difficult sell in production
environments with existing applications already in place. The lack of a
deferred insert may also require code changes when porting from weblogic -
at least - to support this difference in behavior. The approach taken by
weblogic (deferred inserts) appear to have significant merits.



---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



RE: [JBoss-user] Standalone Tomcat 4.1 and JAAS

2002-12-31 Thread Brian Topping
Thanks for the response, sorry for the delay in digesting this...

It seems like the AuthenticationManager and RealmManager interfaces don't
have any particularly sensitive methods related to them, so my guess is the
only reason that these aren't already available remotely is because they are
different per web application?  Correct me if I am wrong, but this solution
seems like it would only support one login context per JNDI tree.

If that's the case, one option would be to parameterize the instantiation of
JBossSecurityMgrRealm with the name of a java:comp/env/security subcontext to
use.  This would solve this issue, but are working patches of this nature
something that you would consider applying or is this a misguided hack?

happy ny!

-b


> -Original Message-
> From: Scott M Stark [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, December 18, 2002 9:24 PM
> To: [EMAIL PROTECTED]
> Subject: Re: [JBoss-user] Standalone Tomcat 4.1 and JAAS
> 
> 
> The ClientLoginModule is just a wrapper around the 
> SecurityAssociation thread
> local variable accessors and the JBossSecurityMgrRealm uses 
> this directly. It
> also uses the AuthenticationManager and RealmMapping of the security
> manager associated with the web app. This is obtained through 
> JNDI, and this
> is not available remotely from the JBoss server. This is what 
> you need to work on.
> 
> You could use the JBossSecurityMgrRealm as is if you created a JNDI
> ObjectFactory binding under java:comp/env/security that 
> supported lookups
> of the "securityMgr" and "realmMapping" bindings, and returned remoted
> proxies for the corresponding AuthenticationManager and RealmMapping
> interfaces of the security manager. Its doable since all the 
> interface objects are
> compatible with RMI, its just going to take some work.
> 
> 
> Scott Stark
> Chief Technology Officer
> JBoss Group, LLC
> 
> 
> - Original Message - 
> From: "Brian Topping" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Wednesday, December 18, 2002 4:59 PM
> Subject: RE: [JBoss-user] Standalone Tomcat 4.1 and JAAS
> 
> 
> > -Original Message-
> > From: Scott M Stark [mailto:[EMAIL PROTECTED]]
> > Subject: Re: [JBoss-user] Standalone Tomcat 4.1 and JAAS
> > 
> > 
> > Its not going to work. The JBossSecurityMgrRealm is 
> designed for being
> > embedded in JBoss. You would have to modify it significantly to run
> > standalone.
> 
> Hi Scott,
> 
> Fair enough, thanks for the clue...
> 
> So I'm wondering if you would consider my wanting to make 
> said significant
> modifications to be possible with existing APIs on the server 
> side.  I'm
> guessing the result would be something that needs to be a 
> selection of meaty
> bits from both the JBossSecurityMgrRealm and ClientLoginModules.  
> 
> Am I on the right track here?  Are there any potential API 
> issues that you
> know of that would cause this to be impossible from a design 
> standpoint?
> 
> Thanks for your consideration,
> 
> -b
> 
> 
> 
> ---
> This SF.NET email is sponsored by: Order your Holiday Geek 
> Presents Now!
> Green Lasers, Hip Geek T-Shirts, Remote Control Tanks, 
> Caffeinated Soap,
> MP3 Players,  XBox Games,  Flying Saucers,  WebCams,  Smart Putty.
> T H I N K G E E K . C O M   http://www.thinkgeek.com/sf/
> ___
> JBoss-user mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/jboss-user
> 


---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] Scheduler in JBoss

2002-12-31 Thread Guy Rouillier
Have you taken a look at testsuite?  There is an example there.  See
\jboss-3.0.4-src\testsuite\src\resources\util\test-default-scheduler-service
.xml and \jboss-3.0.4\server\default\deploy\scheduler-service.xml.

- Original Message -
From: "Thaer Hani Al-Ibaisi" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, December 31, 2002 2:24 AM
Subject: [JBoss-user] Scheduler in JBoss


>
>All,
>
>Please for who worked on Scheduler and know how to use it in JBoss,
> please specify the needed steps for me to configure a Timer on Jboss to
call
> the following URL every 30 minutes from the starting of the JBoss Server
> (Using JBoss 3.0.4).
>
>
> ---
> This sf.net email is sponsored by:ThinkGeek
> Welcome to geek heaven.
> http://thinkgeek.com/sf
> ___
> JBoss-user mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/jboss-user
>



---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] Re: Using CMR with PK-Field as FK

2002-12-31 Thread Jonathan . O'Connor
Alex,
Let me repeat what I think happens during entity bean creation:
In ejbCreate we set all primary key fields.
In ejbPostCreate we can set up any CMR fields.
Any CMR fields set in ejbCreate are ignored, and must be set again in 
ejbPostCreate.

Now if we have a table, T1,  with PK = {pkCol1, pkCol2}, and pkCol1 acts 
as a foreign key to another table, T2, then our entity bean will have a 
problem, because the field mapped to pkCol1 will also be marked as a CMR 
field, and so it will be blanked out at the end of ejbCreate (actually 
throws the IllegalStateException seen below).

So, can we instead only nullify CMR fields that are not mapped to primary 
key fields. This should work fine if T1-T2 is many to one or one to one 
relationship. Many to many is not a problem in this case because we are 
using foreign key constraints and not a mapping table to implement the 
relationship.

So, in Frank's example, he sets up the two parts of the primary key in 
ejbCreate, and does nothing in ejbPostCreate. He can use his CMR getter no 
problem. Of course, the CMR setter would throw an exception as you can't 
change the primary key.

Have I missed anything?
Happy New Year,
Jonathan




Alex Loubyansky <[EMAIL PROTECTED]>
Sent by: [EMAIL PROTECTED]
31.12.2002 12:22
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:[JBoss-user] Re: Using CMR with PK-Field as FK


Hello Frank,

see my answer below.

Tuesday, December 31, 2002, 2:06:52 PM, you wrote:

LF> I have two beans Feature and FeatureOption with CMR.
LF> JBoss-HEAD created the tables correct, using the new feature to have 
the 
LF> same field as FK to parent and part of PK:
LF> create table feature ( feature_id smallint not null,  description 
LF> varchar(30),  primary key (feature_id)  constraint pk_feature );
LF> create table feature_option ( feature_id smallint not null, 
LF>  option_id integer not null,  description varchar(30),  primary key 
LF> (feature_id,option_id) constraint pk_feature_option );
LF> alter table feature_option add constraint (foreign key 
(feature_id) 
LF> references feature  constraint fk_featur_1isvfy8);

LF> But everytime I try to add FeatureOptions to Feature, I get an 
Exception:
LF> java.lang.IllegalStateException: CMR field Feature_options is 
mapped 
LF> to a foreign key which is a part for a primary key,
LF> and primary key may only be set once in ejbCreate [EJB 2.0 
Spec.10.3.5].

LF> My code looks like this:
LF> feature = featureHome.create( feature_id, description );
LF> coll = feature.getOptions();
LF> featureOption = featureOptionHome.create( feature_id, option_id, 
LF> description );
LF> coll.add( featureOption ); // this line throws the exception.

LF> So my Question is: How to add a FeatureOption to Feature ?

This is the expected behaviour.
In this case, the relationships are assigned between ejbCreate and 
ejbPostCreate.
Having the same values in pk field and the corresponding fk field
means having a relationship.
Any attempt to modify the relationship with CMR accessors or
with collection api will throw this exception.
The relationship is removed only with one of the participant removal.

Do you think it should work other way?

alex




---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] How to INSERT after ebjPostCreate versus ejbCreate

2002-12-31 Thread Jonathan . O'Connor
Dain,
I did a hunt on google for any problems, and the only thing I found was 
this:
www.geocities.com/lydian_third/ admintips/pkconstraint.pdf 

Basically it seems that unique indexes may cause a problem with deferrable 
constraints. However, I think the way we use the deferrable fk constraint, 
then it should be OK.

Ciao,
Jonathan




Dain Sundstrom <[EMAIL PROTECTED]>
Sent by: [EMAIL PROTECTED]
30.12.2002 17:26
Please respond to jboss-user

 
To: [EMAIL PROTECTED]
cc: 
Subject:Re: [JBoss-user] How to INSERT after ebjPostCreate versus 
ejbCreate


I've had a lot of Oracle DBAs tell me that DEFERRABLE INITIALLY 
DEFERRED does "very bad things" to Oracle.  I don't remember the 
details, but it was bad enough that I gave up on some code that 
depended on it.

-dain

On Monday, December 30, 2002, at 10:17 AM, Bill Burke wrote:

> nice, thanks Jonathan.
>
>> -Original Message-
>> From: [EMAIL PROTECTED]
>> [mailto:[EMAIL PROTECTED]]On Behalf Of
>> Jonathan.O'[EMAIL PROTECTED]
>> Sent: Monday, December 30, 2002 6:10 AM
>> To: [EMAIL PROTECTED]
>> Subject: Re: [JBoss-user] How to INSERT after ebjPostCreate versus
>> ejbCreate
>>
>>
>> Rod,
>> If you are using Oracle as your DB, then you can mark your CMR fk 
>> columns
>> as DEFERRABLE INITIALLY DEFERRED.
>> Oracle will only check the non-null constraints at commit time. 
>> Shouldn't
>> be a problem for you.
>>
>> Other DBs may have something similar.
>>
>> Ciao,
>> Jonathan
>>
>>
>>
>>
>> "Rod Macpherson" <[EMAIL PROTECTED]>
>> Sent by: [EMAIL PROTECTED]
>> 21.12.2002 19:53
>> Please respond to jboss-user
>>
>>
>> To: <[EMAIL PROTECTED]>
>> cc:
>> Subject:[JBoss-user] How to INSERT after
>> ebjPostCreate versus ejbCreate
>>
>>
>> Calling an entity bean CMR setter method within ejbCreate is 
>> prohibited.
>> The
>> general solution is to make CMP calls within ejbCreate and CMR calls 
>> in
>> ejbPostCreate. That solution does not work when the CMR field maps
>> directly
>> to a non-nullable required column value. WebLogic resolves this issue 
>> by
>> deferring INSERT statements. How does one specify that option in 
>> JBoss?
>>
>>
>>
>>
>>
>> ---
>> This SF.NET email is sponsored by: Order your Holiday Geek Presents 
>> Now!
>> Green Lasers, Hip Geek T-Shirts, Remote Control Tanks, Caffeinated 
>> Soap,
>> MP3 Players,  XBox Games,  Flying Saucers,  WebCams,  Smart Putty.
>> T H I N K G E E K . C O M   http://www.thinkgeek.com/sf/
>> ___
>> JBoss-user mailing list
>> [EMAIL PROTECTED]
>> https://lists.sourceforge.net/lists/listinfo/jboss-user
>>
>>
>>
>>
>>
>> ---
>> This sf.net email is sponsored by:ThinkGeek
>> Welcome to geek heaven.
>> http://thinkgeek.com/sf
>> ___
>> JBoss-user mailing list
>> [EMAIL PROTECTED]
>> https://lists.sourceforge.net/lists/listinfo/jboss-user
>
>
>
> ---
> This sf.net email is sponsored by:ThinkGeek
> Welcome to geek heaven.
> http://thinkgeek.com/sf
> ___
> JBoss-user mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/jboss-user



---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] Re: Using CMR with PK-Field as FK

2002-12-31 Thread Alex Loubyansky
Hello Frank,

see my answer below.

Tuesday, December 31, 2002, 2:06:52 PM, you wrote:

LF> I have two beans Feature and FeatureOption with CMR.
LF> JBoss-HEAD created the tables correct, using the new feature to have the 
LF> same field as FK to parent and part of PK:
LF> create table feature ( feature_id smallint not null,  description 
LF> varchar(30),  primary key (feature_id)  constraint pk_feature );
LF> create table feature_option ( feature_id smallint not null, 
LF>  option_id integer not null,  description varchar(30),  primary key 
LF> (feature_id,option_id) constraint pk_feature_option );
LF> alter table feature_option add constraint (foreign key (feature_id) 
LF> references feature  constraint fk_featur_1isvfy8);

LF> But everytime I try to add FeatureOptions to Feature, I get an Exception:
LF> java.lang.IllegalStateException: CMR field Feature_options is mapped 
LF> to a foreign key which is a part for a primary key,
LF> and primary key may only be set once in ejbCreate [EJB 2.0 Spec.10.3.5].

LF> My code looks like this:
LF> feature = featureHome.create( feature_id, description );
LF> coll = feature.getOptions();
LF> featureOption = featureOptionHome.create( feature_id, option_id, 
LF> description );
LF> coll.add( featureOption ); // this line throws the exception.

LF> So my Question is: How to add a FeatureOption to Feature ?

This is the expected behaviour.
In this case, the relationships are assigned between ejbCreate and ejbPostCreate.
Having the same values in pk field and the corresponding fk field
means having a relationship.
Any attempt to modify the relationship with CMR accessors or
with collection api will throw this exception.
The relationship is removed only with one of the participant removal.

Do you think it should work other way?

alex




---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] Using CMR with PK-Field as FK

2002-12-31 Thread Langelage, Frank
I have two beans Feature and FeatureOption with CMR.
JBoss-HEAD created the tables correct, using the new feature to have the 
same field as FK to parent and part of PK:
   create table feature ( feature_id smallint not null,  description 
varchar(30),  primary key (feature_id)  constraint pk_feature );
   create table feature_option ( feature_id smallint not null, 
option_id integer not null,  description varchar(30),  primary key 
(feature_id,option_id) constraint pk_feature_option );
   alter table feature_option add constraint (foreign key (feature_id) 
references feature  constraint fk_featur_1isvfy8);

But everytime I try to add FeatureOptions to Feature, I get an Exception:
   java.lang.IllegalStateException: CMR field Feature_options is mapped 
to a foreign key which is a part for a primary key,
   and primary key may only be set once in ejbCreate [EJB 2.0 Spec.10.3.5].

My code looks like this:
feature = featureHome.create( feature_id, description );
coll = feature.getOptions();
featureOption = featureOptionHome.create( feature_id, option_id, 
description );
coll.add( featureOption ); // this line throws the exception.

So my Question is: How to add a FeatureOption to Feature ?




---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


RE: [JBoss-user] http session status = broken?

2002-12-31 Thread Sacha Labourey
> Sacha, as you're more use to this ejb clustering framework, maybe 
> you know something about this possibility. Is it worth a try? 

Yes it is worth a try because I know some people using it in production ;)

Cheers,


Sacha


---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] New class loading architecture doc available

2002-12-31 Thread Scott M Stark
An excerpt on the class loading architecture from the 3.0.5RC1 version of the
JBoss Administration and Development book has been made available on
SourceForge here:
http://prdownloads.sourceforge.net/jboss/ClassLoading.pdf?download

It contains a discussion of the Java type system and how class loading fits in
along with common class loading problems such as ClassCastExceptions,
IllegalAccessExceptions and LinkageErrors. Send any feedback to
[EMAIL PROTECTED]


Scott Stark
Chief Technology Officer
JBoss Group, LLC



---
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user