Re: [JBoss-user] sql query

2001-10-10 Thread Edward Q. Bridges

would this do it?

select grp, cmod, dmod from table where
grp in (select distinct grp from table)




On Tue, 9 Oct 2001 19:17:43 -0400, David Jencks wrote:

unfortunately your question makes no sense.  If the GRP value does not
determine the CMOD and DMOD values, which one of the rows with a given GRP
value do you want?  If there is an aggregation function that can sensibly
be applied to CMOD and DMOD, you can do a group by query select grp,
f(CMOD), f(DMOD) from TABLE group by grp  where f is the aggregation
function (sum, min, max, etc)

david jencks

On 2001.10.09 17:27:05 -0400 [EMAIL PROTECTED] wrote:
 Sorry my internet access is down so I am going to try and ask this
 question
 here instead of at a related site.
 I need to do a query like this:
 String sql=SELECT DISTINCT  GRP,CMOD,DMOD FROM TABLE;
 The problem is I only want distinct on the first column(GRP) but it
 returns
 all distinct combinations of the above three columns.
 Any sql pros out there?
 THANKS!! Graham
 
 ___
 JBoss-user mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/jboss-user
 
 

___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] sql query

2001-10-10 Thread David Jencks

no

id grp cmod dmod
1  1   1 1
2  1   1 1

original query returns one row
your query should return 2 rows

I think he needs to give a specific example of what he wants (ie values, as
above) to get an answer that relates to his problem.

david jencks

On 2001.10.10 03:25:35 -0400 Edward Q. Bridges wrote:
 would this do it?
 
 select grp, cmod, dmod from table where
 grp in (select distinct grp from table)
 
 
 
 
 On Tue, 9 Oct 2001 19:17:43 -0400, David Jencks wrote:
 
 unfortunately your question makes no sense.  If the GRP value does not
 determine the CMOD and DMOD values, which one of the rows with a given
 GRP
 value do you want?  If there is an aggregation function that can
 sensibly
 be applied to CMOD and DMOD, you can do a group by query select grp,
 f(CMOD), f(DMOD) from TABLE group by grp  where f is the aggregation
 function (sum, min, max, etc)
 
 david jencks
 
 On 2001.10.09 17:27:05 -0400 [EMAIL PROTECTED] wrote:
  Sorry my internet access is down so I am going to try and ask this
  question
  here instead of at a related site.
  I need to do a query like this:
  String sql=SELECT DISTINCT  GRP,CMOD,DMOD FROM TABLE;
  The problem is I only want distinct on the first column(GRP) but it
  returns
  all distinct combinations of the above three columns.
  Any sql pros out there?
  THANKS!! Graham
  
  ___
  JBoss-user mailing list
  [EMAIL PROTECTED]
  https://lists.sourceforge.net/lists/listinfo/jboss-user
  
  
 
 ___
 JBoss-user mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/jboss-user
 
 
 
 ___
 JBoss-user mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/jboss-user
 
 

___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] JSP custom taglib/security context problem

2001-10-10 Thread Achilleus Mantzios

Hi ,
i have made my own taglib in order to facilitate page layout with templates.
I every page i have 
- header
- sidebar
- content
- footer

My taglib code that does the actual insertion has as follows:
pageContext.include(a url);

Now the problem.

I access beans, which access EJBs, from the content JSP page.
When this JSP page is the *first* jsp page included (inserted) (that is, 
every other page is HTML), then everything is ok.
If there is a JSP page (e.g header) inserted before my content JSP page,
then the security context is not propagated from the web container (tomcat)
to the EJB container (jboss).

Anyone had similar problems??
Any (direct) clues for debugging??


___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] Forum/list archive search

2001-10-10 Thread Fred Loney

1) Search of the sourceforge user list archive yields following message:

  Unable to read configuration file '/bigassraid/htdig//conf/10767.conf'

Can the list administrator fix this?

2) The Jive user forum search is an OR match on any word in the target
string. Is there a way to enable an AND search capability that matches
on all words in the target string?

Thanks.

Fred Loney
Spirited Software, Inc.
www.spiritedsw.com


___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] ERROR : Nested Field does not have a get method

2001-10-10 Thread Fred Loney

The probable cause is that jboss can't map a CMP entity bean field to a
JDBC type. Check that every entity bean field is of primitive type, has
a get method and is included in the appropriate config files. If you
intend to use a non-primitive field, then validate its config setting.

I suspect that the cited message is a last gasp deployment verification
exception that traps several cases which may or may not have to do with
nested fields.

Fred Loney
Spirited Software, Inc.
www.spiritedsw.com


- Original Message -
From: David M. Karr [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, October 09, 2001 6:44 PM
Subject: [JBoss-user] ERROR : Nested Field does not have a get method


 When I deploy my EAR, I see the following message right after JAWS
created one
 of my tables:

 [Container factory] ERROR : Nested Field does not have a get method

 What does this mean?  I sure wish it had a little more useful
information.

 --
 ===
 David M. Karr  ; Best Consulting
 [EMAIL PROTECTED]   ; Java/Unix/XML/C++/X ; BrainBench CJ12P
(#12004)


 ___
 JBoss-user mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/jboss-user



___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] Forum/list archive search

2001-10-10 Thread danch

The first issue has been a problem for months. If you go to the JBoss site
and follow the archive link from there, you'll be led to a search that
works.

- Original Message -
From: Fred Loney [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, October 10, 2001 9:09 AM
Subject: [JBoss-user] Forum/list archive search


 1) Search of the sourceforge user list archive yields following message:

   Unable to read configuration file '/bigassraid/htdig//conf/10767.conf'

 Can the list administrator fix this?

 2) The Jive user forum search is an OR match on any word in the target
 string. Is there a way to enable an AND search capability that matches
 on all words in the target string?

 Thanks.

 Fred Loney
 Spirited Software, Inc.
 www.spiritedsw.com


 ___
 JBoss-user mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/jboss-user



___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



AW: [JBoss-user] JBoss Mysql Connection pooling

2001-10-10 Thread Jan Heise

most often this is an issue connected to the user/password
used. try to connect from the commandline via mysql and the
user/passwd you want to use. and use the machine jboss is
running on. perhaps you lack the needed permissions for
remote connections to mysql.

jan

--
Jan Heise / Tel: +49-163-4803237 / E-Mail: [EMAIL PROTECTED]

-Ursprüngliche Nachricht-
Von: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]Im Auftrag von Imran
Bohoran
Gesendet: Mittwoch, 10. Oktober 2001 16:39
An: Jboss-User (E-mail)
Betreff: [JBoss-user] JBoss Mysql Connection pooling



Hi all

There's a problem in configuring the Connection pools in JBoss for MySQL.
Initially this was working fine. we had to remove JBoss from one system
where things were going smoothly . now I've installed JBoss again and am
trying to configure my pool. the container simply hangs saying that its
trying to bound the connection pool to the name given in the jboss.jcml. I
uninstalled MySQL and tried it again. but the same issue came up. has any
one come across this issue. if so pls respond

tia

Imran

___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] JBoss Mysql Connection pooling

2001-10-10 Thread danch

A hang at that point means that either JBoss can't load the JDBC driver, or
the JDBC driver can't connect to the database. Did you remember to put the
driver jar into lib/ext? Are you sure you have the connection URL right (can
you connect from a standalone app with that URL)?

- Original Message -
From: Imran Bohoran [EMAIL PROTECTED]
To: Jboss-User (E-mail) [EMAIL PROTECTED]
Sent: Wednesday, October 10, 2001 9:39 AM
Subject: [JBoss-user] JBoss Mysql Connection pooling



 Hi all

 There's a problem in configuring the Connection pools in JBoss for MySQL.
 Initially this was working fine. we had to remove JBoss from one system
 where things were going smoothly . now I've installed JBoss again and am
 trying to configure my pool. the container simply hangs saying that its
 trying to bound the connection pool to the name given in the jboss.jcml. I
 uninstalled MySQL and tried it again. but the same issue came up. has any
 one come across this issue. if so pls respond

 tia

 Imran

 ___
 JBoss-user mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/jboss-user



___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] jboss - castor class loading problem

2001-10-10 Thread Joost v.d. Wijgerd
Title: jboss - castor class loading problem






Hi,


I'm currently testing with jboss and castor to do the object-relational mapping,

but I get the following exception:


[Default] org.exolab.castor.mapping.MappingException: Could not find the class com.smarthaven.component.profiler.Profile

[Default] at org.exolab.castor.mapping.loader.MappingLoader.createDescriptor(MappingLoader.java:300)

[Default] at org.exolab.castor.jdo.engine.JDOMappingLoader.createDescriptor(JDOMappingLoader.java:147)

[Default] at org.exolab.castor.mapping.loader.MappingLoader.loadMapping(MappingLoader.java:211)

[Default] at org.exolab.castor.jdo.engine.JDOMappingLoader.loadMapping(JDOMappingLoader.java:294)

[Default] at org.exolab.castor.mapping.Mapping.getResolver(Mapping.java:278)

[Default] at org.exolab.castor.jdo.engine.DatabaseRegistry.loadDatabase(DatabaseRegistry.java:317)

[Default] at org.exolab.castor.jdo.JDO.getDatabase(JDO.java:465)

[Default] at com.smarthaven.component.profiler.ProfileManagerBean.createGroup(ProfileManagerBean.java:57)

[Default] at java.lang.reflect.Method.invoke(Native Method)

[Default] at org.jboss.ejb.StatelessSessionContainer$ContainerInterceptor.invoke(StatelessSessionContainer.java:54

3)

[Default] at org.jboss.ejb.plugins.TxInterceptorBMT.invoke(TxInterceptorBMT.java:276)

[Default] at org.jboss.ejb.plugins.StatelessSessionInstanceInterceptor.invoke(StatelessSessionInstanceInterceptor.

java:87)

[Default] at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:128)

[Default] at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:195)

[Default] at org.jboss.ejb.StatelessSessionContainer.invoke(StatelessSessionContainer.java:286)

[Default] at org.jboss.ejb.plugins.jrmp.server.JRMPContainerInvoker.invoke(JRMPContainerInvoker.java:395)

[Default] at java.lang.reflect.Method.invoke(Native Method)

[Default] at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:242)

[Default] at sun.rmi.transport.Transport$1.run(Transport.java:155)

[Default] at java.security.AccessController.doPrivileged(Native Method)

[Default] at sun.rmi.transport.Transport.serviceCall(Transport.java:152)

[Default] at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:462)

[Default] at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:662)

[Default] at java.lang.Thread.run(Thread.java:498)


The profile class is part of je beans.jar. I suspect it is a class-loading problem, has anybody seen this

before?


thanx,


Joost.





[JBoss-user] Jboss security Messages

2001-10-10 Thread Gerry Duhig

When running secured applications under the combined JBoss-Tomcat, the
console is full of messages of the form:
 
 John Doe is authorised
John Doe is authenticated
 
 How do I get rid of these, or at least pass them off to a file.
 
 Gerry
 
 


___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] jboss with jbuilder

2001-10-10 Thread Yahoo



Hi,

The integration of jboss with jbuilder 4 was good 
for me till I try my secured ejbs. The "secure stateless sessionbean" container 
configuration was moved from jboss.xml to standard-jboss.xml under conf/tomcat. 
When it is started from jbuilder 4, the following exception was thrown, saying 
that the configuration 'Secure Stateless SessionBean' not found. But actually 
it's there. It runs perfect under dos command though. 

Anybody has the same experience?

Burt

Auto deploy] Starting

[Auto deploy] Watching 
E:\working\yy\Cyclops\ExternalPackages\JBoss-2.2.2_Tomcat-3.2.2\jboss\deploy

[Auto deploy] Auto deploy of 
file:/E:/working/yy/Cyclops/ExternalPackages/JBoss-2.2.2_Tomcat-3.2.2/jboss/deploy/cyclops-ejb.jar

[J2EE Deployer Default] Deploy J2EE application: 
file:/E:/working/yy/Cyclops/ExternalPackages/JBoss-2.2.2_Tomcat-3.2.2/jboss/deploy/cyclops-ejb.jar

[J2EE Deployer Default] Create application 
cyclops-ejb.jar

[J2EE Deployer Default] install module 
cyclops-ejb.jar

[Container factory] 
Deploying:file:/E:/working/yy/Cyclops/ExternalPackages/JBoss-2.2.2_Tomcat-3.2.2/jboss/tmp/deploy/Default/cyclops-ejb.jar

[Container factory] 
org.jboss.ejb.DeploymentException: Error in jboss.xml for Bean SecuritySession: 
configuration 'Secure Stateless SessionBean' not found in standardjboss.xml or 
jboss.xml

[Container factory] at 
org.jboss.metadata.ApplicationMetaData.importJbossXml(ApplicationMetaData.java:323)

[Container factory] at 
org.jboss.metadata.XmlFileLoader.load(XmlFileLoader.java:120)

[Container factory] at 
org.jboss.ejb.ContainerFactory.deploy(ContainerFactory.java:388)

[Container factory] at 
org.jboss.ejb.ContainerFactory.deploy(ContainerFactory.java:334)

[Container factory] at 
org.jboss.ejb.ContainerFactory.deploy(ContainerFactory.java:275)

[Container factory] at 
java.lang.reflect.Method.invoke(Native Method)

[Container factory] at 
com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628)

[Container factory] at 
com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)

[Container factory] at 
org.jboss.deployment.J2eeDeployer.startApplication(J2eeDeployer.java:415)

[Container factory] at 
org.jboss.deployment.J2eeDeployer.deploy(J2eeDeployer.java:178)

[Container factory] at 
java.lang.reflect.Method.invoke(Native Method)

[Container factory] at 
com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628)

[Container factory] at 
com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)

[Container factory] at 
org.jboss.ejb.AutoDeployer.deploy(AutoDeployer.java:358)

[Container factory] at 
org.jboss.ejb.AutoDeployer.run(AutoDeployer.java:221)

[Container factory] at 
org.jboss.ejb.AutoDeployer.startService(AutoDeployer.java:332)

[Container factory] at 
org.jboss.util.ServiceMBeanSupport.start(ServiceMBeanSupport.java:93)

[Container factory] at 
java.lang.reflect.Method.invoke(Native Method)

[Container factory] at 
com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628)

[Container factory] at 
com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)

[Container factory] at 
org.jboss.util.ServiceControl.start(ServiceControl.java:97)

[Container factory] at 
java.lang.reflect.Method.invoke(Native Method)

[Container factory] at 
com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628)

[Container factory] at 
com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)

[Container factory] at 
org.jboss.Main.init(Main.java:217)

[Container factory] at 
org.jboss.Main$1.run(Main.java:121)

[Container factory] at 
java.security.AccessController.doPrivileged(Native Method)

[Container factory] at 
org.jboss.Main.main(Main.java:117)

[J2EE Deployer Default] Starting cyclops-ejb.jar 
failed!

[Auto deploy] org.jboss.ejb.DeploymentException: 
Could not deploy 
file:/E:/working/yy/Cyclops/ExternalPackages/JBoss-2.2.2_Tomcat-3.2.2/jboss/tmp/deploy/Default/cyclops-ejb.jar, 
Cause:org.jboss.ejb.DeploymentException: Error in jboss.xml for Bean 
SecuritySession: configuration 'Secure Stateless SessionBean' not found in 
standardjboss.xml or jboss.xml

[Auto deploy] at 
org.jboss.ejb.ContainerFactory.deploy(ContainerFactory.java:365)

[Auto deploy] at 
org.jboss.ejb.ContainerFactory.deploy(ContainerFactory.java:275)

[Auto deploy] at 
java.lang.reflect.Method.invoke(Native Method)

[Auto deploy] at 
com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628)

[Auto deploy] at 
com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)

[Auto deploy] at 
org.jboss.deployment.J2eeDeployer.startApplication(J2eeDeployer.java:415)

[Auto deploy] at 
org.jboss.deployment.J2eeDeployer.deploy(J2eeDeployer.java:178)

[Auto deploy] at 
java.lang.reflect.Method.invoke(Native Method)

[Auto deploy] at 
com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1628)

[Auto deploy] at 

[JBoss-user] integrating with MS Sql Server

2001-10-10 Thread David Treves



Hi,

I am running JBoss 2.4.0 and I wish to integrate it 
with MS Sql Server. I went through the documentation, but it seems like I am 
missing something...

I added the relevant MBean" to 
jboss.jcmland the definition of the Minerva 
connection pool, but when I test it and run the server it is stucked on the line 
where it is trying to run that service/thread.

The MBean I added is:

mbean code="org.jboss.jdbc.XADataSourceLoader" 
name="DefaultDomain:service=XADataSource,name=SQLServerPool" 
attribute 
name="DataSourceClass"org.jboss.pool.jdbc.xa.wrapper.XADataSourceImpl/attribute 
attribute 
name="PoolName"SQLServerPool/attribute 
attribute 
name="URL"jdbc:odbc:ejb/attribute 
attribute name="JDBCUser"sa/attribute 
attribute name="Password"mamamia/attribute 
attribute name="Properties"/attribute 
attribute 
name="GCMinIdleTime"120/attribute 
attribute name="MaxSize"10/attribute 
attribute name="GCEnabled"false/attribute 
attribute 
name="InvalidateOnError"false/attribute 
attribute 
name="TimestampUsed"false/attribute 
attribute name="Blocking"true/attribute 
attribute 
name="GCInterval"12/attribute 
attribute 
name="IdleTimeout"180/attribute 
attribute 
name="IdleTimeoutEnabled"false/attribute 
attribute 
name="LoggingEnabled"false/attribute 
attribute 
name="MaxIdleTimeoutPercent"1.0/attribute 
attribute name="MinSize"0/attribute 
/mbean

and the line 
where the initializing process is stucked at is:

[XADataSourceLoader] 
Started[XADataSourceLoader] Starting[SQLServerPool] XA Connection pool 
SQLServerPool bound to java:/SQLServerPool


Any idea why that happens?

Thanks in advance,
David.


Re: [JBoss-user] Fine grained security JBOSS

2001-10-10 Thread Scott M Stark

 I'm still unsure how one would implement security in respect of entity
 ownership. Assume I have an entity, e.g. an Appointment in a Schedule
 and want to grant read and write permissions to certain roles or users.
 How would I implement this logic. One solution that comes to my mind is
 à la if (entity.canRead(getCallerPrincipal()) and manage the Users /
 Principals with a custom jboss security adapter which works on top of
 the application's user model.
 Is there any standard / existing jboss security adapter which works on
 top of a simple ejb user + role model?

 -billy.

The most natural solution in my mind is to use Java2 style permission.

Permission p = new DocumentPermission(docName, read);
AccessController.checkPermission(p);

When coupled with JAAS subject based permissions this provides an elegant
solution. There is an example of using this type of custom permissions for a
JNDI model that checks for permissions like your are talking about. I have
not
had time to document this so you'll have to just try to wade through the
code
which is made up of these classes:

org.jboss.test.security.ejb.project.ProjRepositoryBean
org.jboss.test.security.proxy.ProjRepositorySecurityProxy2
org.jboss.test.security.test.NamespacePermission


Scott Stark
Chief Technology Officer
JBoss Group, LLC

- Original Message -
From: Philipp Meier [EMAIL PROTECTED]
To: JBOSS_USER [EMAIL PROTECTED]
Sent: Wednesday, October 10, 2001 7:34 AM
Subject: Re: [JBoss-user] Fine grained security  JBOSS




___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] LoginModule called multiple times after auth with 2 url-patterns

2001-10-10 Thread David Ward

Hi, all - found a weird security problem.

My arch:
- Red Hat 7.1, JDK 1.3.1, JBoss-2.4.3_Tomcat-3.2.3
- using a custom LoginModule we wrote

My app:
- .ear with one .war and a few ejb .jar's
- web.xml has these blocks in it:
...snip...

   servlet-mapping
 servlet-nameBLAH/servlet-name
 url-pattern/BLAH/*/url-pattern
   /servlet-mapping
   ...
   security-constraint
 web-resource-collection
   web-resource-nameMyApp/web-resource-name
   url-pattern/test/*/url-pattern
   url-pattern/BLAH/test/*/url-pattern
 /web-resource-collection
 auth-constraint
   role-namefoobar/role-name
 /auth-constraint
   /security-constraint

...snip...

Notice that the first url-pattern protected is just content, whereas the 
second is a servlet with a specific pathInfo after it.  What's good is 
that both url-patterns are being protected (we're using BASIC 
authentication just for now)...

Whichever url-pattern I hit first, I can see my LoginModule debug that 
it's doing work, and surfing to any other page under that first 
url-pattern incurs no more work in the LoginModule.  *However*, then 
surfing to a place underneath the second url-pattern causes the 
LoginModule to reprocess.  Since my browser is just re-broadcasting my 
BASIC authentication, the user doesn't notice anything, BUT I'm worried 
(performance-wise) about the LoginModule working again.  It keeps 
getting invoked after any surfing I do in the second url-pattern.  Also, 
it doesn't matter which url-pattern I authenticate to first; whichever 
one prompted the login only calls the LoginModule once whereas the 
second one continuosly calls the LoginModule for every request.  Why?

Any ideas?

Thanks,
David


___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



Re: [JBoss-user] integrating with MS Sql Server

2001-10-10 Thread David Jencks

Since blocking is true, most likely your connection parameters are wrong
and it can't get a connection.

check:

driver is listed in JdbcProvider mbean

you can connect from standalone program using exactly the driver, url,
username, password in your conf.

Note that use of the jdbc-odbc bridge is strongly discouraged.

david jencks

On 2001.10.10 13:03:02 -0400 David Treves wrote:
 Hi,
 
 I am running JBoss 2.4.0 and I wish to integrate it with MS Sql Server. I
 went through the documentation, but it seems like I am missing
 something...
 
 I added the relevant MBean to jboss.jcml and the definition of the
 Minerva connection pool, but when I test it and run the server it is
 stucked on the line where it is trying to run that service/thread.
 
 The MBean I added is:
 
 mbean code=org.jboss.jdbc.XADataSourceLoader
 name=DefaultDomain:service=XADataSource,name=SQLServerPool
 attribute 
name=DataSourceClassorg.jboss.pool.jdbc.xa.wrapper.XADataSourceImpl/attribute
 attribute name=PoolNameSQLServerPool/attribute
 attribute name=URLjdbc:odbc:ejb/attribute
 attribute name=JDBCUsersa/attribute
 attribute name=Passwordmamamia/attribute
 attribute name=Properties/attribute
 attribute name=GCMinIdleTime120/attribute
 attribute name=MaxSize10/attribute
 attribute name=GCEnabledfalse/attribute
 attribute name=InvalidateOnErrorfalse/attribute
 attribute name=TimestampUsedfalse/attribute
 attribute name=Blockingtrue/attribute
 attribute name=GCInterval12/attribute
 attribute name=IdleTimeout180/attribute
 attribute name=IdleTimeoutEnabledfalse/attribute
 attribute name=LoggingEnabledfalse/attribute
 attribute name=MaxIdleTimeoutPercent1.0/attribute
 attribute name=MinSize0/attribute
   /mbean
 
 and the  line where the initializing process is stucked at is:
 
 [XADataSourceLoader] Started
 [XADataSourceLoader] Starting
 [SQLServerPool] XA Connection pool SQLServerPool bound to
 java:/SQLServerPool
 
 
 Any idea why that happens?
 
 Thanks in advance,
 David.
 
 !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.0 Transitional//EN
 HTMLHEAD
 META http-equiv=Content-Type content=text/html; charset=windows-1255
 META content=MSHTML 5.50.4807.2300 name=GENERATOR
 STYLE/STYLE
 /HEAD
 BODY bgColor=#ff
 DIVFONT face=Arial size=2Hi,/FONT/DIV
 DIVFONT face=Arial size=2/FONTnbsp;/DIV
 DIVFONT face=Arial size=2I am running JBoss 2.4.0 and I wish to
 integrate it 
 with MS Sql Server. I went through the documentation, but it seems like I
 am 
 missing something.../FONT/DIV
 DIVFONT face=Arial size=2/FONTnbsp;/DIV
 DIVFONT face=Arial size=2I added the relevant lt;MBeangt; to 
 jboss.jcml/FONTFONT face=Arial size=2nbsp;and the definition of the
 Minerva 
 connection pool, but when I test it and run the server it is stucked on
 the line 
 where it is trying to run that service/thread./FONT/DIV
 DIVnbsp;/DIV
 DIVFONT face=Arial size=2The MBean I added is:/FONT/DIV
 DIVnbsp;/DIV
 DIVFONT face=Arial size=2lt;mbean
 code=org.jboss.jdbc.XADataSourceLoader 
 
name=DefaultDomain:service=XADataSource,name=SQLServerPoolgt;BRnbsp;nbsp;nbsp;
 
 lt;attribute 
 
name=DataSourceClassgt;org.jboss.pool.jdbc.xa.wrapper.XADataSourceImpllt;/attributegt;BRnbsp;nbsp;nbsp;
 
 lt;attribute 
 
name=PoolNamegt;STRONGSQLServerPool/STRONGlt;/attributegt;BRnbsp;nbsp;nbsp;
 
 lt;attribute 
 name=URLgt;jdbc:odbc:ejblt;/attributegt;BRnbsp;nbsp;nbsp; 
 lt;attribute name=JDBCUsergt;salt;/attributegt;BRnbsp;nbsp;nbsp;
 
 lt;attribute name=Passwordgt;mamamialt;/attributegt;BRnbsp;nbsp;nbsp;
 
 lt;attribute name=Propertiesgt;lt;/attributegt;BRnbsp;nbsp;nbsp;
 
 lt;attribute 
 name=GCMinIdleTimegt;120lt;/attributegt;BRnbsp;nbsp;nbsp; 
 lt;attribute name=MaxSizegt;10lt;/attributegt;BRnbsp;nbsp;nbsp;
 
 lt;attribute name=GCEnabledgt;falselt;/attributegt;BRnbsp;nbsp;nbsp;
 
 lt;attribute 
 name=InvalidateOnErrorgt;falselt;/attributegt;BRnbsp;nbsp;nbsp;
 
 lt;attribute 
 name=TimestampUsedgt;falselt;/attributegt;BRnbsp;nbsp;nbsp; 
 lt;attribute name=Blockinggt;truelt;/attributegt;BRnbsp;nbsp;nbsp;
 
 lt;attribute 
 name=GCIntervalgt;12lt;/attributegt;BRnbsp;nbsp;nbsp; 
 lt;attribute 
 name=IdleTimeoutgt;180lt;/attributegt;BRnbsp;nbsp;nbsp; 
 lt;attribute 
 name=IdleTimeoutEnabledgt;falselt;/attributegt;BRnbsp;nbsp;nbsp;
 
 lt;attribute 
 name=LoggingEnabledgt;falselt;/attributegt;BRnbsp;nbsp;nbsp; 
 lt;attribute 
 name=MaxIdleTimeoutPercentgt;1.0lt;/attributegt;BRnbsp;nbsp;nbsp;
 
 lt;attribute name=MinSizegt;0lt;/attributegt;BRnbsp; 
 lt;/mbeangt;/FONT/DIV
 DIVnbsp;/DIV
 DIVFONT face=Arial size=2and the /FONTnbsp;FONT face=Arial
 size=2line 
 where the initializing process is stucked at is:/FONT/DIV
 DIVFONT face=Arial size=2/FONTnbsp;/DIV
 DIVFONT face=Arial size=2[XADataSourceLoader] 
 StartedBR[XADataSourceLoader] StartingBR[SQLServerPool] XA Connection
 pool 
 SQLServerPool bound to java:/SQLServerPool/FONT/DIV
 DIVFONT face=Arial size=2/FONTnbsp;/DIV
 DIVFONT face=Arial 

Re: [JBoss-user] Fine grained security JBOSS

2001-10-10 Thread Scott M Stark

The example code relies on the JBoss specific SecurityProxyInterceptor to
establish
the JAAS context and the
org.jboss.test.security.proxy.ProjRepositorySecurityProxy2
performs the permission checks using the AccessController and other logic.

 The problem that I had was this:  AccessController relies on your subject
 being stored in a thread variable (i.e. static variable mapped to the
 thread.)  In non-EJB code, you can use Subject.doAs or
 Subject.doAsPrivileged to set your subject after logging in.  In EJB,
 however, this is not safe because the spec does not guarantee thread or
JVM
 consistency over cross-EJB calls.  (Correct?)
Correct in that the bean author has no control over how its calls are
dispatched and whether the Subject associated with the caller thread
is propagated.

 The best solution I could come up with is sort of a hack, but it should
 work.  You can use getCallerPrincipal to retrieve the principal from the
 EJB context...  Make a new subject to contain that principal, you don't
need
 to add credentials because AccessController doesn't care about those.
 Execute Subject.doAsPrivileged with your new principal, and an anonymous
 inner PrivilegedAction class, and perform your
 AccessController.checkPermission in there.  (I've written a small test,
 and it works, but it ain't pretty.)

 Scott, is this pretty much what you had in mind, or did you have a better
 solution?
If your going to try to do something in an app server independent manner
that is what you need to do. I simply use the JBoss security proxy
interceptor
as portable custom security is something of an oxymoron due to the lack of
support in the J2EE specs.


Scott Stark
Chief Technology Officer
JBoss Group, LLC

- Original Message -
From: Michael Jara [EMAIL PROTECTED]
To: JBOSS_USER [EMAIL PROTECTED]
Sent: Wednesday, October 10, 2001 11:09 AM
Subject: Re: [JBoss-user] Fine grained security  JBOSS


I was working on a solution similar to this, using JAAS authorization with
EJBs.  After looking at your (Scott's) code, I didn't see any checks done
with the AccessController.

The problem that I had was this:  AccessController relies on your subject
being stored in a thread variable (i.e. static variable mapped to the
thread.)  In non-EJB code, you can use Subject.doAs or
Subject.doAsPrivileged to set your subject after logging in.  In EJB,
however, this is not safe because the spec does not guarantee thread or JVM
consistency over cross-EJB calls.  (Correct?)

The best solution I could come up with is sort of a hack, but it should
work.  You can use getCallerPrincipal to retrieve the principal from the
EJB context...  Make a new subject to contain that principal, you don't need
to add credentials because AccessController doesn't care about those.
Execute Subject.doAsPrivileged with your new principal, and an anonymous
inner PrivilegedAction class, and perform your
AccessController.checkPermission in there.  (I've written a small test,
and it works, but it ain't pretty.)

Scott, is this pretty much what you had in mind, or did you have a better
solution?

Mike

- Original Message -
From: Scott M Stark [EMAIL PROTECTED]
To: JBOSS_USER [EMAIL PROTECTED]
Sent: Wednesday, October 10, 2001 11:44 AM
Subject: Re: [JBoss-user] Fine grained security  JBOSS


  I'm still unsure how one would implement security in respect of entity
  ownership. Assume I have an entity, e.g. an Appointment in a Schedule
  and want to grant read and write permissions to certain roles or users.
  How would I implement this logic. One solution that comes to my mind is
  à la if (entity.canRead(getCallerPrincipal()) and manage the Users /
  Principals with a custom jboss security adapter which works on top of
  the application's user model.
  Is there any standard / existing jboss security adapter which works on
  top of a simple ejb user + role model?
 
  -billy.

 The most natural solution in my mind is to use Java2 style permission.

 Permission p = new DocumentPermission(docName, read);
 AccessController.checkPermission(p);

 When coupled with JAAS subject based permissions this provides an elegant
 solution. There is an example of using this type of custom permissions for
a
 JNDI model that checks for permissions like your are talking about. I have
 not
 had time to document this so you'll have to just try to wade through the
 code
 which is made up of these classes:

 org.jboss.test.security.ejb.project.ProjRepositoryBean
 org.jboss.test.security.proxy.ProjRepositorySecurityProxy2
 org.jboss.test.security.test.NamespacePermission




___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



[JBoss-user] jBoss + ANT + NetBeans

2001-10-10 Thread IvanLatysh

Someone have samples how run jBoss with my beans for debugging from NetBeans.

I am using NetBeans 3.2 and latest jBoss.
I have visited jBoss manual and NetBeans manual - but there are soo old information.

Sincerely yours, Ivan Latysh.
[EMAIL PROTECTED]
http://ivan.yourmail.com


___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user



RE: [JBoss-user] jBoss + ANT + NetBeans

2001-10-10 Thread John Moore
Title: RE: [JBoss-user] jBoss + ANT + NetBeans





\usr\j2se\bin\java -Xint -Xdebug -Xnoagent %JAXP% -classpath %JBOSS_CLASSPATH% -Xrunjdwp:transport=dt_socket,server=y,address=12999,suspend=n org.jboss.Main %1 %2 %3 %4 %5 %6 %7 %8 %9

I have used the above to debug beans running within jboss on Win2K. You have to attach to the jboss jvm from netbeans after you run. This is from our run.bat, the same should work on unix changing \ to / and %[var]% to ${var}. Make sure you compile with -g for access to everything and change back to -g:none before you test/deploy.

john moore





-Original Message-
From: IvanLatysh [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, October 10, 2001 1:49 PM
To: [EMAIL PROTECTED]
Subject: [JBoss-user] jBoss + ANT + NetBeans



Someone have samples how run jBoss with my beans for debugging from NetBeans.


I am using NetBeans 3.2 and latest jBoss.
I have visited jBoss manual and NetBeans manual - but there are soo old information.


Sincerely yours, Ivan Latysh.
[EMAIL PROTECTED]
http://ivan.yourmail.com



___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user





[JBoss-user] build.bat

2001-10-10 Thread Alice Ad
Can someone please send me build.bat (for JBoss 2.2.2 Windows NT) ? I downloaded it from jboss-all but somehow its giving me a lot of errors. Your help will be highly appreciated.
Thanks much.
Do You Yahoo!?
Make a great connection at Yahoo! Personals.