[JBoss Web Services] - Web Service with Kerberos policy
by Siddhartha Roy
Siddhartha Roy [http://community.jboss.org/people/ssroy73] created the discussion
"Web Service with Kerberos policy"
To view the discussion, visit: http://community.jboss.org/message/585162#585162
--------------------------------------------------------------
Hi,
I have written a web service (JDK1,6, JBoss 4.2.3, Metro, Netbeans) which uses Kerberos Security Policy.
I have written a web client. But while accessing the service, I get following exception. Not getting any clue of the error.
java.lang.ClassCastException
at java.lang.Class.cast(Class.java:2990)
at com.sun.xml.ws.util.ServiceFinder$LazyIterator.next(ServiceFinder.java:374)
at com.sun.xml.ws.api.client.ServiceInterceptorFactory.load(ServiceInterceptorFactory.java:80)
at com.sun.xml.ws.client.WSServiceDelegate.<init>(WSServiceDelegate.java:205)
at com.sun.xml.ws.client.WSServiceDelegate.<init>(WSServiceDelegate.java:178)
at com.sun.xml.ws.spi.ProviderImpl.createServiceDelegate(ProviderImpl.java:106)
at javax.xml.ws.Service.<init>(Service.java:56)
at org.me.calculator.CalculatorWSService.<init>(CalculatorWSService.java:46)
at com.Client.show(Client.java:17)
at org.apache.jsp.index_jsp._jspService(index_jsp.java:72)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:373)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:336)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:182)
at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:262)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:446)
at java.lang.Thread.run(Thread.java:619)
Any help will be greately appreciated.
Many Thanks.
Best Regards - Roy
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/585162#585162]
Start a new discussion in JBoss Web Services at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
13 years, 4 months
[jBPM] - Environment for jBPM 4 workflow (jPDL, xPDL, ...)
by Pedro Kowalski
Pedro Kowalski [http://community.jboss.org/people/pedrokowalski] created the discussion
"Environment for jBPM 4 workflow (jPDL, xPDL, ...)"
To view the discussion, visit: http://community.jboss.org/message/585129#585129
--------------------------------------------------------------
Hi guys,
I've got a question. We want to use the jBPM 4 as our process manager. We've choosen the BPMN as a notation which can be understood by both - developers and analysts guys.
It occurs that the only problem is the jPDL format. There are basically 2 tools which I know about, that the analyst can work on, and which can be used to export BPMN into the jPDL.
The first one is *Eclipse jBPM/jPDL 4 editor* which is nice, but it's very close to the developer world. It doesn't support the swimming pools, swimming lanes, timers, messaging and so on. So it's not fully BPMN editor, but rather a jPDL editor.
The second one is *Visual Architect* which is nice for the analysts guys, as it supports full BPMN, but its export to jPDL is very poor. I mean - jPDL 3.x? It's a bit old to be used right now, where jBPM 4 works on jPDL 4, and jBPM 5 is just around the corner.
So, we can choose to create jPDL-only diagrams using Eclipse plugin or create full BPMN diagrams in Visual Architect which can be exported to jPDL 3.x only. Needless to say - *both ways are unsatisfactory*...
*There is a need for tool which can support BPMN (like BizAgi) and can export the result into the jPDL 4.x.*
I've looked for xPDL -> jPDL translators (as there are some nice tools with xPDL export only) but without any luck. Only answers are like 'no' or 'it's not possible', so I guess it's futile to search for this tool?
Maybe there are some solutions (even commercial - we are definitely willing to pay if something will work properly) which I'm not be able to find or am not aware of?
Is the xPDL <-> jPDL translation really so problematic?
Thank you in advance for your help!
Pedro
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/585129#585129]
Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
13 years, 4 months
[Datasource Configuration] - MySQL problem with multiple instances of JBOSS
by Unmesh Kulkarni
Unmesh Kulkarni [http://community.jboss.org/people/unmesh_kulkarni] created the discussion
"MySQL problem with multiple instances of JBOSS"
To view the discussion, visit: http://community.jboss.org/message/584318#584318
--------------------------------------------------------------
I have setup two IPs on my machine.
eth0 Link encap:Ethernet HWaddr 00:0C:29:B3:6B:25
inet addr:192.168.6.128 Bcast:192.168.6.255 Mask:255.255.255.0
inet6 addr: fe80::20c:29ff:feb3:6b25/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:921323 errors:0 dropped:0 overruns:0 frame:0
TX packets:127221 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:721968842 (688.5 MiB) TX bytes:12898679 (12.3 MiB)
eth0:1 Link encap:Ethernet HWaddr 00:0C:29:B3:6B:25
inet addr:192.168.6.129 Bcast:192.168.6.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
I am starting up two instances of JBOSS AS 6.0.0 Final on the same server using -b option.
/etc/jboss-as/testenv1/bin/run.sh -c testenv1 -b 192.168.6.128
/etc/jboss-as/testenv2/bin/run.sh -c testenv2 -b 192.168.6.129
I have two databases, *testenv1* & *testenv2* on MySQL Server installed on same machine.
+--------------------+
| Database |
+--------------------+
| information_schema |
| mysql |
| test |
| testenv1 |
| testenv2 |
+--------------------+
Also I have two dedicated users testenv1 and testenv2 for connecting those databases.
+----------+---------------+
| user | host |
+----------+---------------+
| admin | % |
| root | 127.0.0.1 |
| *testenv1 | 192.168.6.128 |*
| *testenv2 | 192.168.6.129 |*
| | JBOSS-SS |
| root | JBOSS-SS |
| | localhost |
| root | localhost |
+----------+---------------+
They have been setup such a way that testenv1 user will have access to tesnv1 database from 192.168.6.128 and
testenv2 user will have access to testenv2 databse from 192.168.6.129.
I have attached datasource files which I am using.
Here is a code which i have deployed on both the servers for testing JDBC connectivity
<%
DataSource ds = null;
Connection con = null;
PreparedStatement pr = null;
InitialContext ic;
try {
ic = new InitialContext();
ds = (DataSource)ic.lookup( "java:/MySqlDS" );
con = ds.getConnection();
pr = con.prepareStatement("SELECT * FROM jdbctest");
ResultSet rs = pr.executeQuery();
while (rs.next()) {
out.println("<br> " +rs.getString("comp_inst_status"));
}
rs.close();
pr.close();
}catch(Exception e){
out.println("Exception thrown " +e);
}finally{
if(con != null){
con.close();
}
} %>
When I access my JSP from first instance (i.e. 192.168.6.128 ) it works fine but when I access it from other server it fails. It gives following exception
*Caused by: java.sql.SQLException: Access denied for user 'testenv2'@'**192.168.6.128**' (using password: YES)*
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1073) [:]
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3593) [:]
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3525) [:]
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:931) [:]
at com.mysql.jdbc.MysqlIO.secureAuth411(MysqlIO.java:4031) [:]
at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:1296) [:]
at com.mysql.jdbc.ConnectionImpl.coreConnect(ConnectionImpl.java:2338) [:]
at com.mysql.jdbc.ConnectionImpl.connectOneTryOnly(ConnectionImpl.java:2371) [:]
at com.mysql.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:2163) [:]
at com.mysql.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:794) [:]
at com.mysql.jdbc.JDBC4Connection.<init>(JDBC4Connection.java:47) [:]
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) [:1.6.0_23]
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) [:1.6.0_23]
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) [:1.6.0_23]
at java.lang.reflect.Constructor.newInstance(Constructor.java:513) [:1.6.0_23]
at com.mysql.jdbc.Util.handleNewInstance(Util.java:407) [:]
at com.mysql.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:378) [:]
at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:305) [:]
As the user testenv2 is not having access rights from *192.168.6.128* it throws exception.
But I have bound testenv2 instance on 192.168.6.129 but still it tries to access MySQL from 192.168.6.128.
Any idea if I am missing anything in configuration?
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/584318#584318]
Start a new discussion in Datasource Configuration at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
13 years, 4 months