August 28, 2020

Swagger- api in spring boot


@ApiModel(value = "UserDTO", description = "User Data Transfer Object description")
public class UserDTO {



@ApiModelProperty(value="user ID",position = 0 , hidden = true)
private String userId; 

August 21, 2020

Web hooks - the Reverse APIs

Web hooks provide a mechanism where by a server-side application can notify a client-side application when a new event (that the client-side application might be interested in) has occurred on the server.

Reverse APIs

August 14, 2020

Java8: Stream merge two lists

/**
 * id 53481363
 */
package com.konzern.eight;

import java.util.ArrayList;
import java.util.List;
import java.util.stream.Collectors;

/**
 * @author Chippu
 *
 */
public class MergingList {

public static<T> List<T> merge(List<T> one, List<T> two){
List<T> list = one.stream().collect(Collectors.toList());
list.addAll(two);
return list;
}

/**
* @param args
*/
public static void main(String[] args) {
// TODO Auto-generated method stub

List one = new ArrayList<>();
one.add(1);
one.add(2);
one.add(3);
List two = new ArrayList<>();
two.add(4);
two.add(5);
two.add(6);
System.out.println(MergingList.merge(one, two));

}

}

August 07, 2020

Spring boot failed Field customAuthProvider in SecurityConfig required a bean of type 'AuthProvider' that could not be found.

Description:

Field customAuthProvider in com.proximotech.zhw.WebServiceAuthProviderSecurityConfig required a bean of type 

'com.proximotech.zhw.WebServiceAuthenticationProvider' that could not be found.

The injection point has the following annotations:
- @org.springframework.beans.factory.annotation.Autowired(required=true)


Action:

Consider defining a bean of type 'com.proximotech.zhw.WebServiceAuthenticationProvider' in your configuration.

Solution:
Annotation @component missing in the class
com.proximotech.zhw.WebServiceAuthenticationProvider

Facebook comments