title: How to create REST API with optional parameters?
body: <p>I need to implement an API with these path params.</p>
  
  <pre><code>@Path("/job/{param1}/{optional1}/{optional2}/{param2}")
  </code></pre>
  
  <p>Can the second and third params by optional? So the client need not pass these, but have to pass the first and last.</p>
  
  <p>If this is not possible, then is it recommended to rearrange the params in this way?</p>
  
  <pre><code>@Path("/job/{param1}/{param2}/{optional1}/{optional2}")
  </code></pre>
  
  <p>How to provide the optional params?</p>