Needed Step by Step procedure to create tcp server-client using spring & eclipse - tcp

I am newbie to Spring framework and Spring Integration. As I went through Spring documentation http://docs.spring.io/spring-integration/reference/html/ip.html. I found hard to start. I would like to get the step by step procedure to write an application. Writing from *.xml file, running it, editing the stubs and working on the same.
Although I can see a lot of examples showing TCP /UDP client and server, for a newbie like me, its difficult.
Thanks in advance,
Velman R

See the tcp-client-server sample app that shows the use of both inbound and outbound gateways to invoke an echo service over TCP.
It uses the default CRLF to delimit messages; be sure to read the section about (de)serializers in the documentation.

Related

spring cloud stream multi binder setup - remote source kafka with local destination kafka possible?

I am trying to consume messages from a remote kafka and produce output to a local kafka setup.
Additionally I don't want to 'pollute' the remote Kafka with kakfa streams specific technical topics (e.g. intermediate KTable stores).
I created an example app for demo purposes, however this doesn't work as expected - and I cannot say why.
Not working means: I don't really understand what's going on. Multiple consumers are being created but all to locahost, none seems to point to the remote kafka.
https://github.com/webermich/multibinder
https://github.com/webermich/multibinder/blob/main/src/main/resources/application.yaml
So my qustions are:
Is my general understanding correct that I can build something like I described above?
If the answer to 1) is true: Can anyone spot my mistakes?
I am really unsure about the type: kstream of my bindings, too. I feel this is wrong.
Is there a link to a working example?

How do I disable Expect100Continue if I use BizTalk to communicate with a webservice?

An interface has as a requirement that we do not include an expect-100. (The documentation is assuming I will be using c# or php code to talk and has the code to not send the expect-100)
I quickly googled around a bit and found many topics on how to disable this when not using BizTalk and found multiple posts that would make me believe that BizTalk sends an expect-100 by default as well. (BizTalk Data Services: Extended to bring management functions through IUpdatable and Adding Custom HTTP Headers to messages send via HTTP Adapter.). I have had trouble in finding someone trying to disable it.
Since I have found the C# code to disable it, would a solution be to create a custom pipeline component that disables this?
This is not something I would worry about. I don't recall ever seeing Expect: 100- continue in any trace to or from BizTalk using WCF.
I will say that it is very strange that they would have a dependency on not seeing this. Either way, if WCF is sending it, you should be able to remove it with a Behavior.
You'll have to set this all up to even see if it's a problem. Here's where I say just try it and see what happens.

Migrating from IBM MQ to javax.jms.* (Weblogic)

I've been looking for days about how one could migrate from using IBM Websphere MQ to rather only using the QueueManager within Weblogic 10.3.x server. This would save cost of licenses for IBM MQ. The closest I came was finiding an external link which stated that IBM examples existed that did something similar(moving away from MQ to standard jms libraries), but when I attempted to follow the link: http://www.developer.ibm.com/isv/tech/sampmq.html
it lead to a dead page :\
More specifically I am interested in
What classes to use in my attempts to replace the following, com.ibm.mq.* classes:
MQEnvironment
MQQueueManager
MQGetMessageOptions
MQPutMessageOptions
and other classes which don't have an obvious javax.jms.* alternative.
Some of the nuances & work-arounds I may encounter in this migration process.
The database we are forwarding the queue messages to is Oracle 11 Standard (with advanced queuing) if that changes anything, so basically we are looking to "cut out the middle-man", so to speak. Your learned responses will be highly appreciated!
You seem to use the MQI api for MQ, to which there is no replacement at hand. There is no other way than to actually rewrite your MQ application logic to use the JMS API.
A good way might be to first migrate into JMS using the same WebSphere MQ server, since it allows you to verify your results in a reliable way.
You ask for what classes to replace say MQGetOptions with. There are no single 1-to-1 replacement (there are even some aspects of MQI that JMS cannot easily replace). Most of the MQPutOptions and other options are available by setting parameters on sessions and messages in JMS. You really need to understand the JMS api before trying this switch.
Then, when you have jms working with WebSphere MQ, you can do as Beryllium suggests, but swapping the libraries to Weblogic, switch any reference to com.ibm.mq.jms.MQConnectionFactory;, configuring the new parameters and pray to any a available god - press run :)
I have completed an application which supported both JBossMQ and MQSeries/WebSphere MQ.
The MQSeries specific classes I required were
import com.ibm.mq.jms.JMSC;
import com.ibm.mq.jms.MQConnectionFactory;
import com.ibm.mq.jms.MQQueueConnectionFactory;
import com.ibm.mq.jms.MQTopicConnectionFactory;
These were sufficient to create the javax.jms.QueueConnection/TopicConnection.
As for WebSphere MQ, I connected directly.
As for JBossMQ I looked up the factories using JNDI.
So on top of this there is only JMS.
So the first step is to rewrite your application so that only the initializing part uses WebSphere MQ specific classes (the ones I have listed above)
Replace the remaining MQ specific part with a JNDI/directory lookup for a queue connection factory provided by your application server
Remove the MQ series specific parts from your source.
Here is a simple example which shows how to send a message.

Send data to XDS Repository

So I'm trying to figure out how much capabilities comes with Intersystems to send data to an XDS repository. Specifically with using the basic Ensemble package (NO HSF) Assume it's not the one Intersystems delivers, but an external XDS repository.
Is there a built-in way to send a large blob and wrap the ebRim around that blob?
As you can see at http://www.intersystemsbenelux.com/media/media_manager/pdf/1398.pdf, Ensemble does not natively support ebRIM, but it does support XML and XML schemas.
Maybe you could assemble an XML and use that to wrap your blob content.
You can send that over whatever protocol your XDS system provides (xDBC, SOAP, file system etc). Take a look at the items listed on sections "Ensemble Interoperability" and "Ensemble Adapter and Gateway Guides" of http://docs.intersystems.com/ens20122/csp/docbook/DocBook.UI.Page.cls for a full list of connectivity options.
Regards,
There is healthshare foundation product which has XDS connectivity
See this good answer on google groups https://groups.google.com/forum/m/?fromgroups#!topic/Ensemble-in-Healthcare/h7R300H68KQ
Or healthshare part of their website
HSF (HealthShare Foundation) XDS.b connectivity for query and retrieve and also the Provide and Register Operation.
Ok, so I re-read your question and have an answer for you. I think what you are trying to say is that you have Ensemble, not HSF, and you still want to be able to send documents (XDS provide and Register).
I did some testing with the Open Source Integration mirth and stumbled across an example channel of theirs, and it is doing a provide and register with straight up SOAP calls to the end point.
Basically, build the required soap envelope accordingly, then send a PDF or document to the repository using MTOM.
This is what makes HealthShare its money, encapsulating all that manual construction of objects that need to be sent to endpoints.
Anyway, a screenshot of the Mirth channel destination make give you an understanding:
http://www.integrationrequired.com/wp-content/uploads/2013/02/Capture.PNG

Qt IPC - Named Pipes

I'm developing a qt browser plugin and want to implement named pipes in it. I tried the basic fortune cookie example provided with the QLocalSocket and QLocalServer in an exe and it works fine. But when i try to implement a similar thing in the browser plugin, making a page where the plugin is present listen to a name (like a server) and another tab/window which tries to connect to this. But this doesn't seem to work. When i do a client->errorString() it prints out "Unknown Error".
Any help on what I'm doing wrong?
Thanks a ton in advance
Put debug output to check the following things:
Has your client asked for a connection?
Has the server received a request to setup a connection?
Has each entity created it's QLocalSocket instance?
What does QLocalSocket::state() say on both entities?
Possible causes:
Have both of your code paths received cpu-time (seperate threads in the same process?)?
Is there a deadlock?

Resources