Hi,
I am getting JSon response once some error encounter.Once this json link received the user have to click that link and after clicking new page will be opened which will have radio button that will be selected by user and submitted.This is the requirement.
Hello,
But in jax-rs jersey i was able to do it using exceptionmapper class.There using HAETOS i was able to make json link clickable but in rest spring i am not.
Hello,
I am working wit spring rest.On some error condition in json response i am sending link.But in browser it is not clickable it is in string from.Following is my code
Controller:
@RequestMapping(value="/sendmail", method=RequestMethod.GET)
public ResponseEntity<ConsentManager> home(Locale locale , Model model,HttpServletRequest request){
boolean status=mailService.sendMail("[email protected]", recipantEmail , "Welcome To Fashioniesta Fashion Store", "Hello"+ " "+customerName+ "\n\n"+ "You Have been successfully registered with Fashioniesta.com."+"\n\n"+"Thanks,"+"\n"+"Team Fashioniesta.");
if(!status){
System.out.println("Inside Fail");
try {
throw new ConsentException("Error Occured While sending mail");
} catch (ConsentException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
return new ResponseEntity<ConsentManager>(cm, HttpStatus.OK);
}
@ExceptionHandler(ConsentException.class)
public ResponseEntity<ConsentErrorResponse> exceptionHandler(Exception ex) {
ConsentErrorResponse error = new ConsentErrorResponse();
error.setErrorCode(HttpStatus.PRECONDITION_FAILED.value());
String uri=ServletUriComponentsBuilder.fromCurrentContextPath().path("/my/additional/path").build().toUriString();
Link link = new Link(uri);
error.setMessageLink(link);
return new ResponseEntity<ConsentErrorResponse>(error, HttpStatus.OK);
}
After getting SMTP error i am sending json error response with link.But in browser it is nor clickable.Can anybody let me know where i am making mistake.
Hi,
Actually some other application is accessing my application through entering URL of my application in browser.I want to know IP of that machine who is accessing my application.
Hi,
I am calling application which is on remote machine.I want to retrieve IP of remote machine in my java application.Can anyone tell me how i will be able to retrieve IP of remote machine.
Hi,
In my WebService i am passing two parameter to query.I tested with more than 3000 parameters(UCN,OrderId).Query is executed with all the passing parameters(UCN,OrderId) but with 6 (UCN,OrderId) the resultset don't have any records(size=0).If i am running the same query on SqlDevloper with 6(UCN,OrderId) it is giving the result but inside JDBC resultset is empty.Can anyone tell me where i m wrong .
Hi,
I am a java devloper and query is written by some oracle guy.I asked oracle guy to give me view and SCHL_ORDER_DETAILS_V is a view.After so many effort of optimization he was not able to reduce the time.I write this query to fetch required data from view.Since he is not able to optimize query thats why i am optimizing the view query.Oracle guy is absent since one week and its urgent thats why i am optimizing my view query.
Hi,
The query is about fetching billing address,shipping address,total order summary(total amt,total tax,total discount) and all the line items associated with that orderid.In sql devloper it is talking 1.5 sec to 2 sec.But clients requirement is .3 msc.
Hello,
I have the following query which is taking time to execute.I think it is due to GroupBy.Can anybody modify this query and execute query without using GroupBy but the output result should be same.I am not able to do it.