CheckPrescriptionChangeTask.CheckPrescriptionChange

// Job ID: #66ac8f38d222d90670a89bb8
using OI.Service.HangfireTask.CheckPrescriptionChangeTask;

var checkPrescriptionChangeTask = Activate<CheckPrescriptionChangeTask>();
await checkPrescriptionChangeTask.CheckPrescriptionChange(
    "664c205d8222d30b74798534",
    FromJson<Prescription>("{\"PackType\":0,\"Dose\":[1.0],\"ShortCourseTimeslot\":[],\"PatientId\":\"66ab5801d222d90270b8020c\",\"Direction\":\"Take ONE tablet daily\",\"FoilId\":\"66ab5801d222d90270b8021e\",\"FoilLabel\":\"Blister Pack 1\",\"DateDispensed\":\"2024-07-31T01:02:21Z\",\"ScriptNum\":\"21194702\",\"QtyDispense\":0.0,\"DateExpiry\":\"0001-01-01T00:00:00\",\"Route\":{\"Code\":\"PO\",\"Description\":\"Oral\"},\"IsStandard\":true,\"IsShortCourse\":false,\"IsSinemet\":false,\"IsWarfarin\":false,\"IsInsulin\":false,\"IsS8Drug\":false,\"IsCytotoxic\":false,\"IsS4N\":false,\"StartDate\":\"2024-08-02T04:00:00Z\",\"EndDate\":\"0001-01-01T00:00:00Z\",\"Frequency\":0,\"PackedWeekDay\":[],\"FreqXDay\":0,\"OnDays\":0,\"OffDays\":0,\"IsDoNotCrush\":true,\"FontColor\":\"\",\"PrintIt\":true,\"State\":1,\"DateCeased\":\"0001-01-01T00:00:00\",\"TempSubstitution\":false,\"IsHandPacked\":false,\"IsNoEndDate\":true,\"Unit\":\"\",\"PharmacyId\":\"664c205d8222d30b74798534\",\"SyncDate\":\"0001-01-01T00:00:00\",\"IsSyncImported\":false,\"Drug\":{\"DrugName\":\"ATORVASTATIN (APO) 40mg TAB\",\"DrugCode\":\"ATOR22\",\"Austr\":\"286638\",\"Supplier\":\"APOTEX PTY LTD\",\"Type\":\"Tablet\",\"Color\":\"white\",\"Shape\":\"oval\",\"Marking\":\"ATV40\",\"Warning\":\"*Avoid eating grapefruit or drinking grapefruit juice while being treated with this medicineSpecial handling and disposal required - ask your Pharmacistswallowed whole\",\"Direction\":\"\",\"GenericCode\":\"ATOR3\",\"GenericName\":\"ATORVASTATIN\",\"Presentation\":\"\",\"ImageId\":\"5f3a2dbba0ba5d7c50796bc1\",\"ImageName\":\"286638-C01-01-BL600.jpg\",\"AltBrand\":\"LIPITOR, TROVAS, TROVAS, ATORVASTATIN (PFIZER), ATORVACHOL, ATORVASTATIN (APO), ATORVASTATIN (CHEM MART), ATORVASTATIN (GEN HLTH), ATORVASTATIN (SANDOZ), ATORVASTATIN (TW), LORSTAT 40, TORVASTAT 40, ATORVASTATIN (SCP), ATORVASTATIN (STADA), ATORVASTATIN (SZ), ATORVASTATIN (AN), ATORVASTATIN (BLOOMS), ATORVASTATIN (AMNEAL), ATORVASTATIN (PHARMACOR), ATORVASTATIN (NOUMED), ATORVASTATIN (PHARMACOR), ATOMED, ATORVASTATIN (BTC)\",\"DoNotCrush\":true,\"TradeName\":\"ATORVASTATIN (APO)\",\"Formulation\":\"TAB\",\"Strength\":\"40mg\",\"Schedule\":\"4\",\"PackSize\":30,\"IsCytotoxic\":false,\"Authorized\":0,\"TSAuthorized\":\"0001-01-01T00:00:00Z\",\"ShelfLife\":0,\"Description\":\"oval white ATV40\",\"UsePrintingDrugName\":false,\"PrintingDrugName\":\"\",\"PharmacyId\":\"664c205d8222d30b74798534\",\"Usage\":0,\"DrugFullName\":\"ATORVASTATIN (APO) 40mg TAB\",\"MedicationFullDetails\":\"ATORVASTATIN (APO) 40mg TAB - ATORVASTATIN (ATOR22)\",\"Id\":\"5f0e69e0a0ba5db368a16a52\",\"CreatedDate\":\"2020-07-15T02:28:44.514Z\",\"CreatedUserId\":\"5e7457052a22160c3cf31edb\",\"LastUpdateUserId\":\"\",\"LastUpdateDate\":\"2024-06-14T06:42:40.624Z\",\"UpdateDeletedDate\":\"1900-01-01T00:00:00Z\",\"IsDeleted\":false},\"IsPreventBrandswap\":false,\"Swapped\":false,\"FreqXWeek\":0,\"PatientDocumentIds\":[],\"Id\":\"66ab5802d222d90270b80255\",\"CreatedDate\":\"2024-08-01T09:17:20.821Z\",\"CreatedUserId\":\"664c205d8222d30b7479854e\",\"LastUpdateUserId\":\"666b9ad25ac25f0bdc73d8fa\",\"LastUpdateUserName\":\"lh\",\"LastUpdateDate\":\"2024-08-02T07:48:08.2708455Z\",\"UpdateDeletedDate\":\"1900-01-01T00:00:00Z\",\"IsDeleted\":false}"),
    "66ab5801d222d90270b8020c",
    "");
CurrentCulture
"en-US"
CurrentUICulture
"en-US"

State

8/2/2024 8:00:10 AM (+7m 21.193s) Failed

An exception occurred during performance of the job.

MongoDB.Driver.MongoCommandException

Command find failed: query plan killed :: index 'JobNumber_1_PharmacyId_1_IsDeleted_1' for collection 'myPakLive.PackJob' dropped.

MongoDB.Driver.MongoCommandException: Command find failed: query plan killed :: index 'JobNumber_1_PharmacyId_1_IsDeleted_1' for collection 'myPakLive.PackJob' dropped.
   at MongoDB.Driver.Core.WireProtocol.CommandUsingCommandMessageWireProtocol`1.ProcessResponse(ConnectionId connectionId, CommandMessage responseMessage)
   at MongoDB.Driver.Core.WireProtocol.CommandUsingCommandMessageWireProtocol`1.<ExecuteAsync>d__13.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at MongoDB.Driver.Core.Servers.Server.ServerChannel.<ExecuteProtocolAsync>d__29`1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at MongoDB.Driver.Core.Operations.CommandOperationBase`1.<ExecuteProtocolAsync>d__28.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at MongoDB.Driver.Core.Operations.ReadCommandOperation`1.<ExecuteAsync>d__2.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at MongoDB.Driver.Core.Operations.FindCommandOperation`1.<ExecuteAsync>d__111.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at MongoDB.Driver.Core.Operations.FindOperation`1.<ExecuteAsync>d__111.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at MongoDB.Driver.OperationExecutor.<ExecuteReadOperationAsync>d__3`1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at MongoDB.Driver.MongoCollectionImpl`1.<ExecuteReadOperationAsync>d__93`1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at MongoDB.Driver.MongoCollectionImpl`1.<UsingImplicitSessionAsync>d__101`1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
   at OI.Data.MongoDBRepository`1.<>c__DisplayClass21_0.<<FindAsync>b__0>d.MoveNext() in C:\Program Files (x86)\Jenkins\workspace\myPak-webjob-live\OI\OI.Data\MongoDBRepository.cs:line 219
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
   at OI.Data.MongoDBRepository`1.<FindAsync>d__21.MoveNext() in C:\Program Files (x86)\Jenkins\workspace\myPak-webjob-live\OI\OI.Data\MongoDBRepository.cs:line 216
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
   at OI.Service.PackJobService.PackJobService.<GetByPatientIdAndFoilIdsAndStatus>d__24.MoveNext() in C:\Program Files (x86)\Jenkins\workspace\myPak-webjob-live\OI\OI.Service\PackJobService\PackJobService.cs:line 719
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
   at OI.Service.HangfireTask.CheckPrescriptionChangeTask.CheckPrescriptionChangeTask.<CheckPrescriptionChange>d__23.MoveNext() in C:\Program Files (x86)\Jenkins\workspace\myPak-webjob-live\OI\OI.Service\HangfireTask\Prescription\CheckPrescriptionChangeTask.cs:line 120

+4m 40.893s Processing

Server:
ip-0a0008b4:744
Worker:
ba951afc

+124ms Enqueued

Queue:
default

8/2/2024 7:48:08 AM Created