Welcome Guest, Not a member yet? Register   Sign In
How to implement EventSource on Codeignigter app?
#9

(This post was last modified: 02-24-2020, 09:59 AM by SmokeyCharizard.)

(02-23-2020, 11:13 PM)daveĀ friend Wrote:
(02-23-2020, 03:27 PM)SmokeyCharizard Wrote: It can take anywhere between 3 minutes to 3 hours, depending on the items being processed. Should I turn to websockets instead? What would you recommend?

Wow! Now that's a very intensive process.

Is the hard part during or after this line?

PHP Code:
$data $this->proxy->catalogProductList($this->sessionId$filter); 

Wherever it is, I'd need to see the code to find the best place(s) to send progress messages.

I don't think WebSockets is necessary. I don't see the two-way capability of them as useful in this case. They are more complicated to implement too.

Unless examining the code indicates otherwise I'd say stick with EventSource.

Yes and no. The model calls a lot of methods likeĀ catalogProductList, and when one is finished, I want it to fire a message. For security purposes, I can't share all the code, but I do know where I should put the messages. The message must be sent from the cfa_model.php, and I can only seem to have the eventsource listen on a controller's function. Would I have eventsource listen to the file itself?
Reply


Messages In This Thread
RE: How to implement EventSource on Codeignigter app? - by SmokeyCharizard - 02-24-2020, 09:50 AM



Theme © iAndrew 2016 - Forum software by © MyBB