# JPAMetaModelEntityProcessor does not generate all fields with Docker

**URL:** https://discourse.hibernate.org/t/jpametamodelentityprocessor-does-not-generate-all-fields-with-docker/5824
**Category:** Hibernate Tools
**Created:** [November 5, 2021, 9:00pm UTC](https://discourse.hibernate.org/t/jpametamodelentityprocessor-does-not-generate-all-fields-with-docker/5824 "2021-11-05T21:00:20Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![devsaleh](https://avatars.discourse-cdn.com/v4/letter/d/b77776/32.png) [@devsaleh](https://discourse.hibernate.org/u/devsaleh)
#### Post date: [November 5, 2021, 9:00pm UTC](https://discourse.hibernate.org/t/jpametamodelentityprocessor-does-not-generate-all-fields-with-docker/5824/1 "2021-11-05T21:00:20Z")

</div>

I have the following entities

```auto
@JsonInclude(JsonInclude.Include.NON_NULL)
@Embeddable
public class EmbeddableEntity
{
    @Cascade(CascadeType.SAVE_UPDATE)
    @OneToOne
    @JoinColumn(name = "fk_entity_A")
    private EntityA entityA;
}

```

```auto
@Entity
@Table(name = "tb_entity_a")
@Inheritance(strategy = InheritanceType.SINGLE_TABLE)
@DiscriminatorColumn(name = "type", length = 50)
@JsonInclude(JsonInclude.Include.NON_NULL)
public abstract class EntityA
{
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @JsonIgnore
    protected Long id;

    @JsonIgnore
    @OneToOne(mappedBy = "embeddableEntity.entityA", orphanRemoval = true)
    protected EntityB entityB;

    @NotNull
    @Column(name = "boolean_field", columnDefinition = "TINYINT DEFAULT 0", nullable = false)
    private Boolean booleanField = false;
}

```

```auto
@Entity
@Table(name = "tb_entity_b")
@DiscriminatorColumn(name = "type", length = 50)
@DiscriminatorValue("entityb")
public class EntityB
{
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Long id;

    @Embedded
    private EmbeddableEntity embeddableEntity;
}

```

I want JPAMetaModelEntityProcessor to generate a MetaModel class like this:

```auto
package br.com.loopec.loopkey.server.corp.persistence.entity;

import javax.annotation.Generated;
import javax.persistence.metamodel.SingularAttribute;
import javax.persistence.metamodel.StaticMetamodel;

@Generated(value = "org.hibernate.jpamodelgen.JPAMetaModelEntityProcessor")
@StaticMetamodel(EmbeddableEntity.class)
public abstract class EmbeddableEntity_ {

	public static volatile SingularAttribute<EmbeddableEntity, EntityB> entityB;
	public static volatile SingularAttribute<EmbeddableEntity, Boolean> booleanField;

	public static final String ENTITY_B = "entityB";
	public static final String BOOLEAN_FIELD = "booleanField";
}

```

But all it generates for me is a class like this, omitting the entityB field I want generated:

```auto
package br.com.loopec.loopkey.server.corp.persistence.entity;

import javax.annotation.Generated;
import javax.persistence.metamodel.SingularAttribute;
import javax.persistence.metamodel.StaticMetamodel;

@Generated(value = "org.hibernate.jpamodelgen.JPAMetaModelEntityProcessor")
@StaticMetamodel(EmbeddableEntity.class)
public abstract class EmbeddableEntity_ {

	public static volatile SingularAttribute<EmbeddableEntity, Boolean> booleanField;

	public static final String BOOLEAN_FIELD = "booleanField";
}

```

I don’t know it’s useful information, but I’ve been facing this problem building the project from Docker.  
My version of hibernate is: 5.4.15.Final  
Can you see if I did something wrong with my code? I don’t know if it’s a hibernate bug, but I found a thread on stack overflow with another developer having a similar problem. [JPA Hibernate 5: OneToOne in nested Embeddable causes metamodel issue - Stack Overflow](https://stackoverflow.com/questions/46710730/jpa-hibernate-5-onetoone-in-nested-embeddable-causes-metamodel-issue)
