Skip to content

Commit

Permalink
Fixed link references
Browse files Browse the repository at this point in the history
Signed-off-by: thadumi <th.theodor.th@gmail.com>
  • Loading branch information
thadumi committed Mar 23, 2020
1 parent d2fdc1e commit 5bdd11b
Show file tree
Hide file tree
Showing 19 changed files with 57 additions and 126 deletions.
2 changes: 1 addition & 1 deletion spec/src/main/asciidoc/chapters/appendix/bibliography.adoc
Expand Up @@ -9,7 +9,7 @@
////

[appendix]
[bibliography]
[[bibliography]]
== Bibliography

- [[[bib1,1]]] Enterprise JavaBeansTM, version 3.0 . http://jcp.org/en/jsr/detail?id=220.
Expand Down
25 changes: 10 additions & 15 deletions spec/src/main/asciidoc/chapters/appendix/change_log.adoc
Expand Up @@ -12,21 +12,17 @@
[[change_log]]
== Change Log

Clarified
link:intercept.html#a7[See Relationship to Other
Specifications] to be consistent with the Jakarta EE Platform specification
Clarified <<relationship_to_other_specifications>> to be consistent with the Jakarta EE Platform specification
with regard to when interceptors defined by means of the _Interceptors_
annotation and interceptors defined by means of interceptor bindings are
required to be supported.

Clarified terminology in sections
link:intercept.html#a15[See Terminology] and
link:intercept.html#a20[See Definition of Interceptor Classes
and Interceptor Methods].
Clarified terminology in sections <<terminology>> and
<<definition_of_interceptor_classes_and_interceptor_methods>>.

Noted that around-construct interceptors run
in the same thread as the target constructor in section
link:intercept.html#a48[See Interceptor Environment].
<<interceptor_environment>>.

Clarified that around-construct interceptor
methods may throw checked exceptions.
Expand All @@ -41,8 +37,8 @@ Clarified that interceptor binding may not be
used to associate interceptors with decorators.

Corrected bug in section
link:intercept.html#a313[See Interceptor binding types with
additional interceptor bindings]: An interceptor binding type can only
<<interceptor_binding_types_with_additional_interceptor_bindings>>:
An interceptor binding type can only
be applied to an interceptor binding type defining a subset of its
target types.

Expand All @@ -54,18 +50,17 @@ Clarified when _Priority_ annotation is
ignored.

Added section
link:intercept.html#a447[See Enabling Interceptors] to
link:intercept.html#a446[See Interceptor Ordering] to
<<enabling_interceptors>> to
<<interceptor_ordering>> to
centralize existing requirements on enabling interceptors and separate
concept of the enabling of interceptors from the ordering of
interceptors.

Combined interceptor ordering rules into a
single algorithm in section link:intercept.html#a453[See
Interceptor Ordering Rules].
single algorithm in section <<interceptor_ordering_rules>>.

Factored out section
link:intercept.html#a502[See Excluding Interceptors] on
<<excluding_interceptors>> on
excluding interceptors.

Clarified that _ExcludeClassInterceptors_
Expand Down
Expand Up @@ -14,8 +14,7 @@
Interceptor bindings are intermediate
annotations that may be used to associate interceptors with any
component that is not itself an interceptor or decorator
link:intercept.html#a546[See Jakarta EE Platform 9.
https://jakarta.ee/specifications/platform/9/.].
see <<bib6>>.

include::interceptor_binding_types/interceptor_binding_types.adoc[]

Expand Down
Expand Up @@ -50,10 +50,7 @@ applied at method level or constructor level. Note that the interceptor
bindings applied to the target class may include those inherited from
its superclasses. The CDI specification rules for the inheritance of
type-level metadata apply to the inheritance of interceptor bindings
from superclasses of the target class. See
link:intercept.html#a543[See
Jakarta Contexts and Dependency Injection (CDI specification), version 3.0.
https://jakarta.ee/specifications/cdi/3.0/.].
from superclasses of the target class. See <<bib3>>.

An interceptor binding declared on a method
or constructor replaces an interceptor binding of the same type declared
Expand Down
Expand Up @@ -65,18 +65,14 @@ the equals method.
Array-valued or annotation-valued members of
an interceptor binding type are not supported. An extension
specification may add support for these member types. For example the
CDI specification link:intercept.html#a543[See
Jakarta Contexts and Dependency Injection (CDI specification), version 3.0.
https://jakarta.ee/specifications/cdi/3.0/.] adds the
CDI specification <<bib3>> adds the
jakarta.enterprise.util.Nonbinding annotation, allowing array-valued or
annotation-valued members to be used on the annotation type, but ignored
by the resolution process.

If the set of interceptor bindings of a
component class or interceptor, including bindings inherited from CDI
stereotypes link:intercept.html#a543[See
Jakarta Contexts and Dependency Injection (CDI specification), version 3.0.
https://jakarta.ee/specifications/cdi/3.0/.] and other interceptor bindings,
stereotypes <<bib3>> and other interceptor bindings,
has two instances of a certain interceptor binding type and the
instances have different values of some annotation member, the container
automatically detects the problem, treats it as a definition error, and
Expand Down
Expand Up @@ -32,21 +32,19 @@ declared as meta-annotations of other interceptor bindings.
An interceptor is bound to a method or
constructor if:

The method or constructor has all the
- The method or constructor has all the
interceptor bindings of the interceptor. A method or constructor has an
interceptor binding of an interceptor if it has an interceptor binding
with (a) the same type and (b) the same annotation member value for each
member. An extension specification may further refine this rule. For
example, the CDI specification link:intercept.html#a543[See
Jakarta Contexts and Dependency Injection (CDI specification), version 3.0.
https://jakarta.ee/specifications/cdi/3.0/.] adds the
example, the CDI specification <<bib3>> adds the
jakarta.enterprise.util.Nonbinding annotation, causing member values to be
ignored by the resolution process.

The interceptor intercepts the given kind of
- The interceptor intercepts the given kind of
lifecycle event or method.

The interceptor is enabled. An interceptor is
- The interceptor is enabled. An interceptor is
enabled if the _Priority_ annotation is applied to the interceptor
classlink:#a574[8]. An extension specification may define other
means of enabling interceptors. For example, the CDI specification
Expand Down
Expand Up @@ -38,8 +38,7 @@ any default interceptors (if supported).
If multiple interceptor classes are specified
in the _Interceptors_ annotation, the interceptor methods of these
classes are invoked in the order in which the classes are specified. The
ordering rules for interceptors are defined in Chapter
link:intercept.html#a446[See Interceptor Ordering].
ordering rules for interceptors are defined in Chapter <<interceptor_ordering>>.

The _Interceptor_ annotation is ignored
during the processing of classes bound using the _Interceptors_
Expand All @@ -56,7 +55,7 @@ In the following example, the around-invoke
methods specified by both the _MyInterceptor_ and the
_MyOtherInterceptor_ classes will be invoked when the _otherMethod_
method is called. The rules for ordering these interceptors are defined
in Chapter link:intercept.html#a446[See Interceptor Ordering].
in Chapter <<interceptor_ordering>>.

[source, java]
----
Expand Down
Expand Up @@ -16,35 +16,30 @@ eligible to be invoked.

Interceptors declared using interceptor
bindings are enabled using the Priority annotation (see Section
link:intercept.html#a472[See Use of the Priority Annotation in
Ordering Interceptors]). The _Priority_ annotation also controls
interceptor ordering (see Section link:intercept.html#a453[See
Interceptor Ordering Rules]).
<<use_of_the_priority_annotation_in_ordering_interceptors>>).
The _Priority_ annotation also controls
interceptor ordering (see Section <<interceptor_ordering_rules>>).

Interceptors declared using the
_Interceptors_ annotation are enabled by that annotation. Using the
_Interceptors_ annotation to associate interceptor classes with a target
class or a method or constructor of a target class enables them for that
target class, method, or constructor. The order in which the interceptor
classes are specified in the _Interceptors_ annotation controls
interceptor ordering (see Section link:intercept.html#a453[See
Interceptor Ordering Rules]). Interceptor methods declared in the target
interceptor ordering (see Section <<interceptor_ordering_rules>>).
Interceptor methods declared in the target
class or in a superclass of the target class are enabled unless
overridden.

An extension specification may define
alternative mechanisms (e.g., a deployment descriptor such as the CDI
beans.xml link:intercept.html#a543[See
Jakarta Contexts and Dependency Injection (CDI specification), version 3.0.
https://jakarta.ee/specifications/cdi/3.0/.] or the EJB _ejb-jar.xml_
deployment descriptor link:intercept.html#a542[See Jakarta Enterprise
Beans, version 4.0.
https://jakarta.ee/specifications/enterprise-beans/4.0/.]) to
beans.xml <<bib3>> or the EJB _ejb-jar.xml_
deployment descriptor <<bib2>>) to
enable and order interceptors, to override the order specified by means
of annotations, or to disable interceptors.

Note: The _InvocationContext_ object allows
interceptor methods to control the behavior of the invocation chain,
including whether the next method in the chain is invoked and the values
of its parameters and result. See Section
link:intercept.html#a52[See InvocationContext].
<<invocation_context>>.
Expand Up @@ -73,8 +73,7 @@ _Inherited_ annotation) are combined with all binding annotations on the
target method and sorted by the priorities specified by the _Priority_
annotation; and then the interceptor methods are invoked in order of
priority. The _Priority_ annotation is described in Section
link:intercept.html#a472[See Use of the Priority Annotation in
Ordering Interceptors].
<<use_of_the_priority_annotation_in_ordering_interceptors>>.

If an interceptor class declared using
interceptor bindings has superclasses, interceptor methods declared in
Expand Down
Expand Up @@ -41,15 +41,15 @@ interceptor ordering when used with the Priority annotation.
Interceptors with lower priority values are invoked earlier in the
interceptor chain.

Interceptor.Priority.PLATFORM_BEFORE = 0
- Interceptor.Priority.PLATFORM_BEFORE = 0

Interceptor.Priority.LIBRARY_BEFORE = 1000
- Interceptor.Priority.LIBRARY_BEFORE = 1000

Interceptor.Priority.APPLICATION = 2000
- Interceptor.Priority.APPLICATION = 2000

Interceptor.Priority.LIBRARY_AFTER = 3000
- Interceptor.Priority.LIBRARY_AFTER = 3000

Interceptor.Priority.PLATFORM_AFTER = 4000
- Interceptor.Priority.PLATFORM_AFTER = 4000

These values define the following interceptor
ranges to order interceptors for a specific interposed method or event
Expand Down
Expand Up @@ -42,10 +42,8 @@ In general, an around-invoke method
invocation occurs within the same transaction and security context as
the method on which it is interposing. However, note that the
transaction context may be changed by transactional interceptor methods
in the invocation chain, such as those defined by the _Java Transaction
API_ specification link:intercept.html#a547[See Jakarta Transaction (JTA)
version 2.0.
https://jakarta.ee/specifications/transactions/2.0/.] .
in the invocation chain, such as those defined by the _Jakarta Transaction
API_ specification <<bib7>> .

The following example defines
MonitoringInterceptor, which is used to interpose on ShoppingCart
Expand Down
Expand Up @@ -18,7 +18,7 @@ class.

Any number of interceptor classes may be
associated with a target class. See Chapter
link:intercept.html#a446[See Interceptor Ordering] for rules on
<<interceptor_ordering>> for rules on
interceptor ordering.

An interceptor class must not be abstract and
Expand Down Expand Up @@ -79,23 +79,17 @@ optionally, by means of a deployment descriptor.

Interceptor classes may be associated with
the target class using either interceptor binding annotations (see
link:intercept.html#a303[See Associating Interceptors with
Classes and Methods using Interceptor Bindings]) or the
<<associating_interceptors_with_classes_and_methods_using_interceptor_bindings>>) or the
_jakarta.interceptor.Interceptors_ annotation (see
link:intercept.html#a423[See Associating Interceptors with
Classes and Methods using the Interceptors Annotation]). Typically only
<<associating_interceptors_with_classes_and_methods_using_the_interceptors_annotation>>). Typically only
one interceptor association type is used for any target class.

An extension specification may use a
deployment descriptor to specify the invocation order of interceptors or
to override the order specified in metadata annotations. A deployment
descriptor can optionally be used to define interceptors, to define
default interceptors, or to associate interceptors with a target class.
For example, the EJB specification link:intercept.html#a542[See
Jakarta Enterprise Beans, version 4.0.
https://jakarta.ee/specifications/enterprise-beans/4.0/.] requires support for the
For example, the EJB specification <<bib2>> requires support for the
ejb-jar.xml deployment descriptor and the CDI specification
link:intercept.html#a543[See
Jakarta Contexts and Dependency Injection (CDI specification), version 3.0.
https://jakarta.ee/specifications/cdi/3.0/.] requires support for the beans.xml
<<bib3>> requires support for the beans.xml
deployment descriptor.
Expand Up @@ -17,16 +17,16 @@ exceptions, but—except for around-construct methods—may not throw
checked exceptions.

In addition to the rules specified in section
link:intercept.html#a75[See Exceptions], the following rules
<<exceptions>>, the following rules
apply to the lifecycle callback interceptor methods:

A lifecycle callback interceptor method
- A lifecycle callback interceptor method
declared in an interceptor class or in a superclass of an interceptor
class may catch an exception thrown by another lifecycle callback
interceptor method in the invocation chain, and clean up before
returning.

Pre-destroy interceptor methods are not
- Pre-destroy interceptor methods are not
invoked when the target instance and the interceptors are discarded as a
result of such exceptions: the lifecycle callback interceptor methods in
the chain should perform any necessary clean-up operations as the
Expand Down
Expand Up @@ -49,7 +49,7 @@ specified on methods declared in a given class.
Lifecycle callback interceptor methods are
invoked in an unspecified security context. Lifecycle callback
interceptor methods are invoked in a transaction context determined by
their target class and/or methodlink:#a571[5].
their target class and/or method.footnote.

Lifecycle callback interceptor methods can
have _public_ , _private_ , _protected_ , or _package_ level access. A
Expand All @@ -61,9 +61,8 @@ Lifecycle callback interceptor methods
declared in an interceptor class or superclass of an interceptor class
must have one of the following signatures:

void <METHOD>(InvocationContext)

Object <METHOD>(InvocationContext)
_void <METHOD>(InvocationContext)_
_Object <METHOD>(InvocationContext)_

Note: A lifecycle callback interceptor method
may be declared to throw checked exceptions including the
Expand All @@ -76,12 +75,12 @@ Lifecycle callback interceptor methods
declared in a target class or in a superclass of a target class must
have the following signature:

void <METHOD>()
_void <METHOD>()_

The following example declares lifecycle
callback interceptor methods in both the interceptor class and the
target class. Rules for interceptor ordering are described in
link:intercept.html#a446[See Interceptor Ordering].
<<interceptor_ordering>>.

[source, java]
----
Expand Down
Expand Up @@ -51,10 +51,7 @@ _InvocationContext_ instance is otherwise unspecified.

If interceptor methods are invoked as a
result of the invocation on a web service endpoint, the map returned by
_getContextData_ will be the JAX-WS _MessageContext_
link:intercept.html#a544[See
Jakarta XML Web Services (JAX-WS 3.0) version 3.0.
https://jakarta.ee/specifications/xml-web-services/3.0/.].
_getContextData_ will be the JAX-WS _MessageContext_ <<bib4>>.

The _getTarget_ method returns the associated
target instance. For around-construct lifecycle callback interceptor
Expand Down
Expand Up @@ -14,14 +14,14 @@
The following terminology is used in this
document:

_Interceptor class_ : a class containing
- _Interceptor class_ : a class containing
interceptor methods that is designed to be associated with a target
class, method, or constructor.

_Interceptor_ : instance of an interceptor
- _Interceptor_ : instance of an interceptor
class.

_Interceptor method_ : a method of an
- _Interceptor method_ : a method of an
interceptor class or of a target class that is invoked to interpose on
the invocation of a method of the target class, a constructor of the
target class, a lifecycle event of the target class, or a timeout method
Expand Down
Expand Up @@ -18,10 +18,8 @@ NOTE: Timeout methods are currently specific
to Enterprise JavaBeans, although Timer Service functionality may be
extended to other specifications in the future, and extension
specifications may define events that may be interposed on by
around-timeout methods. The EJB Timer Service, defined by the Enterprise
JavaBeansTM specification link:intercept.html#a542[See
Jakarta Enterprise Beans, version 4.0.
https://jakarta.ee/specifications/enterprise-beans/4.0/.], is a container-provided service
around-timeout methods. The EJB Timer Service, defined by the Jakarta Enterprise
Beans specification <<bib2>>, is a container-provided service
that allows the Bean Provider to register enterprise beans for timer
callbacks according to a calendar-based schedule, at a specified time,
after a specified elapsed time, or at specified intervals. The timer
Expand Down
Expand Up @@ -19,8 +19,7 @@ enabled, the use of interceptors defined both by means of interceptor
binding annotations and by means of the _Interceptors_ annotation is
required to be supported for component classes that support injection,
as described in the section “Annotations and Injection” of the Jakarta EE
Platform specification link:intercept.html#a546[See Jakarta EE Platform 9.
https://jakarta.ee/specifications/platform/9/.].
Platform specification <<bib6>>.

Both the EJB and the CDI specifications
provide extensions to this specification. Other specifications may
Expand Down

0 comments on commit 5bdd11b

Please sign in to comment.