Khalid Habib

Ranch Hand
+ Follow
since Dec 22, 2012
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by Khalid Habib

Try Math.random();



OR just pass 50 in parameter then add 1

9 years ago
Thanks MR Marcel Friedmann

Let me try it on
10 years ago
I also have same problem
can any body guide us ?
10 years ago
Guys,
I have configured the JMS Queue and now when I try connect with JMS Queue it showing me following error.

here it's Code



INFO: SOME_FUTURE_MESSAGES_SUPPRESSED_CWSIU0005
javax.jms.JMSException: CWSIA0241E: An exception was received during the call to the method JmsManagedConnectionFactoryImpl.createConnection: com.ibm.websphere.sib.exception.SINotPossibleInCurrentConfigurationException: CWSIT0008E: A successful connection was made to the bootstrap server at localhost:7276:BootstrapBasicMessaging but the server returned an error condition: CWSIT0090E: A bootstrap request was made to bus MyBus using channel chain InboundBasicMessaging. Use of this chain is not permitted by bus MyBus..
at com.ibm.ws.sib.api.jms.impl.JmsManagedConnectionFactoryImpl.createConnection(JmsManagedConnectionFactoryImpl.java:195)
at com.ibm.ws.sib.api.jms.impl.JmsManagedConnectionFactoryImpl.createConnection(JmsManagedConnectionFactoryImpl.java:135)
at JMSClient.main(JMSClient.java:26)
Caused by: com.ibm.websphere.sib.exception.SINotPossibleInCurrentConfigurationException: CWSIT0008E: A successful connection was made to the bootstrap server at localhost:7276:BootstrapBasicMessaging but the server returned an error condition: CWSIT0090E: A bootstrap request was made to bus MyBus using channel chain InboundBasicMessaging. Use of this chain is not permitted by bus MyBus.
at com.ibm.ws.sib.trm.client.TrmSICoreConnectionFactoryImpl.generateException(TrmSICoreConnectionFactoryImpl.java:1004)
at com.ibm.ws.sib.trm.client.TrmSICoreConnectionFactoryImpl.remoteBootstrap(TrmSICoreConnectionFactoryImpl.java:638)
at com.ibm.ws.sib.trm.client.TrmSICoreConnectionFactoryImpl.createConnection(TrmSICoreConnectionFactoryImpl.java:307)
at com.ibm.ws.sib.trm.client.TrmSICoreConnectionFactoryImpl.createConnection(TrmSICoreConnectionFactoryImpl.java:222)
at com.ibm.ws.sib.api.jmsra.impl.JmsJcaConnectionFactoryImpl.createCoreConnection(JmsJcaConnectionFactoryImpl.java:711)
at com.ibm.ws.sib.api.jmsra.impl.JmsJcaConnectionFactoryImpl.createCoreConnection(JmsJcaConnectionFactoryImpl.java:647)
at com.ibm.ws.sib.api.jmsra.impl.JmsJcaConnectionFactoryImpl.createConnection(JmsJcaConnectionFactoryImpl.java:376)
at com.ibm.ws.sib.api.jms.impl.JmsManagedConnectionFactoryImpl.createConnection(JmsManagedConnectionFactoryImpl.java:162)
... 2 more
Caused by: com.ibm.websphere.sib.exception.SINotPossibleInCurrentConfigurationException: CWSIT0009W: A client connect to bus MyBus failed in the bootstrap server with endpoint localhost:7276:BootstrapBasicMessaging with reason: CWSIT0090E: A bootstrap request was made to bus MyBus using channel chain InboundBasicMessaging. Use of this chain is not permitted by bus MyBus..
at com.ibm.ws.sib.trm.client.TrmSICoreConnectionFactoryImpl.generateException(TrmSICoreConnectionFactoryImpl.java:1004)
at com.ibm.ws.sib.trm.client.TrmSICoreConnectionFactoryImpl.contactBootstrapService(TrmSICoreConnectionFactoryImpl.java:745)
at com.ibm.ws.sib.trm.client.TrmSICoreConnectionFactoryImpl.remoteBootstrap(TrmSICoreConnectionFactoryImpl.java:589)
... 8 more
10 years ago
Hi friends,
I am stuck for many days in configuring IBM MQ_Manager and Using that in java
I want configure a manager and que channels and then want use them through java, I also tried to configure in IBM Websphere Application server and then tried to connect through java but Zero Result
any body can help ..or provide me full manual or any tutorials

Regards
10 years ago

Dave Tolls wrote:So you need to get your web service method to handle uploading a file.
At the moment it isn't.
It simply accepts a String representing the path on the client.

You need to use (and I'm a little rusty here) MTOM. At least that used to be the thing.

Here's a ranch thread from 2011. H Paul's posts are the one's I would look at, at least for MTOM.



Thanks dear,
Let me try this then I will update
10 years ago

Paul Clapham wrote:Well, that's not the way to transfer a file to an FTP server. But my question remains: why are you using a file on your server at all?




Dear I have a Web application that accept attachment and that attachment goes to DB in form of clob and clob makes db Very heavy and app performance is becoming down day by day so I want resolve this issue, that's why seeking a alternate way in which I want store that attachment in a shared directory or any other place out of DB

Please suggest me. what is actual way to do this
10 years ago

Paul Clapham wrote:There's no point in uploading a file unless you are uploading it to some particular location. You didn't tell us where you want to upload the files to -- it looks like you haven't thought that through yet?

Wait a minute, I just reread your post; you said you wanted to upload to an FTP server. But I don't see any code to upload to an FTP server in what you posted there, instead you're uploading to a file. So why aren't you uploading to an FTP server in that code?




Dear Paul Clapham,
ftpUrl = String.format(ftpUrl, user, pass, host, uploadPath);
System.out.println("Upload URL: " + ftpUrl);


URL url = new URL(ftpUrl);
URLConnection conn = url.openConnection();
OutputStream outputStream = conn.getOutputStream();
in this code connecting with ftp server.
10 years ago
Guys
Actually my requirement is that ,I want create a web service that upload the file to ftp server which I have don but the main requirement is that it will be used from remote, means it will be used for uploading remotely from other systems, specified users will upload the files from their systems. so this program works fine at locally but when I try it remotely from other system it show me error that directory and file not found.
this web service will be uploaded on server. so user can access from server
guys please suggest me the way in which I do this .

Thanks in advance
10 years ago
Thanks lot dear friends,
Now I am using outputSteam instead of inputStream, File is being upload but when I open that file it contains no data, after uploading when I try to open it show me "The process cannot access the file because it being used by an other process"

here is new code
==========

10 years ago
Dear friends,
I am in tough time and I need your help,

This is a web service
When I run it locally in Web service explorer it works fine but when I it run from an other pc it showing me the error D:/test/File.txt (No such file or directory)

I run it from local pc like this http://localhost:Port/FileUpload/UploadServiceService?wsdl it works fine

but when I run it from other pc like this http://hostIp:Port/FileUpload/UploadServiceService?wsdl it bring me prompts in web service explorer but on submit it shows error


here is the code


10 years ago
Hi dear friends
I have requirement that I have to connect db2 from jndi
server is ibm websphere application server
10 years ago
Hi guys
I have created a web service in which I used db2 database
I am connecting this database by jndi datasource
when I try to run it is showing me following error

and here is code


javax.naming.NameNotFoundException: javax.naming.NameNotFoundException: "dbc/IBM_FORMS_DATA_SOURCE
10 years ago
<service name="HubUserService" >
<port name="HubUserServicePort" binding="tns:HubUserServicePortBinding" >
<soap:address location="REPLACE_WITH_ACTUAL_URL" />
</port>
</service>

I do I change this endpoint address
10 years ago
Thanks dear for quick reply

When I hit the URL from Browser it shows me the response
and when I check the wsdl from SOAPUI it showing me following error

Error 404: SRVE0295E: Error reported: 404
10 years ago