title: Is there an advantage to having individual endpoints over a single endpoint with a path variable?
body: <p>If for example, I have multiple types of electronic devices requesting large files is there any advantage (apart from readability and neatness) of having individual endpoints (or controllers) per device type, like this:  </p>
  
  <pre><code>@RequestMapping(value = "/device/tablet", method = GET)
      public List&lt;Object&gt; getTabletFile(@RequestBody Object body){
   // code here
  }
  
  @RequestMapping(value = "/device/laptop", method = GET)
      public List&lt;Object&gt; getLaptopFile(@RequestBody Object body){
   // code here
  }
  </code></pre>
  
  <p>As opposed to this:  </p>
  
  <pre><code>@RequestMapping(value = "/device/{type}", method = GET)
  public List&lt;Object&gt; getFiles(@PathVariable("type") String type, @RequestBody Object body){
   // code here
  }
  </code></pre>
  
  <p>I'm wondering in terms of performance, if there is expected to be a high load on the system? </p>