Avatar
dolu
59b96df8d8b5e66b3b95a3e1ba159750a6edd69bcbba1857aeb652a5b208bd59

This is my main issue on Nostr Proxy.

After running for ~1 hour (locally) with 15-20 clients connected to it, I closed all clients. Everything got cleaned correctly, but not these Promises. 534k Promises...

That's why Nostr Proxy crashes after a while. If anyone can help with this analysis, contact me please.

I can't find any information in the memory heap snapshots

Nostr Proxy stress test time!

https://nproxy.zerologin.co or https://nproxy.cc (or both)

Welcome sir #[0]

Did you remember twitter? It was an old social network back in the good old days

Is it a good UX to always have to click on "Show X new notes" instead of displaying them directly in the thread?

I'm on iris.to. Let's try it

So... if you are connected to either nproxy.zerologin.co or nproxy.cc, just publish things to stress test the proxy!

(nproxy.cc should be better)

Subscribing to events looks fine.

Leaks appeared only on publish events, that's why it could take many hours before crash

Oh, I found a beautiful memory leak in nostr-tools!

Fixed on my branch, let's try this!

GM it crashed again

Replying to Avatar dolu

Nostr proxy is running for more an hour without RAM or CPU issue!

If it stay alive all the night, I could say it's "stable".

Try it here

https://nproxy.zerologin.co (deployed on a VPS)

https://nproxy.cc (deployed on railway)

Stats are funny (no)

VPS: 20 currents connections - 50-100Mo RAM

Railway: 2 currents connection - ~140Mo RAM

VPS one died.

But wtf, I can't believe it. Is there an attacker?

My two proxy on VPS and Railway got full of RAM at the same time

Nostr proxy is running for more an hour without RAM or CPU issue!

If it stay alive all the night, I could say it's "stable".

Try it here

https://nproxy.zerologin.co (deployed on a VPS)

https://nproxy.cc (deployed on railway)

Stats are funny (no)

VPS: 20 currents connections - 50-100Mo RAM

Railway: 2 currents connection - ~140Mo RAM

First, I'm using a branch named "heap" for all my tests.

I'll merge as soon as I resolved perf issues (it should be ok very soon™️!)

Then I'll write a robust readme for deploying.

I can also make "Deploy on railway" button into the readme when it's ready.

I know they offer free credits for each deployments if the project is open source and has 100+ stars on github. It could be very great for me 😅

Anyway, I can send you a batch env example in DM, but it can change fast

- Having only 1 WS connection instead of X results in battery/bandwidth eco.

- Hide your IP address to relays (only the proxy knows your IP, but you can self host the proxy)

I have disabled schnorr signature validation and... It works!

I have some peak at 100%+ sometimes, but it's under 10-20% all the time