I am working with project and I need to create jar file which needs to bind to AIDL Service that can communicate with other apps.
Is it possible? or if not what could be the best way?
Related
I want to know how to deploy two different .jar files on the same port using Jenkins.
The two .jar files is build by Jenkins, i just want to know if there are any better options than re-doing the projects to build .war files and deploy them using a single Tomcat container?
edit:
The reason i'm asking the questions is because i'm building a webapp using multiple microservices, therefor i'm interested in how to do this with "best practice".
It sounds like what you want is a common point of access that your clients can use to access your services. You can achieve this by creating an API gateway service that routes requests to the correct service. Your original two services listen on different ports, but your client only has to know about the API gateway endpoints, the API gateway itself will route the requests.
Have a look at Spring-cloud-zuul or this tutorial to see how to do this.
I am developing a Windows Service that uses TCP/IP to communicate with their clients.
So i create a project for the service using Maven. Now i need to create a client to comunicate with this service. Is it better to create another project or a module? Or create it inside the Windows Service project?
For development purposes it easier to create another module. First, its easy to view both client and server code in the IDE without having to close and open projects. Second, common code can be placed in another module, which makes easier to code and debug.
I'm trying to implement an interface that needs to be implemented by the server but also the client. I am making an RMI server/client system where the client should call the server, and get a value from the server.
It should be a "Remote Interface" between the server and client but i have problems implement it in my server and client programs.
Have made 3 projects in Eclipse
Projekt 1 (Server)
Projekt 2 (Client)
Projekt 3 (Remote Interface)
I want a class inside the Server project named DataImpl to implement the Remote Interface. Have tried to add a JARS in my Server libraries but it dosnen't work.. have these options:
So if i add them, and go to the DataImpl class inside the server, i still wont implement DataI. Here is the options, but they are all wrong.
Hope someone know what the problem is, and what i am doing wrong :)
I found the answer myself..
You should add the project
In the build path --> Project --> Add --> Choose it!
Is the project with the interface on the classpath for the project you want to use it in? If it is, implementing it the way you are doing it is correct.
This scenario is just like any other jar file in the class path. One project is including the other project in its classpath and then uses it.
I want to write an Android app that is able to communicate with an application on a server pc, using java sockets.
I have created few classes that implement the Serializable interface, in order to send them through socket as protocol.
The problem is that I have to create two projects in Eclipse, one for the server application and one for the android app. So, I should create a duplicate of those protocol classes in order to use them in both projects.
Is that right? Is there a kind of "import project into another project" so that I can keep those protocol classes in a third project and import it in my android app and server application?
Thank you.
You don't actually need to create a separate Eclipse project for the shared classes. You can just create a 'common source folder' outside of the other two projects' disk hierarchy. For both the server and client projects. In the Properties/Java Build Path/Source add a 'Link source' to the new folder.
I am using Play framework 1.2.5 in my application in Eclipse IDE. I need to access a web service built using IBM JAX-RPC. I have got the wsdl file of the web service which I need to access in my applicatiom.
For normal Java EE applications, I used to paste the WSDL in my workspace, generate the files by right clicking the WSDL file => Generate Client option i.e. generating files with the help of Eclipse IDE.
I am not sure how to access the WSDL using Play framework.
I want to know:
1) Where to paste the WSDL file in my workspace?
2) In Play framework how do generate the client (Not sure even if we need this or not in play framework) and access the service methods?
3) Any additional settings needed for accessing the service methods?
Please let me know about this.
Regards,
The easy way:
Use Play!'s built-in play.libs.WS (Link #2 and #3). You have to create the raw HTTP requests yourself, and parse the XML result from the server yourself. Of course, this can become a complex task, if the web service interface is complex.
Preferably, you will create a JAX-RPC client based on your WSDL, and use it from your Play! application.