this post was submitted on 04 Sep 2023
24 points (100.0% liked)

DevOps

26 readers
1 users here now

DevOps integrates and automates the work of software development (Dev) and IT operations (Ops) as a means for improving and shortening the systems development life cycle.

Rules:

Icon base by Lorc under CC BY 3.0 with modifications to add a gradient

founded 1 year ago
MODERATORS
 

TLDR: terraform bad, pulumi good

top 11 comments
sorted by: hot top controversial new old
[–] Charliebeans@slrpnk.net 4 points 1 year ago (1 children)

I don't think DSLs are a waste of time, just a stepping stone in a quite new IT paradigm. A lot of things will die until IaC stabilizes.

I'm more fearing ever increasing reliance on Cloud Providers. Trust and power that we are giving these companies is getting insane and I hope I'm wrong but it will bite all of our butts big time. I hope all of IaC tools will create more tools to have better power balance.

[–] balder1993@programming.dev 2 points 1 year ago

What’s your biggest fear in this regard?

[–] MrJay@programming.dev 3 points 1 year ago* (last edited 1 year ago)

I thought I was going to disagree at first, because I am forced to use multiple DSLs for several projects I work on, however after I thought about it I hate the those DSL's because they are not actual programming languages they are overly restrictive. more limiting than assembly, thus why I am using an actual language to create my own DSL that mainly uses the language as its host, so its not really a full DSL just a few extra functions on top of an actual language. so surprisingly I pretty much agree.

I would say Elixir, Ocaml, Rust, Haskell, Scheme, Clojure, Common Lisp all have great examples of large and small DSL's that are very convenient, I would also include libraries as DSLs a C example would be something like Raylib, or SDL, and I would consider the code below an example of a micro DSL in Common Lisp.

    (loop for i from 0 to 100 by 2
              for x from 10 by 10
              do (print (list i x)))

so I think I mostly agree.

[–] Reptorian@programming.dev 2 points 1 year ago* (last edited 1 year ago)

Here's my opinion, a well-developed DSL could even be arguably more flexible than say Python even with existing libraries on their specific domains. So, if one is just limited to domains, they may be very well be preferable to general languages.

I have coded in C#, Python, C++, and currently nearly everyday, G'MIC. Which one of those are a DSL? The last one. What it is? It's a Domain-Specific Language that has been geared toward raster graphics image processing. Why do I use it? Looking at the stack-based processing, commands, built-in mathematical functions. It seems that it has a lot more things that are built-in than say Pillow library for Python and other things. And I only do create images with code, so I am happy with this, and I even did things like Python itertools combinatorics with more things like rank2list/list2rank variation of those combinatorics which aren't image processing by themselves, but can aid to it.

If I feel that it is way too limited for that Domain, then I wouldn't use it. DSLs are only good if the other options are much more difficult to build with and their flexibility are often enough to entice their audience which is one with limited use cases. Of course, generic languages are usually better even than most DSL even within their domains because of wider support, and wider audience. More DSLs would be better than generics given enough time and support for their domains in my opinion.

[–] onlinepersona@programming.dev 1 points 1 year ago (1 children)
[–] ArtemZ@nowoke.social 2 points 1 year ago (1 children)

I would say it's a library available for several languages

[–] onlinepersona@programming.dev 1 points 1 year ago (1 children)

Lua fall into that category too. It can be embedded to allow writing plugins or extensions.

[–] nikaro@jlai.lu 1 points 1 year ago (1 children)
[–] onlinepersona@programming.dev 1 points 1 year ago (1 children)

LUA is a programming language. Being embeddable doesn't stop something from being a DSL. It's not an attribute that should factor in the distinction between DSL and general purpose programming language.

[–] nikaro@jlai.lu 1 points 1 year ago

Ok i think i get the point. A "generic programming language" could be used as a "domain specific language" in some context. Is that what you mean?