SSL error with entity core
Or malformed SQL, it varies...
I have web api that access and database using entity core. I have an angular frontend. If I call my endpoints invidually, or successively, it works fine. But for some reason when I do something like this:
let patientsObs = forkJoin(neededPatientId.map(id => patientService.getPatientById(id))).pipe(defaultIfEmpty([]));
let doctorObs = forkJoin(needDoctorId.map(id => doctorService.getDoctorById(id))).pipe(defaultIfEmpty([]));
return combineLatest([patientsObs, doctorObs]).pipe(
where neededPatientId and needDoctorId are arrays if integers, the backend throws an exception.
But when i get the patientObs first, and then the doctorObs, it works fine3 Replies
I realise this is related to angular as well, but the issue is a c# backend issue
I get errors like:
AuthenticationException: Authentication failed because the remote party sent a TLS alert: 'IllegalParameter'.
and
Win32Exception: The message received was unexpected or badly formatted.
My AddDbContext@:
builder.Services.AddDbContext<MedTrackContext>(options =>
// options.UseInMemoryDatabase(builder.Configuration.GetConnectionString("MedTrackDashInMemoryDb"));
options.UseMySql(connectionString,
ServerVersion.AutoDetect(connectionString),
options => options.EnableRetryOnFailure(
maxRetryCount: 5,
maxRetryDelay: System.TimeSpan.FromSeconds(30),
errorNumbersToAdd: null)
));
The services injected into the controllers:
builder.Services.AddTransient<IPatientDatabaseService, PatientDatabaseService>(); builder.Services.AddTransient<IDoctorDatabaseService, DoctorDatabaseService>(); builder.Services.AddTransient<IAppointmentDatabaseService, AppointmentDatabaseService>();I think the SSL Authentication Error is a redherring because it works just fine, even from the front end, when I make calls not using my angular snippet
GitHub
TLS Handshake error: `Win32Exception: The message received was unex...
Description While trying to make a Client integration with a server through Mutual TLS we got this error: System.Net.Http.HttpRequestException HResult=0x80131501 Message=The SSL connection could no...
Introduced controller methods getByIds(List<int> ids) to solve/avoid this problem. Couldn't seem to increase the size
Don't know why it causes an issue otherwise - I reduced 4 api calls to 2 api calls...