title: Spring Boot REST one-to-one - POST or PUT?
body: <p>I am developing Spring Boot REST api, and now I have encountered some <code>logical problem</code>.</p>
  <p>So I have an entity &quot;A&quot; that owns one-to-one relationship with entity &quot;B&quot;.
  Initialy, entity &quot;A&quot; is POSTed with without entity &quot;B&quot; (-&gt; so relationship is null).</p>
  <p><strong>So when I want to add entity &quot;B&quot; should I simply POST it, or PUT/PATCH entity &quot;A&quot; with entity &quot;B&quot;?</strong></p>