@giuliohome@mastodon.world avatar

giuliohome

@giuliohome@mastodon.world

This profile is from a federated server and may be incomplete. Browse more on the original instance.

greggyb, to random
@greggyb@mastodon.sdf.org avatar

I came up with a thing in today and I am unsure about it. I don't know if it's cute, useless, or useful; I cannot see far enough ahead to understand its implications.

type ErrExn = | Err of DomainError | Exn of System.Exception

This DU unifies domain errors (that are represented in a user-written DU) and exceptions.

I'd expect it to be in a function with a signature of 'a -> Result<'b, ErrExn>.

I don't know if this gives value over separate domain errors and exceptions.

Thoughts?

giuliohome,
@giuliohome@mastodon.world avatar

@pblasucci @chethusk @greggyb
In the retry case, according to temporal workflow philosophy, it would be an exception, a retriable exception, possibly with exponential backoff, managed by the workflow platform. And nobody wants to reinvent the wheel, sadly imho.
One starts as f# programmer and ends up working in a python project team. And they say it's "typed" and has "compile time" checks, due to LSP magic, openai generated domain classes and the like.
We're in the YAML and AI era.
¯_(ツ)_/¯

giuliohome,
@giuliohome@mastodon.world avatar

@pblasucci @chethusk @greggyb
"Let it bubble up and crash" is also more in line with and modern 10 factor app principles.
It's not "crash" though, it is "shut down gracefully"
For a worker , graceful shutdown is achieved by returning the current job to the work .

thisismissem, to random
@thisismissem@hachyderm.io avatar

That thing do with using a custom CA certificate for databases is really fucking annoying.

giuliohome,
@giuliohome@mastodon.world avatar

@thisismissem Maybe this is related https://mastodon.world/@giuliohome/111338180540250101
To be honest, I like DigitalOcean's simplicity. Instead of installing a operator on (which is however a good exercise on their DOKR), you can offload some resources but yeah searching for hidden Helm chart configuration settings can be annoying indeed 😉

giuliohome,
@giuliohome@mastodon.world avatar

@thisismissem @elan what I am saying is. If I create a managed postrgres there I see that I can connect via psql but from golang it's tricky because I have to set ssl=require to make the connection work. It does seem related to what you have written above IMHO

giuliohome,
@giuliohome@mastodon.world avatar

@thisismissem @elan and also my export SQL_TLS_DISABLE_HOST_VERIFICATION=1 seems related to avoiding "a whole weird dance with custom SSL certificates" as far as an exercise, a tutorial or a "proof of concept" demo are concerned... Anyway, thanks for your interesting "toots"

giuliohome,
@giuliohome@mastodon.world avatar

@thisismissem @elan sure ;-) I know what I am doing of course it's not for production or even test, but just for hacking. If I want to test a dotnet activity in temporal cluster and I'm starting from scratch from creating a new k8s cluster that I'll delete eventually, the part where I connect postgresql is "just let me do that"... but yeah I agree that the certificate "dance" is always annoying. And can be due also to private enterprise cert root auth, not only to DO

  • All
  • Subscribed
  • Moderated
  • Favorites
  • megavids
  • rosin
  • thenastyranch
  • GTA5RPClips
  • tester
  • InstantRegret
  • DreamBathrooms
  • ngwrru68w68
  • magazineikmin
  • everett
  • Youngstown
  • mdbf
  • slotface
  • kavyap
  • JUstTest
  • cisconetworking
  • khanakhh
  • normalnudes
  • osvaldo12
  • cubers
  • tacticalgear
  • Durango
  • ethstaker
  • modclub
  • anitta
  • provamag3
  • Leos
  • lostlight
  • All magazines