Questions tagged [spring-mvc]
The spring-mvc tag has no summary.
53 questions
0
votes
0
answers
300
views
better structure of a software project to prevent circular dependencies
I am contacting you today regarding a recent problem with circular dependencies. It's about a Spring boot application that accepts data via a Rest API and then forwards it to an internal Spring ...
0
votes
3
answers
2k
views
In which scenarios is server-side rendering is better choice than the front-end JS libraries like React, Vue, Angular etc.?
As a Java developer, I just have scratched the surface of Javascript libraries like React, Angular, Vue etc. It seems that theoretically any web applications with server side rendering, like Spring-...
0
votes
1
answer
111
views
Where Should You Add a Shared Maven Module as a Dependency in an N-tier Architecture
In a simple web architecture using Spring and Maven where it consists of following layers:
Controller
Service
Repository
Shared
Where in shared module all the classes that are used among different ...
2
votes
1
answer
159
views
What should I name this area of my architecture?
I am developing an architecture for a new MVC system. The legacy system has a layer it calls "facade", but it is not the classic GoF Facade. It is more like a service aggregator. It is used as a ...
1
vote
1
answer
821
views
JHipster generated endpoints adds header messages
I'm adding new functionality to an existing application it was done using JHipster.
I've notice that some endpoints follow this pattern:
return ResponseUtil.wrapOrNotFound(updatedUser,
...
1
vote
1
answer
229
views
Spring Boot Controller Unit Test Strategy
All of the controllers in our project are as dumb as we can make them. Rightfully so, they simply validate the incoming payload, hand the request over to a service layer, and return whatever response ...
2
votes
1
answer
527
views
Strategy to deal with huge data
I have a Spring based java webservice which is returning JSON response. The problem is that the JSON response takes long time because the SQL involved is querying huge chunk of data and it takes 4-5 ...
8
votes
1
answer
8k
views
Implementing a REST API in a Clean Architecture
I have been implementing a proof of concept application using Uncle Bob's Clean Architecture and I have run into a bit of a problem.
Uncle Bob's architecture calls for the explicit separation of ...
9
votes
1
answer
14k
views
Data Objects for each layer(DTO vs Entity vs Response objects)
Let's say I'm building a Customer web application(in Spring Boot 2), which also exposes rest end points. I'm modeling my application into 3 layers.
a) UI - CustomerDTO
b) REST - ...
7
votes
2
answers
8k
views
Localization (i18n) with Spring boot with data in database
I am writing a Spring boot app with Thymeleaf, which should support two languages (or more). I have set up the locale resolver and messages.properties so now my app can translate static messages on ...
4
votes
1
answer
4k
views
DTO can be considered as Business objects (with behavior)?
Based on this Question and its answer :
Object in Business layer same as DTO with logic?
I want to ask :
What if instead of DAL, I'm getting data from a remote service (API) through DTOs. My ...
2
votes
1
answer
1k
views
Is the Model in Spring MVC the same of MVC pattern?
Studying some in-depth concept of Spring framework, I'm facing this doubt.
Has the Model, as inteded in Spring MVC, the same meaning of the M in MVC?
I mean: I always considered the Model of the MVC ...
3
votes
0
answers
79
views
How to wireup the Edit Functionality of a Entity and make REST API when it contains Dropdown Values
I am having a scenario wherein we have a Product Entity or a Front End Module which can be Added, Edited and Deleted.
Now Product ( when added or edited) can contain a Dropdown called as ...
2
votes
1
answer
393
views
Advantages and disadvantages of building web app purely with microservices and hybrid with web framework
Definition:
Purely microservice: Not using any web framework such as Spring, Laravel, Zend, Django. Web app is a single page app loading data via Ajax calls to web services
Hybrid: The web framework ...
2
votes
1
answer
3k
views
Handling validation/exception responses in rest-ful app
So I am facing a problem with handling all sorts of exceptions within spring-boot application. Basically project is structured:
back-end (services, repositories) <----- RestControllers <---- UI ...
1
vote
1
answer
140
views
Details of how model implemented in Spring MVC?
It seems to be the view and controllers are rigidly defined, but the model is highly nebulous. For instance, views go in views folder, controllers have the word controller in their name and have ...
0
votes
1
answer
858
views
Is it a Good Idea to use REST API from Javascript Code
I am Developing a E-Commerce Web Application as a part of my learning using Spring Hibernate and AngularJs.
I have written some Rest API's Controllers in Spring and then from the Web Component i am ...
1
vote
0
answers
100
views
Creating duplicate instances of objects for timeline functionality
I am working on a Spring-MVC based project, in which I would like to add Timeline functionality. The most important object in our project is the Note, there are objects associated with it like ...
2
votes
2
answers
4k
views
What should be the best way to run a long operation in Java Spring?
I am working on a price comparator, one of the module of application crawls through the list of website against the product stored in the database and updates the price in the application database.
...
5
votes
2
answers
2k
views
Simple and Composite transactional services: Question about separation of concerns and transactions
I believe I know the answer to this but I'm looking for any holes or anything I may be missing.
This is focused on Spring and Java but could really apply to any programming stack.
Anyway, we have a ...
0
votes
1
answer
1k
views
Spring web application deployment infrastructure
I'm interested in hearing out what's out there in terms of tips and tricks on deploying and maintaining a Java web application whilst keeping agile. I'm running solo on a startup project I'd like to ...
3
votes
2
answers
553
views
blurry lines between web application context layer, service layer and data access layer in spring
I'll admit I'm a spring newbie, but you can correct me if I'm wrong, this one liner looks kinda fishy in a best practices sort of way:
@RepositoryRestResource(collectionResourceRel="people"...)
...
8
votes
1
answer
6k
views
Passing multiple errors back from service layer
I am using Spring for a web application. To validate a user's input in a form such as for creating a Person entity I use JSR 303 validation to check for not null/empty or valid patterns etc.. Some ...
1
vote
1
answer
5k
views
RequestContextHolder.currentRequestAttributes() and accessing HTTP Session
Need to access HTTP session for fetching as well storing some information.I am using Spring-MVC for my application and i have 2 options here.
User Request/ Session in my Controller method and do my ...
1
vote
0
answers
902
views
How to integrate google search results in a spring mvc app
Here's what am trying to do (and searching for similar hasn't shown any results anywhere):
On my website - provide an input box which will search google for results. I want to display those results ...