asynchronous Questions
1
I'm looking to catch IOExceptions caused by a broken pipe before the async threads dispatch the result to Tomcat. Essentially the client disconnects and the error bubbles up to Tomcat before I can ...
Sandry asked 10/3, 2023 at 20:30
3
Solved
I have implemented a socket client using TcpClient class. So I can send and receive data, everything works good. But I ask some of the guru's out there :) Is there something wrong with my implement...
Hatchet asked 18/1, 2017 at 11:32
9
Solved
I have PHP's mail() using ssmtp which doesn't have a queue/spool, and is synchronous with AWS SES.
I heard I could use SwiftMail to provide a spool, but I couldn't work out a simple recipe to use ...
Telemechanics asked 11/4, 2016 at 5:45
5
Let say I have this code
class Duck{
func walk() async {
//do something
print("walk start")
try? await Task.sleep(nanoseconds: UInt64(2e9))
print("walk end")
}
func q...
Choe asked 23/3, 2022 at 11:43
2
Solved
I've been reading parts of https://eel.is/c++draft/exec and other related articles regarding this topic. I know what schedulers, receivers, and senders are. However, I don't see how these interacti...
Thessalonian asked 3/8 at 16:15
4
var crypto = require('crypto');
var sha = crypto.createHash('sha512').update(String(s));
var result = sha.digest('hex');
That's my current code.
How do I do this async? I'm planning to do the sh...
Donatist asked 9/8, 2014 at 7:50
3
Solved
I'm trying to make multiple requests async and get response back, I'm using concurrent.futures to do this, but inside my function using current_app which from flask and I always got this error:
Run...
Machmeter asked 29/4, 2018 at 7:18
4
Solved
I have two calls to chrome.storage.local.get(). I need for these calls to finish before continuing executing the rest of the code (calling continueCode() function) for my chrome extension, but I'm ...
Brockie asked 21/12, 2019 at 21:38
4
Solved
I would like to replicate the behavior and ergonomics of taking a closure/function as an argument much like map does: iterator.map(|x| ...).
I've noticed that some library code allows passing in a...
Oletta asked 17/3, 2020 at 7:12
1
I am attempting to launch thrust::fill on two different device vectors in parallel on different CUDA streams. However, when I look at the kernel launches in NSight Systems, they appear to be serial...
Aldarcy asked 22/7 at 18:28
7
Solved
I'm writing a Javascript script.
This script will probably be loaded asynchronously (AMD format).
In this script, I'd like to do nothing important until the window.load event was fired.
So I liste...
Pairs asked 13/11, 2012 at 16:27
2
Solved
I have a situation like this:
var retrievalTasks = new Task[2];
retrievalTasks[0] = GetNodesAsync();
retrievalTasks[1] = GetAssetsToHandleAsync();
Task.WaitAll(retrievalTasks);
And I wo...
Bibliolatry asked 11/6, 2018 at 9:55
4
Solved
I am trying to use async to get the HTML from a list of urls (identified by ids). I need to use a proxy.
I am trying to use aiohttp with proxies like below:
import asyncio
import aiohttp
from bs4...
Burdick asked 17/8, 2018 at 2:54
3
Solved
I am trying to download files asynchronously from an SFTP-server using SSH.NET. If I do it synchronously, it works fine but when I do it async, I get empty files. This is my code:
var port = 22;
s...
Sclaff asked 2/12, 2015 at 10:1
2
Solved
I want to connect to a list of a lot of different sites very fast.
Im using asyncio to do this in an asynchronous manner and now want to
add a timeout for when connections should be ignored if the...
Decoder asked 20/4, 2015 at 19:17
6
Is it possible for Lambda to continue processing after returning a response like the status code is 202 then Lambda will have to call a request before ending the Lambda?
Hightower asked 14/8, 2019 at 9:27
9
Solved
I want to use asyncio in combination with a tkinter GUI.
I am new to asyncio and my understanding of it is not very detailed.
The example here starts 10 task when clicking on the first button. The ...
Gwyn asked 19/12, 2017 at 21:57
4
Solved
I am using Asp.Net Core Identity and trying to simplify some code that projects a list of users and their roles to a ViewModel. This code works, but in trying to simplify it I have gone into a craz...
Doner asked 15/9, 2016 at 18:38
3
Solved
For simplicity let's imagine we have a method that should return an object while doing some heavy operation. There're two ways to implement:
public Task<object> Foo()
{
return Task.Ru...
Upanishad asked 25/3, 2016 at 7:44
9
I am currently trying to add polling to my application using this link https://davidwalsh.name/javascript-polling (and many others).
I have access to the following already implemented api:
client...
Combine asked 13/9, 2017 at 22:56
2
Solved
I have a C# WPF program that opens a file, reads it line by line, manipulates each line then writes the line out to another file. That part worked fine. I wanted to add some progress reporting so I...
Cavort asked 30/9, 2017 at 1:3
12
Solved
How can I create a wrapper that makes celery tasks look like asyncio.Task? Or is there a better way to integrate Celery with asyncio?
@asksol, the creator of Celery, said this::
It's quite comm...
Bowerman asked 2/10, 2016 at 9:51
2
Solved
I am using this chunk of code:
assert.throws(async () => {
patientSubscriber = await PatientSubscriber.create({
isSubscribed: true,
patient: patient._id,
subscriber: user._id
});
},{
me...
Elva asked 21/9, 2018 at 19:19
5
So I'm locked to a python 3.6.2 interpreter that follows my desktop application.
What I want is to call an async function from a synchronized method or function.
When calling the python function fr...
Aime asked 9/8, 2018 at 8:29
3
Solved
This question has several answers (here, here, and here), but none of them worked for me :(
What I've tried so far:
use hyper as http;
use futures::TryStreamExt;
fn test_heartbeat() {
let mut...
Yangyangtze asked 7/8, 2020 at 12:24
1 Next >
© 2022 - 2024 — McMap. All rights reserved.