Class GetAllCollectionsServiceImpl
java.lang.Object
com.skava.oms.service.EcommCoreServices
com.skava.oms.service.collection.CollectionHelperServices
com.skava.oms.service.collection.impl.GetAllCollectionsServiceImpl
- All Implemented Interfaces:
com.skava.core.EcommService<GetAllCollectionsRequest,
,OmsServiceEntityResponse<CollectionsResponse>> GetAllCollectionsService
,CustomEcommService<GetAllCollectionsRequest,
OmsServiceEntityResponse<CollectionsResponse>>
@Service
public class GetAllCollectionsServiceImpl
extends CollectionHelperServices
implements GetAllCollectionsService
This class is used to get all the collections.
GetAllCollectionsServiceImpl
- Since:
- 07-Jul-2018
- Author:
- Infosys Equinox
-
Field Summary
Fields inherited from class com.skava.oms.service.collection.CollectionHelperServices
authHelper, bpmService, collectionAssembler, collectionAttributeAssembler, collectionAttributeRepository, collectionPropertiesAssembler, collectionRepository
Fields inherited from class com.skava.oms.service.EcommCoreServices
context, messageSource, orderService, redissonClient, validator
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionList<com.skava.core.validation.ValidatorComponent>
void
init()
The method is initially called to set the validators The validators needed for the patch order will be presentmethodFallback
(GetAllCollectionsRequest request) Circuit breaker fall-back method monitors for failures and once failures reach certain threshold, the circuit breaker trips and returns error response accordingly.process
(@Valid GetAllCollectionsRequest request) This method is used to load all Collection based on given Collection.Methods inherited from class com.skava.oms.service.collection.CollectionHelperServices
checkForDuplicateName
Methods inherited from class com.skava.oms.service.EcommCoreServices
createOrderNotes, getItemIds, getItemIdsStr, updateOrderNotification
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.skava.oms.service.CustomEcommService
getValidateException
Methods inherited from interface com.skava.core.EcommService
getValidator
-
Constructor Details
-
GetAllCollectionsServiceImpl
public GetAllCollectionsServiceImpl()
-
-
Method Details
-
init
@EventListener(org.springframework.boot.context.event.ApplicationReadyEvent.class) public void init()The method is initially called to set the validators The validators needed for the patch order will be present -
getValidator
- Specified by:
getValidator
in interfacecom.skava.core.EcommService<GetAllCollectionsRequest,
OmsServiceEntityResponse<CollectionsResponse>>
-
process
@HystrixCommand(commandKey="oms-key", fallbackMethod="methodFallback", ignoreExceptions={com.skava.core.validation.ValidateException.class,OmsServiceException.class}) public OmsServiceEntityResponse<CollectionsResponse> process(@Valid @Valid GetAllCollectionsRequest request) This method is used to load all Collection based on given Collection. It throws error if the given collection id is not valid It will get all the collections Debug log has been added- Specified by:
process
in interfacecom.skava.core.EcommService<GetAllCollectionsRequest,
OmsServiceEntityResponse<CollectionsResponse>> - Parameters:
request
- It contains the attributes required for the load all Collection.- Returns:
- It returns the
CollectionsResponse
. It will throw Ecommerce exception if it process get failed.
-
methodFallback
public OmsServiceEntityResponse<CollectionsResponse> methodFallback(GetAllCollectionsRequest request) Circuit breaker fall-back method monitors for failures and once failures reach certain threshold, the circuit breaker trips and returns error response accordingly.- Parameters:
request
- Instance ofGetAllCollectionsRequest
- Returns:
- Instance of
OmsServiceEntityResponse
-