In all cases, the functions are launched correctly, despite the errors.
only 1 runtime container is created
I try with fresh install of appwrite 1.3.4/6/7, only upload fonction, same things
what error?
Connection refused
on every execution?
Hard to say, locally now error is gone
appwrite-worker-functions | Fetched 1 functions...
appwrite-worker-functions | Iterating function: Database to Redis
appwrite-executor | Executing Runtime: production-64799a2654cc3fc38bba
appwrite-executor | Function executed in 0.010145902633667 seconds, status: completed
appwrite-worker-functions | Triggered function: databases.dID.collections.cID.documents.647aed18a9ce5746bffa.update
If I force docker compose -f docker-compose-appwrite.yml up -d --force-recreate
error returns
appwrite-executor | Build Stage completed in 1 seconds
appwrite-executor | Executing Runtime: production-64799a2654cc3fc38bba
appwrite-executor | [Error] Type: Exception
appwrite-executor | [Error] Message: An internal curl error has occurred within the executor! Error Msg: Connection refused
appwrite-executor | [Error] File: /usr/src/code/app/executor.php
appwrite-executor | [Error] Line: 541
appwrite-executor | Executing Runtime: production-64799a2654cc3fc38bba
appwrite-executor | [Error] Type: Exception
appwrite-executor | [Error] Message: An internal curl error has occurred within the executor! Error Msg: Connection refused
appwrite-executor | [Error] File: /usr/src/code/app/executor.php
appwrite-executor | [Error] Line: 541
appwrite-executor | Executing Runtime: production-64799a2654cc3fc38bba
appwrite-executor | Function executed in 1.1776671409607 seconds, status: completed
appwrite-worker-functions | Triggered function: databases.dID.collections.cID.documents.647aed18a9ce5746bffa.update
But I can see document updated on redis
perhaps the runtime containers are trying to exit so they aren't accepting new requests
Maybe... Do you think these errors aren't serious and can be ignored?
up to you. i'd look into somehow cleanly exiting
What could cause this exit? Because the runtime works, since it sends to redis 100% of the time.
Your force re create stops the executor which then tries to stop the runtime containers it's managing
From that you mean ? I wait for executor up before test it
maybe in your code somehow catch the kill signall and then stopping execution?
All the code is encapsulated in a try/catch
Catch only set isError=err.message
that won't do it. you would need to do something along the lines to https://stackoverflow.com/questions/43003870/how-do-i-shut-down-my-express-server-gracefully-when-its-process-is-killed.
I try with a blank function
module.exports = async function (req, res) {
res.json({
areDevelopersAwesome: true,
});
};
And have same behavior
appwrite-worker-functions | Fetched 1 functions...
appwrite-worker-functions | Iterating function: My Awesome Function
appwrite-executor | [Error] Type: Exception
appwrite-executor | [Error] Message: Runtime not found. Please create the runtime.
appwrite-executor | [Error] File: /usr/src/code/app/executor.php
appwrite-executor | [Error] Line: 469
appwrite-executor | Building container : production-647f670dba63ab3232e0
appwrite-executor | Build Stage completed in 0 seconds
appwrite-executor | Executing Runtime: production-647f670dba63ab3232e0
appwrite-executor | [Error] Type: Exception
appwrite-executor | [Error] Message: An internal curl error has occurred within the executor! Error Msg: Connection refused
appwrite-executor | [Error] File: /usr/src/code/app/executor.php
appwrite-executor | [Error] Line: 541
oh...perhaps the runtime container isn't actually ready yet before it's trying to be executed?
I can see {areDevelopersAwesome: true}
on Console > Functions > Executions > Logs
Or executor auto retry perhaps ?
it could be a tiny window where the runtime container is created, but the web server isn't actually up and ready yet
Everyone should reproduce in this case ? Let's just say it's a normal error...
[STANDBY] executor log Error but function works
Recommended threads
- Deploy function not working - 503
Hellon i get this error message, when i try to deploy a new version of a function <html><body><h1>503 Service Unavailable</h1>No server is available to handle...
- Migrate from cloud to localhost
Hello everyone. I need to migrate my test project from cloud to localhost, however it seems that this is possible only if a self-hosted appwrite instance it's h...
- Need help with createExecution function
Hi, Need some help understanding createExecution. When requesting function execution via createExecution, the function handler arguments are incorrect and rese...