DTD Hibernate · 3.0

Hibernate configuration 3.0

hibernate.cfg.xml

The hibernate.cfg.xml file, still read by Hibernate up to version 6.

About

hibernate.cfg.xml sets the session factory properties and lists mappings. Hibernate keeps accepting this DTD-based file in current versions.

Good to know

  • The Hibernate mapping DTD (hbm.xml) is not included: its content model is not deterministic, which XML validators such as libxml2 reject.
  • The example is by xmlvalid.com.

Files

1 file · 2.7 KB

Example document

hibernate.cfg.xml · 585 B · valid against this schema

In CI and from code

The same schema by its name, hibernate-configuration-3.0, through the API.

npx @xmlvalid/cli validate "**/*.xml" --schema hibernate-configuration-3.0
- uses: xmlvalid/validate-action@v1
  with:
    files: "**/*.xml"
    schema: hibernate-configuration-3.0
    api-key: ${{ secrets.XMLVALID_API_KEY }}
curl https://xmlvalid.com/api/v1/validations \
  -H "Authorization: Bearer $XMLVALID_API_KEY" \
  -F document={{ $schema->example ?? 'document.xml' }} -F schema=hibernate-configuration-3.0

Free accounts get 100 API validations a month. On Pro, a URL monitor can check a published document against this schema every hour and email you when it breaks. More CI setups