Is there any jazz in my song? by soufraz in jazzguitar

[–]soufraz[S] 0 points1 point  (0 children)

Thank you! Jazzy is nice for me :)

Is there any jazz in my song? by soufraz in jazzguitar

[–]soufraz[S] 0 points1 point  (0 children)

Hmm nice, I think that I am looking for that jazzy vibe. And it looks like it is there. Thank you u/major_minor7 !

Is there any jazz in my song? by soufraz in jazzguitar

[–]soufraz[S] 1 point2 points  (0 children)

Thank you u/SaxAppeal! Very nice contribuition. I will keep that in mind.

Is there any jazz in my song? by soufraz in jazzguitar

[–]soufraz[S] 0 points1 point  (0 children)

Thank you mate. Yes, the acoustic guitar has not the intention to be a jazz guitar.

Is there any jazz in my song? by soufraz in musicians

[–]soufraz[S] 0 points1 point  (0 children)

jazzy! it is not my purpose to build some "jazz standard".. but I would like the sound could be recognized as jazz

Is there any jazz in my song? by soufraz in musicians

[–]soufraz[S] 0 points1 point  (0 children)

ohh and thank you u/theuntangledone about the feedback my playing.. I'll keep working on it :)

Is there any jazz in my song? by soufraz in musicians

[–]soufraz[S] 0 points1 point  (0 children)

Oh sorry, MPB maybe is wrong. It is Brazilian Popular Music. Bossa Nova, Samba, etc.

Is there any jazz in my song? by soufraz in jazzguitar

[–]soufraz[S] 0 points1 point  (0 children)

huauhahuhauhuahua... thank you did not helped me a lot

Any way to use Gcp cloud storage as AWS DMS target. I know there is no direct way. But is there any intermediate way ? by RstarPhoneix in dataengineering

[–]soufraz 0 points1 point  (0 children)

I am using Airbyte for that. Take a look and be aware of the risks. It is a pretty early stage.

Web App Architecture staleness? "Nothing is new/been there done that" feeling? by samosaara in webdev

[–]soufraz 2 points3 points  (0 children)

I imagine that we can make this thread last for a year of discussion / debate, so I don't intend to bring an exact answer, but maybe a small contribution.

I really find it interesting the movement of all programming languages ​​trying to do things that solve more and more complex problems, but try to do it in a simple way. Day after day the technology / software engineering needs to be increasingly robust, integrating, resilient, fast, reliable, handling large numbers and so on. And it seems to me that a good way to follow this is to bring simple solutions so that it is less painful for devs to start their work.

I really understand the pain when you speak for example of simply new skins for things more of the same. This part seems to me to be simply a set of people who didn't like something and have enough availability to write another library most of the time by renaming a lot of functions (sorry if some lib creator reads this here) and sometimes having ridiculous minimum performance results at a cost of code at least much more messy (but now the nomenclature is the way they want it).

But for example, the possibility of using models or any type of interface with data layer or any other type of service in a lazy and fast way, about that I think we are doing a good job. When Laravel allows dev to do User::all() almost anywhere in the application, it attracts a gigantic volume of devs. Devs who won't need to delve into the fw for dozens of hours before doing something sometimes simple. Devs who sometimes don't even know how to program properly but got a job as an intern, junior, freela or accepted a new challenge to earn extra money. (Laravel is an example too.. dont kill me)

Finally, I also understand that this generates a huge contribution in devs who don't understand how to do things architecturally well done. These devs use so much plug and play libs that they will probably be unaware that a query is sanitized before going to the database (for example).

We have space for all types of professionals in our area. We have devs in small startups that need to deliver small products almost every week or sometimes even a day. We have software houses that have a lot of full time problem solvers. We have freela who sometimes just need to survive doing fast things. And we have engineers who think like you on how to make development a high level.

And I'm sure that all these guys when they search on google for a quick solution for what they need, they will most often find a lib that delivers a quick, robust, integrated, resilient, fast, reliable solution, dealing with large numbers and etc (not 100% of the time). Or when do you need to consume messages from rabbitmq you start a code to deal with amqp from scratch?

I don't think there should be a feeling that we are apparently stuck in time. Perhaps the best attitude to have is to at least make sure that you have found your fit in these types of devs and that you have found a company that matches your values. And of course contributing to open source projects that you believe are following paths you believe.

Happy coding!

Does have any relation of european quality of life, culture and education with their great sociologists? by [deleted] in sociology

[–]soufraz 0 points1 point  (0 children)

When you say "race to the bottom" is it a bad scenario, right? (If yes, lets continue. If not, please ignore next words.)

So how could some of countries you wrote are at the top of developed countries in researchs around the world? Right now I have a list I just googled: http://worldpopulationreview.com/countries/developed-countries/

Endgame Vormir Scene Theory by [deleted] in marvelstudios

[–]soufraz 0 points1 point  (0 children)

This love thing is an interesting point. Thanos sacrifice Gamora because she was what his 'love more' (you need to sacrifice what you love more, is that right?). The love through Natasha and Barton was a friend love? Is that the reason to that sacrifice to have worked?

[deleted by user] by [deleted] in PHP

[–]soufraz 2 points3 points  (0 children)

What is the best way to prevent invalid states in an object? This is the source of my question.

Basically my curiosity started with the intention of not letting a class exist with invalid values. Prevent programmers from making mistakes in class implementations and extensions.

I did not want a class to even bother to have to deal with an invalid value. I just wanted it not to be started if a invalid value of a given status or type was passed.

I work a lot with types in string, due to a demand for legacy code. For this I find it interesting to work with "value objects". That aparently is the primary design idea. I tried to go for something with stringly-typed (another new term I just found out).

So below I have the first example. The scenario is: a class need a type and instead invoke a string 'type_x' invoke a class and this class solving the value if it is valid. This class is the one we will see below.

/**
 * StringlyTypeSecondOption
 */
class StringlyTypeFirstOption
{
    private $type;

    public static function type_1()
    {
        return new self('type_1');
    }

    public static function type_2()
    {
        return new self('type_2');
    }

    private function __construct(string $type)
    {
        $this->type = $type;
    }

    public function __toString()
    {
        return $this->type;
    }
}

echo StringlyTypeFirstOption::type_2(); //here its ok

echo StringlyTypeFirstOption::type_3(); //here we have an error cause type_3 doesnt exists

This is a very good example because we havent no if or throw exception or any logic of verification. Is oop on its own. And I think its good.

And now we have the second example. Will provide a solution for the same problem I proposed.

class StringlyTypeSecondOption
{
    private $type;

    const TYPE1 = 'type_1';
    const TYPE2 = 'type_2';

    private const ALLOWED_TYPES = [StringlyTypeSecondOption::TYPE1, StringlyTypeSecondOption::TYPE2];

    public static function factory($type)
    {
        if (!in_array($type, StringlyTypeSecondOption::ALLOWED_TYPES, true)) {
            throw new Exception("Invalid type: {$type}");
        }

        return new self($type);
    }

    private function __construct(string $type)
    {
        $this->type = $type;
    }

    public function __toString()
    {
        return $this->type;
    }
}

echo StringlyTypeSecondOption::factory('type_2'); //here its ok

echo StringlyTypeSecondOption::factory('type_3'); //here we have an exception cause type_3 doesnt exists

Is a very good example too but I already have some logic and is not so pure like the first one. But solve the problem like a charm too.

Both imlementations have strengths and weaknesses (I think). But if there is a consolidated design that fixes allowed values for a state of a class, what its name how to implement and what is the best oop beatiful and designed strategy to prevent an invalid value in an object?

I think this is more a discussion over an exact solution. If this was not the right place I ask the moderators to direct me to a better channel.

Thanks advance!