Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 8 years ago.
Improve this question
I'm developing a web service and as being new to the technology, I did a bit of research on the internet on the infrastructure software/technologies needed. Below are my findings and hope to get your precious opinion:
Application Server - Tomcat6
Web service engine - Axis2
Web service implementation - POJO
Accessing Database MySql - JPA (Only 5 simple tables)
Do they look good to you?
I'm thinking of using EJB3 for point3, but there are a lot of people on the internet (and this forum) saying EJB3 is not worth the effort, POJO will do. What's your view?
Thanks,
Sarah
Might be worth trying on programmers.stackexchange.com as its not specifically a coding question. For my 2 cents, I'd seriously consider whether you wanted to go down the SOAP route (Axis is SOAP only) or whether you should use REST.
Tomcat is usually a good choice for a server, as is MySQL for a DB. If you're going to use JPA, you need to choose a JPA implementation; the obvious one is Hibernate. If you do choose to use REST then I can recommend Jersey, which is Sun's reference implementation.
Related
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
I have started learning spring integration. As of now learnt that it provides features like transformers, filters etc
But I am not getting what can be practical use cases of spring integration. Say if I have to just transform java object to xml/json or vice versa.
Should I go ahead with spring integration . I think no as it can be achieved with their 3rd part libraries also . So what can be the use cases of
spring integration ?
Its very much used for enterprise integration.There are many theories and examples that you may have read. I can give you one scenario where we are currently using Spring integration.
We manage a business system in which we have to connect to different telecom operator with different kind service to get some information.Now some telecom operator uses email,soap based web service ,restfull webservice,Sockets ,ftp etc and all these we need to integrate our system. So we have one component which integrates with all the operator just by some simple configuration and very minimal codes.
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 8 years ago.
Improve this question
I have to create a RESTful web service. But, I was thinking for a generic RESTful web service for SOA. I don't know is it a good or bad idea for RESTful SOA.
How can I create generic web service which also satisfying REST concept.
Quite an endeavour.
At a first thought you would have to provide some kind of abstraction layer over the resources that you would typically expose. And that's just the API. Then you would have to execute custom logic for every resource you access.
The short answer is that it's not worth trying to figure out. Going with the typical solutions we have now is far better than over-generalising REST.
There is no one-size-fits-all.
I totally agree with #Gabriel Ruiu - "There is no one-size-fits-all."
But if you are thinking about building an API kind of thing (maybe a library) using which one could build RESTful Services easily, then you can generalize some of things and expose the features via your API.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 9 years ago.
Improve this question
I usually write my web services using PHP + Mysql, in a simplified way: reading the POST/GET params, connecting to the MySQL database and finally printing a JSON.
I'd like to check how to do this with a Java server, I've never programmed Java web servers and I'd like to know what should I study to learn to do it
Thanks
I'm supposing here that you have a good understand of java programming.
Fisrtly, I think you should understand java for web.
I recommend this book:
Head First Servlets and JSP
http://www.amazon.com/Head-First-Servlets-JSP-Certified/dp/0596516681/
Then you can learn web services with java:
Java Web Services: Up and Running
http://www.amazon.com/Java-Web-Services-Up-Running/dp/1449365116
Of course, there are many tutorials over the internet as well, but books give you a lot of background information.
I wanna suggest you garner understanding of the two main WebServices Architectures then decide which ones suit your case/use best
REST (GET,PUT,POST,DELETE,PATCH) JAX-RS
http://docs.oracle.com/javaee/6/tutorial/doc/giepu.html
vs SOAP bases JAX-WS
http://docs.oracle.com/javaee/5/tutorial/doc/bnayn.html
Comparing them:
Main differences between SOAP and RESTful web services in java
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
I want to learn Java WebServices. I read couple of articles on IBM developer works but I think I am getting confused about where to start. My main interest is Restful webservices. Where can i start from? I also prefer book with web service development example based on eclipse platform.
I always find very useful response from this site and always respect the people who responds to all these questions, so as always this time too I am expecting top answers.
Thanks a lot
The Spring Framework has great support for RESTful web services in java. It is a huge library for web development in Java so it might be a bit heavy handed. However, in my experience you eventually end up needing a lot of what's provided by Spring whether you plan on it or not.
http://static.springsource.org/spring/docs/current/reference/mvc.html
So with Spring Web MVC, you can create web controllers that handle requests in a really clean way, something to the effect of (but not tested for exact correctness):
#Controller
public class PetController {
#RequestMapping("/pets/{petId}")
public void findPet(#PathVariable String petId) {
// implementation omitted
}
}
In terms of learning about RESTful web service design, I'd suggest RESTful Web Services by Richardson, Ruby, DHH.
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 4 years ago.
Improve this question
I work for a mid-size financial company and we are trying to adapt an API driven architecture. We are developing APIs from the ground up using JEE container and the JAX-RS API like Jersey. I'll simplify and say that we have a website where you can manage your financial accounts and personal information. So for simplicity say I have an API:
/bank/accounts
/bank/accounts/{guid}
/customers/{guid}/
I have two potential types of users that can hit these services, the customer themselves and/or customer service representative. I'm wondering if anyone would like to share insight into the best way to secure such services. Do you even have the same services to serve both types of users?
In particular how do you ensure that the data that is being requested can be returned to the user requesting the information.
I think RolesAllowed works great if the check is as simple as "does this user have access to call the API". How do you ensure that user 1 can't see user 2's data. Is there a best practice? What are others doing?
I did happen to come across this which does address what I'm thinking. This was answered in 2009, so I'm wondering if there are other alternatives 6 years later.
JAX-RS access control