• JeSuisUnHombre@lemm.ee
      link
      fedilink
      arrow-up
      1
      ·
      10 days ago

      Am I wrong or does that title he’s given himself directly contradict his dislike of code ownership? Or is it just he assumes he deserves credit for the code written by any of his subordinates?

  • THCDenton@lemmy.world
    link
    fedilink
    arrow-up
    2
    ·
    8 days ago

    Lmao ok ill just follow best practices and end up inadvertently writing an orm from scrach then 🙆‍♀️

  • DarkWinterNights@lemmy.world
    link
    fedilink
    arrow-up
    1
    ·
    edit-2
    9 days ago

    Lol. Let’s ban accountability, refactoring, and debugging, never work alone, never coordinate, avoid productivity, and refuse ownership—then scream when things break, don’t integrate, and fall behind schedule.

    “This is all your fault!” built-in. Why didn’t you intuitively know what myX is supposed to do and how it’s used?

    Provocation just for “engagement” really. 102 comments so, to some degree, it works.

    E: Guys, it’s satire. Lol.

    • turnip@sh.itjust.works
      link
      fedilink
      English
      arrow-up
      1
      ·
      7 days ago

      Golang is petty slow with a GUI I’ve found, a web UI works well but GTK or something like that is slow. Maybe that’s what he means?

  • jubilationtcornpone@sh.itjust.works
    link
    fedilink
    English
    arrow-up
    0
    ·
    10 days ago
    • ORM’s
    1. Place ALL of the business logic in stored procedures.
    2. Eliminate the backend.
    3. Make the front end connect directly to the database.
    4. Profit
    5. Introduce tons of bugs and terrible performance.
    6. Database is compromised within five minutes of going live.
    • expr@programming.dev
      link
      fedilink
      arrow-up
      0
      ·
      9 days ago

      I’m confused. Are you saying all of that is a consequence of not using ORMs? Because if so, that’s absolutely not true. ORMs truly are complete trash.

      • sugar_in_your_tea@sh.itjust.works
        link
        fedilink
        arrow-up
        0
        ·
        9 days ago

        Sounds like you were hurt by an ORM.

        One huge benefit of an ORM is that it does type checking. it makes sure your tables exist, relationships are valid, etc, and it makes easy things easy. If you add a column, it’ll make sure it gets populated, give you decent error messages, etc.

        As long as you use a proper repository pattern setup and isolate DB interactions from the rest of the code, how you construct the queries is completely up to you. I try to use DTOs to communicate w/ the repo layer, so whether an ORM is used or direct SQL queries is largely an implementation detail.

    • Jack@slrpnk.net
      link
      fedilink
      arrow-up
      0
      ·
      9 days ago

      I have for years been pumped to create a sql only side project or sql + frontend

  • Boomkop3@reddthat.com
    link
    fedilink
    arrow-up
    0
    ·
    edit-2
    9 days ago

    No mutable types? So like… no lists? no for … i++?

    I get that there are alternative approaches, but I don’t quite see why you’d want to go to that extreme with this idea? It’s useful for some applications but even for a simple video game it’s likely not helpful.

    • GissaMittJobb@lemmy.ml
      link
      fedilink
      arrow-up
      1
      ·
      9 days ago

      It’s perfectly possible to work without mutability.

      Is it desirable to be entirely without it? Probably not, but leaning immutable is definitely beneficial.

      • Boomkop3@reddthat.com
        link
        fedilink
        arrow-up
        0
        ·
        edit-2
        9 days ago

        I get that there are alternative approaches, but I don’t quite see why you’d want to go to that extreme with this idea? It’s useful for some applications but even for a simple video game it’s likely not helpful.

        I should’ve said that right away, really. That’s on me being online while tired. At that time I did not really think outside the box I was working in that day

        • socsa@piefed.social
          link
          fedilink
          English
          arrow-up
          0
          ·
          9 days ago

          It’s just a very common foot gun, especially in legacy code where it is not explicit in the design. Even when you have proper getters and setters, it’s way to easy for someone to overload the scope of some object, either intentionally or accidentally and modify it inappropriately.

          • Boomkop3@reddthat.com
            link
            fedilink
            arrow-up
            0
            ·
            9 days ago

            I suppose immutability is a solution, I’m not sure if it’s a good idea to radically isolate everything though

            • aubeynarf@lemmynsfw.com
              link
              fedilink
              arrow-up
              0
              ·
              8 days ago

              it’s not radical, it’s just a guarantee that if you hold a reference to an object, it won’t change state under you. It’s a bit like every object has MVCC and copy-on-write semantics built in.

              It’s easy enough to edit the object, producing a new copy, and then explicitly store it back where it goes or send it to whatever consumer needs it.

              • Boomkop3@reddthat.com
                link
                fedilink
                arrow-up
                0
                ·
                8 days ago

                I get the idea, and how you keep it from copying a lot of data unnecessarily. A radical approach would be using immutable types exclusively

                • aubeynarf@lemmynsfw.com
                  link
                  fedilink
                  arrow-up
                  1
                  ·
                  4 days ago

                  Oh, regarding copying data - immutable collections are based on https://en.m.wikipedia.org/wiki/Persistent_data_structure - when a change is applied, you get back a reference to a new data structures where as many inner references as possible are shared with the old one. So, all the parts that didn’t change, are not copied.

                  For something like a Scala case class (similar to a record), o.copy(membername1 = newvalue) returns a new object, with a new membername1 reference, but all other member references are the same as the copied-from object. So it’s a shallow copy with minimal changes.

                  you might see how default immutability as a policy makes this more predictable and able to be reasoned about - any mutable object in an object graph that has a shared reference in a copy may surprise you by suddenly changing state.

                  Of course, that’s the situation everywhere, all the time, in default-mutable languages. How many people set a default value of a Python function argument to [] or {} and were baffled when things started breaking because the instance of the default value was mutated?

  • sugar_in_your_tea@sh.itjust.works
    link
    fedilink
    arrow-up
    0
    ·
    8 days ago

    Wow, the only one I agree with here is MongoDB (and probably Lombok, I don’t write Java), and that has more to do with their licensing issues than anything technical.

    That’s pretty impressive.

    Here’s my list:

    • no-go list of languages - Java, PHP, Ruby, C++ (unless you absolutely need C++ for some domain)
    • OOP - OOP should be isolated, not forced on every problem; many OOP advocates are dogmatic about injecting it everywhere
    • waterfall - screw that noise, faster to market + faster feedback is generally better

    That’s really it, and I’m totally willing to mentor someone who likes the above if they’re otherwise a good developer.

    • DerArzt@lemmy.world
      link
      fedilink
      arrow-up
      0
      ·
      8 days ago

      If you had to write Java you probably would like Lombok if you dislike boilerplate (it can build object constructors, comparators, and field accessor methods via annotation).

      • sugar_in_your_tea@sh.itjust.works
        link
        fedilink
        arrow-up
        0
        ·
        8 days ago

        Java is boilerplate though. It’s finally getting almost tolerable with static imports, arrow functions/lambdas (whatever Java calls it), etc.

        If I had to write Java, I’d push for Kotlin instead, after failing to convince management that there are much better options for the problem they need to solve.

        • aubeynarf@lemmynsfw.com
          link
          fedilink
          arrow-up
          2
          ·
          4 days ago

          You can say you’re running Java and write components in Kotlin or Scala, no one knows after the module is published!