<?xml version="1.0" encoding="UTF-8"?>
<rss version='2.0' xmlns:dc="http://purl.org/dc/elements/1.1/"
  xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Shawn McCool</title>
    <description>software, business, and game design</description>
    <link>https://shawnmccool.silvrback.com/feed</link>
    <atom:link href="https://shawnmccool.silvrback.com/feed" rel="self" type="application/rss+xml"/>
    <category domain="shawnmccool.silvrback.com">Content Management/Blog</category>
    <language>en-us</language>
      <pubDate>Fri, 12 Apr 2019 02:37:21 -1200</pubDate>
    <managingEditor>shawn@heybigname.com (Shawn McCool)</managingEditor>
      <item>
        <guid>http://shawnmc.cool/reasons-not-to-use-value-types-in-domain-events#46927</guid>
          <pubDate>Fri, 12 Apr 2019 02:37:21 -1200</pubDate>
        <link>http://shawnmc.cool/reasons-not-to-use-value-types-in-domain-events</link>
        <title>Reasons Against Using Value Types in Domain Events</title>
        <description></description>
        <content:encoded><![CDATA[<h1 id="domain-events-are-super-ice">Domain Events are Super Ice</h1>

<p>Domain events are frozen. They don&#39;t change. They&#39;re so cold that if an event needs to change we instead version up a new event and leave the old one alone.</p>

<p>They&#39;re SO cold in fact that they freeze whatever they touch. Freezing strings and shit is no big deal, because that&#39;s the language&#39;s problem... A bigger problem is when they freeze your whole domain model&#39;s value types.</p>

<p>What happens if a domain event is full of your nice rich value types and a value type needs to change? That&#39;s going to be a problem because they&#39;re implemented in frozen code. It&#39;s likely that the kinds of values that are in one domain object are going to be in multiple. Are you going to change the value and then create new versions of multiple events? Are you going to create a new version of that value? </p>

<p>Domain events are frozen, anything they touch freezes, don&#39;t freeze your value types.</p>

<h1 id="slower-bulk-instantiation">Slower Bulk Instantiation</h1>

<p>Do you need to rebuild a projection? Do you need to process anything with a bunch of events? It&#39;s going to be much faster with primitive types.</p>

<h1 id="serialization-complexity">Serialization Complexity</h1>

<p>Primitive values can be auto-serialized trivially. Complex serialization systems are a drag. It can be done, I&#39;ve done it, it&#39;s ok. It&#39;s better without.</p>

<h1 id="consistency">Consistency</h1>

<p>If the intent for the event came through your domain then your domain values are responsible for consistency. It&#39;s entirely possible to have static factory methods on your events that allow them to be built from domain value types etc.</p>

<p>What about data that comes from external services? Webhooks? Do we really want to validate that for consistency? Are we sure that we know the specifics of that services&#39; types? </p>

<p>That external service validates their data and what we got IS what they sent. Better to take what they sent than just reject it. Otherwise you&#39;re just giving up what information you could have had based on a disagreement. I think that we should be a bit more mature than that.</p>

<p><strong>Tune in for the next episode called, &quot;Reasons to use Value Types in Domain Events&quot;.</strong></p>
]]></content:encoded>
      </item>
      <item>
        <guid>http://shawnmc.cool/avoiding-unified-data-models#42030</guid>
          <pubDate>Mon, 13 Aug 2018 00:59:36 -1200</pubDate>
        <link>http://shawnmc.cool/avoiding-unified-data-models</link>
        <title>Avoiding Unified Data Models</title>
        <description>a talk about boundaries in architecture</description>
        <content:encoded><![CDATA[<p>Recently at the Dutch PHP Conference (DPC) I gave a talk on architectural boundaries. </p>

<p>I target Laravel developers as an audience and use some Laravel syntax. But the talk is not about Laravel and it doesn&#39;t require any prerequisite knowledge at all. </p>

<p>The talk is purely about architecture.</p>
<iframe width="420" height="315" src="https://www.youtube.com/embed/jPnhTxRfOVk" frameborder="0" allowfullscreen=""></iframe>
]]></content:encoded>
      </item>
      <item>
        <guid>http://shawnmc.cool/social-media-extremism#35818</guid>
          <pubDate>Wed, 13 Dec 2017 00:14:40 -1200</pubDate>
        <link>http://shawnmc.cool/social-media-extremism</link>
        <title>Social Media Extremism</title>
        <description>becoming our ugliest selves</description>
        <content:encoded><![CDATA[<p><strong>On social media voices carry and extreme voices carry the most.</strong></p>

<p>We&#39;re exposed to much more extremism than we would normally be exposed to. It&#39;s natural to <strong>react</strong> to extreme positions by <em>forming extreme positions</em>. </p>

<p>We see some ridiculous thing that someone does in the name of civil rights and it becomes a little bit easier to believe that anyone involved in sex / gender based civil rights is an insane <strong>hypocritical SJW</strong>.</p>

<p>We see ridiculous things being done in the name of social responsibility and it becomes a little bit easier to believe that anyone who believes that our society should decide once and for all that healthcare is a basic human right is a <strong>libtard with a mental illness</strong>.</p>

<p><strong>Conceptual modeling is our ability to abstract complexity away from noisy reality into something that we can comprehend and use.</strong></p>

<p>We have a need for these abstractions. They are a critical element of what it is to be human and to function at a human level. But, the capability is far from perfect. From the process of simplification we can arrive at ideas like.. (insert abstract group) are lazy criminals...</p>

<p>We cannot effectively understand reality. So we fall back on simplifications that we <strong>must</strong> learn to realize are <em>ALWAYS</em> fundamentally lacking.</p>

<p>Our conceptual models are not accurate. But, they can be useful. We can use them to predict the future and try to understand why things have happened in the past. When we&#39;re exposed to floods of extreme viewpoints our conceptual modeling skills are triggered into backfiring. They create extreme defensiveness, apathy, disgust. These feelings are then tied to the abstract simplification that we use to understand the source of the insanity.. The movements themselves.</p>

<p>I think that it&#39;s important that we learn to see past extreme viewpoints to potential underlying causes. We should stop associating extreme behavior with the genuine opportunities that exist for us to improve the human condition.</p>

<p><strong>Yes, people are bat-shit crazy.</strong> They are and they always will be. Don&#39;t let the fact that <strong>we&#39;re tired of hearing about their shit</strong>, that <strong>they&#39;re insanely rude and hypocritical</strong>, or that <strong>they&#39;re clearly fucking sociopaths</strong> trick us into being the ugliest possible version of ourselves.</p>

<p>Be honest... When was the last time that you sided against what YOU YOURSELF considered to be decent just because you were fucking tired of hearing about it? </p>

<p>We need to be ready to protect ourselves from our own toxic reactions and to see through the fucking crazy in others and seek to understand the underlying systemic causes. If we absolutely cannot engage with others without letting our personal failings make the world a worse place then we should learn to ACCEPT that we&#39;re not in a place to be productive and avoid participation.</p>

<p>In the same vein as &quot;if you can&#39;t say something nice, don&#39;t say anything at all&quot; consider &quot;if you can&#39;t care enough to try to make the world a better place, at least don&#39;t actively make it worse just to vent your emotions.&quot;</p>

<p>We are individuals and we may be able to reach out to an individual in our lives and improve their situation. But, <strong>the real important work is improving the systems that birth us and forge us into the crazy things that we are.</strong></p>

<p>Let&#39;s evolve into something that makes positive impacts instead of amplifies negativity.</p>
]]></content:encoded>
      </item>
  </channel>
</rss>