title: swagger springfox - bean validation JSR 303 not recognize
body: <p>I followed this tutorial <a href="https://springframework.guru/spring-boot-restful-api-documentation-with-swagger-2/" rel="noreferrer">https://springframework.guru/spring-boot-restful-api-documentation-with-swagger-2/</a> to generate a swagger documentation.
  It's working but when I try to add some validation in my bean I don't find the information in the documentation:</p>
  
  <pre><code>@ApiOperation(value = "Creates a product",
          notes="Populates a product instance bla bla")
  @RequestMapping(value = "/add", method = RequestMethod.POST, produces = "application/json")
  public ResponseEntity saveProduct(  @Valid @RequestBody Product product){
      productService.saveProduct(product);
      return new ResponseEntity("Product saved successfully", HttpStatus.OK);
  }
  </code></pre>
  
  <p>My entity with the validations annotations :</p>
  
  <pre><code>@Entity
  public class Product {
      @Id
      @GeneratedValue(strategy = GenerationType.AUTO)
     // @ApiModelProperty(notes = "The database generated product ID")
      private Integer id;
      @Version
     // @ApiModelProperty(notes = "The auto-generated version of the product")
      @NotNull
      private Integer version;
     // @ApiModelProperty(notes = "The application-specific product ID" )
      private String productId;
     // @ApiModelProperty(notes = "The product description")
      @NotBlank
      @Size(max = 50)
      private String description;
     // @ApiModelProperty(notes = "The image URL of the product")
      private String imageUrl;
     // @ApiModelProperty(notes = "The price of the product", required = true)
      @NotNull
      private BigDecimal price;
  </code></pre>
  
  <p>But when I check the documentation I don't have those validation information:</p>
  
  <p><a href="https://i.stack.imgur.com/c7sFp.png" rel="noreferrer"><img src="https://i.stack.imgur.com/c7sFp.png" alt="enter image description here"></a></p>
  
  <p>Here <a href="https://github.com/springfox/springfox/issues/987" rel="noreferrer">https://github.com/springfox/springfox/issues/987</a> they say that we need to update our dependencies and it's what I did :</p>
  
  <pre><code>&lt;dependency&gt;
      &lt;groupId&gt;io.springfox&lt;/groupId&gt;
      &lt;artifactId&gt;springfox-swagger-ui&lt;/artifactId&gt;
      &lt;version&gt;2.8.0&lt;/version&gt;
  &lt;/dependency&gt;
  &lt;dependency&gt;
      &lt;groupId&gt;io.springfox&lt;/groupId&gt;
      &lt;artifactId&gt;springfox-swagger2&lt;/artifactId&gt;
      &lt;version&gt;2.8.0&lt;/version&gt;
  &lt;/dependency&gt;
  </code></pre>
  
  <p>Did I miss something in the configuration? Any idea to help me ?</p>