[Security & JAAS/JBoss] - Query fails in the Util class used by the DatabaseServerLogi
by eblom
I'm using the DatabaseServerLoginModule in my project and when the Util class is executing my query it fails.
The code that is failing in the Util class, method: static Group[] getRoleSets(String username, String dsJndiName, String rolesQuery, AbstractServerLoginModule aslm, boolean suspendResume):
code:
do
{
String name = rs.getString(1);
String groupName = rs.getString(2); // Throws exception
If I comment the code:
String groupName = null // rs.getString(2);
Then it will work.
Is this a bug? The query is working; the problem is when the code will fetch the result.
I'm using the following query:
SELECT accessprivileges.privilegename FROM securityprofileprivileges
INNER JOIN accessprivileges ON (securityprofileprivileges.privilegeid=accessprivileges.privilegeid)
INNER JOIN securityprofiles ON (securityprofileprivileges.securityprofileid=securityprofiles.securityprofileid)
INNER JOIN users ON (users.securityprofileid=securityprofiles.securityprofileid) WHERE userid=?
/Magnus
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4049236#4049236
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4049236
18 years, 11 months
No ManagedConnections problem- JBoss + MSSQL
by Shanmugam Karthikeyan NCS
Hi All,
I am having a major production issue.Every week , atleast once I am
getting the following error.
Iam using JBoss + MSSQL + Quartz.
As far as i know this 'no managed connection' problem will come mostly,
if there is not enough connection in the JBoss connection pool.
Now my application and the Quartz are using the same datarouce.At first
i suspected that my application is not closing the connection properly
which might have resulted in this problem.But i checked my application
code , and the closing it done properly.
Is there any known problem in Quartz which uses many connections.I am
planning to create a new datasource which will be used only for Quartz,
Will this solves my problem.
Pls help me to find a good solution to this problem.
2007-05-23 08:43:45,776 INFO
[com.ncs.iframe.extensions.scheduler.quartz.IFrameQuartzScheduler]
Scheduler initiating ...
>>>>>>>>>>>>>>>> ;>>>>>>>>
2007-05-23 08:44:14,823 ERROR [org.quartz.impl.jdbcjobstore.JobStoreTX]
MisfireHandler: Error handling misfires: Failed to obtain DB connection
from data source 'myDS': java.sql.SQLException: Could not retrieve
datasource via JNDI url 'java:/iconnectDS'
org.jboss.util.NestedSQLException: No ManagedConnections available
within configured blocking timeout ( 30000 [ms] ); - nested throwable:
(javax.resource.ResourceException: No ManagedConnections available
within configured blocking timeout ( 30000 [ms] ))
org.quartz.JobPersistenceException: Failed to obtain DB connection from
data source 'myDS': java.sql.SQLException: Could not retrieve datasource
via JNDI url 'java:/iconnectDS' org.jboss.util.NestedSQLException: No
ManagedConnections available within configured blocking timeout ( 30000
[ms] ); - nested throwable: (javax.resource.ResourceException: No
ManagedConnections available within configured blocking timeout ( 30000
[ms] )) [See nested exception: java.sql.SQLException: Could not retrieve
datasource via JNDI url 'java:/iconnectDS'
org.jboss.util.NestedSQLException: No ManagedConnections available
within configured blocking timeout ( 30000 [ms] ); - nested throwable:
(javax.resource.ResourceException: No ManagedConnections available
within configured blocking timeout ( 30000 [ms] ))]
at
org.quartz.impl.jdbcjobstore.JobStoreSupport.getConnection(JobStoreSuppo
rt.java :575)
at
org.quartz.impl.jdbcjobstore.JobStoreTX.doRecoverMisfires(JobStoreTX.jav
a:1343)
at
org.quartz.impl.jdbcjobstore.JobStoreSupport$MisfireHandler.manage(JobSt
oreSupp ort.java:2449)
at
org.quartz.impl.jdbcjobstore.JobStoreSupport$MisfireHandler.run(JobStore
Support .java:2468)
* Nested Exception (Underlying Cause) ---------------
java.sql.SQLException: Could not retrieve datasource via JNDI url
'java:/iconnectDS' org.jboss.util.NestedSQLException: No
ManagedConnections available within configured blocking timeout ( 30000
[ms] ); - nested throwable: (javax.resource.ResourceException: No
ManagedConnections available within configured blocking timeout ( 30000
[ms] ))
at
org.quartz.utils.JNDIConnectionProvider.getConnection(JNDIConnectionProv
ider.ja va:166)
at
org.quartz.utils.DBConnectionManager.getConnection(DBConnectionManager.j
ava:111 )
at
org.quartz.impl.jdbcjobstore.JobStoreSupport.getConnection(JobStoreSuppo
rt.java :553)
at
org.quartz.impl.jdbcjobstore.JobStoreTX.doRecoverMisfires(JobStoreTX.jav
a:1343)
at
org.quartz.impl.jdbcjobstore.JobStoreSupport$MisfireHandler.manage(JobSt
oreSupp ort.java:2449)
at
org.quartz.impl.jdbcjobstore.JobStoreSupport$MisfireHandler.run(JobStore
Support .java:2468)
2007-05-23 08:44:15,777 INFO [STDOUT]
org.quartz.JobPersistenceException: Failed to obtain DB connection from
data source 'myDS': java.sql.SQLException: Could not retrieve datasource
via JNDI url 'java:/iconnectDS' org.jboss.util.NestedSQLException: No
ManagedConnections available within configured blocking timeout ( 30000
[ms] ); - nested throwable: (javax.resource.ResourceException: No
ManagedConnections available within configured blocking timeout ( 30000
[ms] )) [See nested exception: java.sql.SQLException: Could not retrieve
datasource via JNDI url 'java:/iconnectDS'
org.jboss.util.NestedSQLException: No ManagedConnections available
within configured blocking timeout ( 30000 [ms] ); - nested throwable:
(javax.resource.ResourceException: No ManagedConnections available
within configured blocking timeout ( 30000 [ms] ))]
2007-05-23 08:44:15,779 INFO [STDOUT] at
org.quartz.impl.jdbcjobstore.JobStoreSupport.getConnection(JobStoreSuppo
rt.java :575)
2007-05-23 08:44:15,779 INFO [STDOUT] at
org.quartz.impl.jdbcjobstore.JobStoreTX.removeTrigger(JobStoreTX.java:36
5)
2007-05-23 08:44:15,779 INFO [STDOUT] at
org.quartz.core.QuartzScheduler.unscheduleJob(QuartzScheduler.java:723)
2007-05-23 08:44:15,779 INFO [STDOUT] at
org.quartz.impl.StdScheduler.unscheduleJob(StdScheduler.java:285)
2007-05-23 08:44:15,779 INFO [STDOUT] at
com.ncs.iframe.extensions.scheduler.quartz.IFrameQuartzScheduler.unsched
uleTask (IFrameQuartzScheduler.java:345)
Best Regards,
Shanmugam Karthikeyan
Chief Architect Office
NCS Pte. Ltd.
(A member of the Singapore Telecom Group)
5 Ang Mo Kio St 62, NCS Hub, S (569141)
___________________________________
Tel * 65566786
Fax* 64835431
E-mail * skarthi(a)ncs.com.sg
Web * http://www.ncs.com.sg
-----Original Message-----
From: jboss-user-bounces(a)lists.jboss.org
[mailto:jboss-user-bounces@lists.jboss.org] On Behalf Of
jboss-user-request(a)lists.jboss.org
Sent: Tuesday, May 29, 2007 5:39 PM
To: Shanmugam Karthikeyan NCS
Subject: Welcome to the "jboss-user" mailing list (Digest mode)
Welcome to the jboss-user(a)lists.jboss.org mailing list! Welcome to
JBoss-user. Please observe the netitquette directives when posting
here.
To post to this list, send your email to:
jboss-user(a)lists.jboss.org
General information about the mailing list is at:
https://lists.jboss.org/mailman/listinfo/jboss-user
If you ever want to unsubscribe or change your options (eg, switch to
or from digest mode, change your password, etc.), visit your
subscription page at:
https://lists.jboss.org/mailman/options/jboss-user/skarthi%40ncs.com.sg
You can also make such adjustments via email by sending a message to:
jboss-user-request(a)lists.jboss.org
with the word `help' in the subject or body (don't include the
quotes), and you will get back a message with instructions.
You must know your password to change your options (including changing
the password, itself) or to unsubscribe. It is:
karmaker
Normally, Mailman will remind you of your lists.jboss.org mailing list
passwords once every month, although you can disable this if you
prefer. This reminder will also include instructions on how to
unsubscribe or change your account options. There is also a button on
your options page that will email your current password to you.
18 years, 11 months
[Beginners Corner] - JMS C/C++ client without a java proxy
by l33t_Phr3Ak
Hey folks,
i know there is a jms-subforum, but scince my question is nothing specific and scince i am quite new to jboss, i thougt this subforum would be the right place.
I am wondering if there is a C client for JMS which doesn't require a java-Proxy?
I know the active-mq website, but the c/c++ client section there is really confusing and it seems that no one takes care of it anymore:
The active-mq website suggest the following as c/c++-clients:
anonymous wrote : It is very common for an organisation to have lots of legacy C code which needs integration into the message bus. The current available solutions are
|
| * use the OpenWire C Client which is only available in ActiveMQ 4.x or later.
| * we are working on the OpenWire CPP Client
| * the ActiveMQ C++ Clients is currently a C++ API to Stomp, and is a full-blown replacement for CMS for AMQ v4.0.1 and later. In the future this will be expanded to support OpenWire as well.
| * the CMS C++ client which is a C++ API to Stomp which can also be implemented with OpenWire
|
| * use the Stomp C Client for any version of ActiveMQ from 3.1 onwards. You can also use Stomp from many other languages like .Net, Python, Ruby, Perl etc.
|
|
But:
a)
anonymous wrote : * use the OpenWire C Client which is only available in ActiveMQ 4.x or later.
The only two links:
anonymous wrote : You can browse the code here
|
| http://svn.activemq.org/branches/activemq-4-0/activemq/openwire-c/
|
| e.g. here's an example of it in use...
|
| http://svn.activemq.org/branches/activemq-4-0/activemq/openwire-c/src/exa...
are deadlinks.
Google doesn't help as well, this project seems to be dead?
b)
anonymous wrote : we are working on the OpenWire CPP Client
ok, nothing released yet (as far as i can tell)
c)
anonymous wrote : the ActiveMQ C++ Clients is currently a C++ API to Stomp, and is a full-blown replacement for CMS for AMQ v4.0.1 and later. In the future this will be expanded to support OpenWire as well.
But if i click on the link i get redirected to
anonymous wrote : CMS is an easy-to-use JMS 1.1-like API. Our implementation of CMS is called ActiveMQ-CPP, the architecture for which supports pluggable transport protocols, very much like the ActiveMQ broker itself.
So it says " it is a full replacement for CMS", but leads me directly to CMS?
What the hack?
Furthermore - and even worse - __NOT__ a single download link is working as well as the link to the api-docs is broken (if it ever worked)...
d)
anonymous wrote : the CMS C++ client which is a C++ API to Stomp which can also be implemented with OpenWire
Yeah, see c)
e)
anonymous wrote : use the Stomp C Client for any version of ActiveMQ from 3.1 onwards. You can also use Stomp from many other languages like .Net, Python, Ruby, Perl etc.
Almost no documentation at all.
So, in a nutshell, this whole "jms-c/c++ client" project seems to be just dead or unusable....
Has somebody any ideas for a:
- C/C++ JMS client
- which does not need a proxy
Thx for all clues in advance!
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4049232#4049232
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4049232
18 years, 11 months