mirror of
https://github.com/spring-projects/spring-petclinic.git
synced 2025-07-21 07:15:49 +00:00
format
This commit is contained in:
parent
28feaae451
commit
0aea5a67f4
5 changed files with 20 additions and 18 deletions
|
@ -59,5 +59,3 @@ public class PetClinicApplication {
|
|||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -12,6 +12,7 @@ public class PetVaccinationRequestMessage {
|
|||
|
||||
this.kafkaTemplate = kafkaTemplate;
|
||||
}
|
||||
|
||||
public void Send() {
|
||||
// template.convertAndSend("petVaccineRequests", "Hello, world!");
|
||||
kafkaTemplate.send("petVaccineRequests", "test");
|
||||
|
|
|
@ -94,11 +94,11 @@ public class OwnerValidation {
|
|||
}
|
||||
|
||||
String usr;
|
||||
|
||||
String pswd;
|
||||
|
||||
String sysCode;
|
||||
|
||||
|
||||
|
||||
@WithSpan
|
||||
private synchronized void AuthServiceValidateUser(Owner owner) {
|
||||
// This is the actual Root Cause!!
|
||||
|
|
|
@ -114,8 +114,8 @@ class OwnerController {
|
|||
}
|
||||
|
||||
@GetMapping("/owners")
|
||||
public String processFindForm(@RequestParam(defaultValue = "1") int page, Owner owner,
|
||||
BindingResult result, Model model) {
|
||||
public String processFindForm(@RequestParam(defaultValue = "1") int page, Owner owner, BindingResult result,
|
||||
Model model) {
|
||||
validator.ValidateUserAccess("admin", "pwd", "fullaccess");
|
||||
// if (owner.getLastName()!=null){
|
||||
// throw new RuntimeException();
|
||||
|
|
|
@ -50,6 +50,7 @@ class PetController implements InitializingBean {
|
|||
private static final String VIEWS_PETS_CREATE_OR_UPDATE_FORM = "pets/createOrUpdatePetForm";
|
||||
|
||||
private final OwnerRepository owners;
|
||||
|
||||
private final PetVaccinationRequestMessage vaccinationRequestMessage;
|
||||
|
||||
@Autowired
|
||||
|
@ -57,8 +58,7 @@ class PetController implements InitializingBean {
|
|||
|
||||
private ExecutorService executorService;
|
||||
|
||||
public PetController(OwnerRepository owners,
|
||||
PetVaccinationRequestMessage petVaccinationRequestMessage) {
|
||||
public PetController(OwnerRepository owners, PetVaccinationRequestMessage petVaccinationRequestMessage) {
|
||||
this.owners = owners;
|
||||
this.vaccinationRequestMessage = petVaccinationRequestMessage;
|
||||
}
|
||||
|
@ -115,11 +115,14 @@ class PetController implements InitializingBean {
|
|||
|
||||
// var petRequests = owner.getPets()
|
||||
// .stream()
|
||||
// .map(x -> new PetVaccinationStatusService.UpdateVaccineStatusRequest(owner.getId(), x.getId()))
|
||||
// .map(x -> new
|
||||
// PetVaccinationStatusService.UpdateVaccineStatusRequest(owner.getId(),
|
||||
// x.getId()))
|
||||
// .toList().subList(0,1);
|
||||
// executorService.submit(() ->
|
||||
// petVaccinationStatus.updateVaccinationStatus(petRequests)).get();
|
||||
//executorService.submit(() -> petVaccinationStatus.updateVaccinationStatus(petRequests));
|
||||
// executorService.submit(() ->
|
||||
// petVaccinationStatus.updateVaccinationStatus(petRequests));
|
||||
// petVaccinationStatus.updateVaccinationStatus(petRequests.subList(0,1));
|
||||
//
|
||||
|
||||
|
|
Loading…
Reference in a new issue