Skip to content

Commit

Permalink
Change definitons of explicit/implicit archive, add notion about back…
Browse files Browse the repository at this point in the history
…wards compatibility.
  • Loading branch information
manovotn authored and Ladicek committed Aug 27, 2021
1 parent fc5f209 commit 973dc55
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions spec/src/main/asciidoc/core/packagingdeployment.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,12 @@ is not a bean archive.
An _explicit bean archive_ is an archive which contains a `beans.xml` file:

* with a version number of `1.1` (or later), with the `bean-discovery-mode` of `all`, or,
* with no version number, or,
* that is an empty file.
* with no version number.

An _implicit bean archive_ is any other archive which contains one or more bean classes with a bean defining annotation as defined in <<bean_defining_annotations>>.
An _implicit bean archive_ is:

* an archive which contains a `beans.xml` file that is empty, or,
* any other archive which contains one or more bean classes with a bean defining annotation as defined in <<bean_defining_annotations>>.

When determining which archives are bean archives, the container must consider:

Expand All @@ -48,6 +50,8 @@ The `beans.xml` file must be named:

* `META-INF/beans.xml`.

For compatibility with CDI versions prior to 4.0, {cdi_full} products must contain an option that causes an archive with empty beans.xml to be considered an explicit bean archive.

The container searches for beans in all bean archives in the application classpath.

If a bean class is deployed in two different bean archives, non-portable behavior results.
Expand Down

0 comments on commit 973dc55

Please sign in to comment.