spring-mvc Questions
4
Solved
I have the below interface:
public interface MailSender {
void sender(String to, String subject,String body);
}
With 2 imlementation of it:
public class SmtpkMailSender implements MailSender {...
Subjoin asked 21/9, 2017 at 12:9
4
Solved
I have this class:
import org.springframework.security.core.userdetails.UserDetails;
@Entity
@Table(name="t_user")
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonIgnoreProperties(ignore...
Herries asked 19/4, 2021 at 17:0
2
For learning purposes, I have made a custom authentication system where I pass a token from the client to the server through the Authorization header.
In the server side, I'd like to know if it's ...
Touchdown asked 19/11, 2019 at 20:50
6
Solved
I am using the ReactiveElasticsearchClient from spring-data-elasticsearch 3.2.3 with spring-boot 2.2.0. When upgrading to spring-boot 2.2.2 i have got org.springframework.core.io.buffer.DataBufferL...
Barnum asked 13/12, 2019 at 16:23
1
I have the following Controller endpoint in my project:
@GetMapping(value = "/{id}")
public FooDto findOne(@PathVariable Long id) {
Foo model = fooService.findById(id)
.orElseThrow(() -...
Nutwood asked 6/1, 2023 at 10:46
29
Solved
When trying to convert a JPA object that has a bi-directional association into JSON, I keep getting
org.codehaus.jackson.map.JsonMappingException: Infinite recursion (StackOverflowError)
All I fou...
Hygrograph asked 24/7, 2010 at 14:0
4
according this answer I try to write my code:
pojo:
class MyBean{
public String getValueName() {
return valueName;
}
public void setValueName(String valueName) {
this.valueName = valueName;
...
Westnorthwest asked 2/9, 2015 at 22:24
6
So I have this code
import org.springframework.web.bind.annotation.GetMapping;
And I already have the following in my POM file
<packaging>war</packaging>
<properties>
<sp...
Singlefoot asked 7/9, 2017 at 4:30
3
I'm new inWireMock. I am running the WireMock server as a standalone process. I am able to mock simple rest api, by configuring json files under /mappings folder. Now, I want to mock a file downloa...
Segno asked 22/5, 2017 at 18:24
5
Solved
There is a RestFull method that return a List of Menu objects
public ResponseEntity<List<Menu>> getMenus() {
..
}
But I don't know how to get them from the RestTemplate, getting the ...
Statolatry asked 26/5, 2018 at 8:32
8
Solved
I am using Spring 3.2 and try to use an ajax post request to submit an array of json objects. If this is relevant, I escaped all special characters.
I am getting an HTTP Status of 415.
My contro...
Nicollenicolson asked 7/8, 2013 at 11:40
18
this is my first mybatis spring mvc application using spring 3.2.4, mybatis-spring-1.2.1
When i try to call my webservice i get the error::
org.springframework.web.util.NestedServletException: R...
Norton asked 6/12, 2013 at 15:9
4
I have developed a web application using SPRING MVC and JSP, now these applications work perfectly fine locally, but when I deployed on the server I am receiving this error. And nothing gets loaded...
Coincidence asked 19/7, 2015 at 17:0
16
Solved
I search some page in stackoverflow to solve this problem, did follow some true answer but not working. I am new in spring , sorry.
here is my dispatcher-servlet
<?xml version='1.0' encoding='...
Dunnage asked 3/11, 2014 at 23:40
2
Solved
Is there any way for insert a new record if doesn't exist and update the record if exist without losing old data?
This is my service layer method:
public void saveSample(Sample sample) {
Sample ...
Gagman asked 26/3, 2016 at 21:35
6
Why post construct does not get called without putting bean in applicationContext.xml
Here is my class which contains @PostConstruct annotation.
package org.stalwartz.config;
import javax.annot...
Millisent asked 29/3, 2016 at 14:32
3
Solved
I'm trying to append some text to a dynamic text as shown below:
<label th:text="Hello ${worldText}"></label>
But the UI throws:
TemplateProcessingException: Could not parse as expr...
Harrisharrisburg asked 8/9, 2017 at 14:38
4
Solved
I have some REST endpoints in my project which I call from a client application in another server. I have successfully disabled CORS using the @CrossOrigin annotation, and all the methods work fine...
Ers asked 2/4, 2017 at 9:53
15
Solved
I'd like to expose all IDs using a Spring Rest interface.
I know that per default an ID like this will not be exposed via the rest interface:
@Id
@GeneratedValue(strategy=GenerationType.IDENTIT...
Drury asked 18/6, 2015 at 10:26
4
Below is my DTO class.
public class AbstractDTO extends BaseDTO {
private Integer createdBy;
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = DATE_FORMAT)
@NotNull(message = "createdDat...
Barometer asked 1/10, 2019 at 10:8
7
I am having trouble trying to test a REST endpoint that receives an UserDetails as a parameter annotated with @AuthenticationPrincipal.
It seems like the user instance created in the test scenario ...
Lovemaking asked 12/7, 2016 at 13:40
2
Solved
I have the following jQuery AJAX request:
// collect form data and create user obj
var user = new User();
user.firstname = $("#usrFirstName").val();
user.lastname = $("#usrSurname").val();
user.r...
Gunboat asked 23/10, 2013 at 16:9
3
Solved
I have a simple Spring MVC application in which I want to handle all the unmapped urls using @ControllerAdvice.
Here is the controller:
@ControllerAdvice
public class ExceptionHandlerController {
...
Cursor asked 9/1, 2019 at 18:28
9
Solved
In my project I am uploading a file. While uploading, I am saving its original file name and extension in a database and saving that file with some GUID on server, generated GUID is also stored in ...
Periodical asked 2/4, 2013 at 10:40
33
Solved
I use Spring boot+JPA and having a problem while starting the service.
Caused by: java.lang.IllegalArgumentException: Not an managed type: class com.nervytech.dialer.domain.PhoneSettings
at org.h...
Mnemonics asked 22/2, 2015 at 22:28
© 2022 - 2024 — McMap. All rights reserved.