M Kethi

Greenhorn
+ Follow
since Aug 01, 2008
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by M Kethi


I have to use an existing Model object Test in my HelloAction.

The Test object has array list of Object XYZ.

I am able to display the properties of Test object as well as the properties of XYZ object on my hello jsp.

The problem is those properties are editable and I have to get the new values of the properties of Test and XYZ after editing.

How do I do that .??
9 years ago
an object X has an array list xyzList.

getXyzList() returns an array of objects Test

public Test[] getXyzList() {
}

The object Test() contains variables name and setting.

how do I loop through the xyzList to display values of name and setting

I tried the below ..seems like thats not the way to do. any help is appreciated.

Thank you ..

<s:iterator id="xyzLst" value="X.xyzList" status="alertSetting">

<tr>
<td><label>Setting Name:</label></td>
<td> <s:textfield value="%{#xyzLst[%{#alertSetting.index}]}"></s:textfield> </td>

</tr>
</s:iterator>
9 years ago
Okay ..

I had the same problem with double select as i did with select ..
i need to find a way to populate the second dropdown with values of the arraylist ( value of the map)
not sure how I can accomplish ..
9 years ago
I tried that ...it dint work out ...
9 years ago

I have a map of type ..
HashMap<String, List<String>>();

key - id1
value - List of value1,value2,value3

key - id2
value - List of value3,value4,value5

I am not sure how to represent them on two drop downs.

first drop should show id1, id2
second drop down should show value1, value2, values3 or value3,value4,value5
depending on what was selected on first drop down..

I am successful to some extent using map.entrySet as the list..

first drop down key
second drop down as value ..

but thats not the exact way i want ..cos on second drop down it shows values as lists [value1, value2, values3 ] [value3,value4,value5] .

any suggestions please ..i wasted almost a day ..already. ..

9 years ago

I have a List list1 of objects "test" - type
test object has id1 and id2 .

I will need to populate 2 drop downs
drop down 1 with id1 and drop down 2 with id2.

am able to do it with listValue.

the problem is id1 can be same value on multiple objects of the list and same with id2

so, how do i show unique values instead of repeating the same value..

also, if i select id1 from drop down 1 then the respective values of id2 on drop down 2 should be populated and vice versa..

not sure how to accomplish this. any help is greatly appreciated.
9 years ago
WE recently did an upgrade from WAS 5 to WAS 6.. see the below errors ..any help is greatly appreciated...

Exception processing JMS Message for MDB PublishService1, JMSDestination jms/PubQueue1 :
javax.ejb.TransactionRolledbackLocalException: ; nested exception is: com.ibm.websphere.csi.CSITransactionRolledbackException: Transaction marked rollbackonly
com.ibm.websphere.csi.CSITransactionRolledbackException: Transaction marked rollbackonly
at com.ibm.ejs.csi.TranStrategy.postInvoke(TranStrategy.java:202)
at com.ibm.ejs.csi.TransactionControlImpl.postInvoke(TransactionControlImpl.java:590)
at com.ibm.ejs.container.EJSContainer.postInvoke(EJSContainer.java:3986)
at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java:107)
at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java:132)
at com.ibm.ejs.jms.listener.ServerSession.run(ServerSession.java:535)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1497)
javax.ejb.TransactionRolledbackLocalException: ; nested exception is: com.ibm.websphere.csi.CSITransactionRolledbackException: Transaction marked rollbackonly
at com.ibm.ejs.csi.TranStrategy.postInvoke(TranStrategy.java:202)
at com.ibm.ejs.csi.TransactionControlImpl.postInvoke(TransactionControlImpl.java:590)
at com.ibm.ejs.container.EJSContainer.postInvoke(EJSContainer.java:3986)
at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java:107)
at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java:132)
at com.ibm.ejs.jms.listener.ServerSession.run(ServerSession.java:535)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1497)
Caused by: com.ibm.websphere.csi.CSITransactionRolledbackException: Transaction marked rollbackonly


[6/7/10 9:58:10:282 CDT] 0000002a XATransaction E J2CA0026E: Method addSync caught javax.transaction.RollbackException: Transaction rolled back
at com.ibm.ws.Transaction.JTA.TransactionImpl.registerSynchronization(TransactionImpl.java:3548)
at com.ibm.ws.Transaction.JTA.TransactionImpl.registerSynchronization(TransactionImpl.java:3527)
at com.ibm.ws.Transaction.JTA.TranManagerSet.registerSynchronization(TranManagerSet.java:515)
at com.ibm.ejs.j2c.XATransactionWrapper.addSync(XATransactionWrapper.java:290)
at com.ibm.ejs.j2c.ConnectionManager.initializeForUOW(ConnectionManager.java:1340)
at com.ibm.ejs.j2c.ConnectionManager.involveMCInTran(ConnectionManager.java:1065)
at com.ibm.ejs.j2c.ConnectionManager.allocateConnection(ConnectionManager.java:613)
at com.ibm.ejs.jms.JMSQueueConnectionHandle.createQueueSession(JMSQueueConnectionHandle.java:209)
at com.caremark.emp.service.delegate.SendToQueueService.sendMessage(SendToQueueService.java:88)
at com.caremark.emp.service.delegate.XMLMessageServiceDelegate.sendJMSMessage(XMLMessageServiceDelegate.java:167)
at com.caremark.emp.service.delegate.XMLMessageServiceDelegate.sendMessageToErrorQueue(XMLMessageServiceDelegate.java:159)
at com.caremark.emp.service.evtpub.ealert.EAlertEventPublishServiceImpl.service(EAlertEventPublishServiceImpl.java:74)
at com.caremark.emp.common.mdb.AbstractCmpSpringMessageDrivenBean.onMessage(AbstractCmpSpringMessageDrivenBean.java:48)
at com.ibm.ejs.jms.listener.MDBWrapper$PriviledgedOnMessage.run(MDBWrapper.java:302)
at com.ibm.ws.security.util.AccessController.doPrivileged(AccessController.java:63)
at com.ibm.ejs.jms.listener.MDBWrapper.callOnMessage(MDBWrapper.java:271)
at com.ibm.ejs.jms.listener.MDBWrapper.onMessage(MDBWrapper.java:240)
at com.ibm.mq.jms.MQSession.run(MQSession.java:1695)
at com.ibm.ejs.jms.JMSSessionHandle.run(JMSSessionHandle.java:1040)
at com.ibm.ejs.jms.listener.ServerSession.connectionConsumerOnMessage(ServerSession.java:1030)
at com.ibm.ejs.jms.listener.ServerSession.onMessage(ServerSession.java:710)
at com.ibm.ejs.jms.listener.ServerSession.dispatch(ServerSession.java:677)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:79)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:618)
at com.ibm.ejs.jms.listener.ServerSessionDispatcher.dispatch(ServerSessionDispatcher.java:44)
at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java:96)
at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java:132)
at com.ibm.ejs.jms.listener.ServerSession.run(ServerSession.java:535)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1497)
9 years ago
dear ranchers

i have to print data to multiple columns using a logic iterate

for eg: the below code would print the same data on each column...
i'd like to see the values for the arraylist like a matrix..

1 2 3
4 5 6
7 8 9

rather than

1 1 1
2 2 2
3 3 3
4 4 4

can anyone suggest how can i achieve this ?


<logic:iterate id="myCollectionElement" collection="<%=drugsList %>" >
<tr>
<td bgcolor="#E9E9E9">
<html:radio property="selectedDrug" value="" /><bean:write name="myCollectionElement" />
</td>
<td bgcolor="#E0E0E0">
<html:radio property="selectedDrug" value="" /><bean:write name="myCollectionElement" />
</td>
<td bgcolor="#E9E9E9">
<html:radio property="selectedDrug" value="" /><bean:write name="myCollectionElement" />
</td>
</tr>
</logic:iterate>
10 years ago
yes. I created a custom exception and my service method throws that custom exception. my client method catches that exception. I am able to get the message i sent. but, when i run the client, it logs the remote exception as well bcos of the checked exception thrown by the server. how could you prevent that?
public java.util.Vector getParticipant(int id) throws java.rmi.RemoteException, CustomException

let me know if i am right

thanks
MK
11 years ago
http://www.theserverside.com/tt/articles/article.tss?l=Systinet-web-services-part-2

something like this...
but it doesn't work for me...
the message is not being propagated to the client side...
11 years ago
Thankq again..

I am working on it. Creating a Custom exception. Will let you if that works. Keep checking.
11 years ago
Thankyou for your inputs.

I was talking about checked exceptions. If not showing the actual message, atleast show that an exception occurred? Suppose, if there is a jdbc connection failure, I would catch that exception at the server side. But at the same time I want to pass a message to the client that an exception occured. If I dont do that, all the checked exceptions caught at the server side, are turned to Remote exceptions at the client side. And the developer writing the client code would see it as a remote exception no matter what kind of exception was caught at the server side.
If I am not very clear please refer to the below text.

"Exceptions could be thrown inside a Web Service for various reasons. The possible types of exceptions that could be thrown are RuntimeException, RemoteException, SOAPFaultException and User Defined Exception.

The Web Service developer might try throwing a RuntimeException such as NullPointerException or ArrayIndexOutOfBoundsException inside the Web Service. But, throwing RuntimeException inside the Web Service is considered to be a bad exercise because RuntimeException will always be converted into RemoteException at the client side. While the client is waiting to catch the RuntimeException after invoking a Web Service, he will get only the RemoteException instead of RuntimeException. Eventually, he cannot perform proper error handling for RuntimeException."


Also, I am the person who has to implement the service as well as the client. Suppose, if the service is down, how should I handle it at the client side.

Thanks,
MK.
11 years ago
I am creating a webservice using the tool( WSAD 5).
I am not sure how to pass on the Exception caught at the server side to the client. Suppose I catch an 'GenericJDBCException' on the server side. How can I send the message to the client? So the client would know what Exception was caught and act accordingly.

Thanks,
MK.
11 years ago
Hi,

I am kind of new to webservices. I am trying to use WSAD 5 tool to develop a webservice.
The tool gives three different ways of creating a webservice. Apache Axis, IBM WebSphere V5
and IBM SOAP. From my understanding Apache Axis is from Apache ( open source, hence IBM does
not provide any support.), IBM SOAP from IBM, IBM WebSphere V5 also from IBM. However,
I am not very clear on the whole concept yet. Can anyone please give a more clear picture?
Also, what is the difference between IBM WebSphere V5 and IBM SOAP?
Also, what is the difference between Document/ Literal, RPC/ Literal and RPC/ Encoded.

Thankyou in advance,
KK.
11 years ago