Every module that you install in Geronimo, whether it is a service, application, resource, etc., can be configured via a deployment plan. These deployment plans are XML files based on XML Schemas containing the configuration details for a specific application module or component. The Java EE specification defines standard deployment descriptors such as web.xml, application.xml, etc. The Java EE 6 specifications also allows the usage of annotations directly in the Java code to mitigate the development burdens associated with creating Java EE 5 applications.
Annotations in the Java EE specifications is a new metadata facility where many java entities such as classes, fields, packages, methods, etc. can be decorated with annotations. These declarations can reduce, and in many cases eliminate entirely, the necessity of using deployment plans. When both annotations and a declarations in a deployment plan are provided the whe declarations in the deployment plna will take precedence. This allows changes to the deployment characterics of Java EE 6 modules without having to change the code.
Geronimo as a Java EE 6 certified application server supports all the annotations in the Java EE 6 specifications. These annotations are listed and described below, along with the corresponding Java EE 6 specification, and the deployment plan XML element(s) they can replace (if applicable):
Here is a list of all Java EE 6 annotations supported by Geronimo:
JSR |
Annotation |
Deployment |
Supported in |
Notes |
|
---|---|---|---|---|---|
JSR 250 |
1. javax.annotation.Generated |
|
|
The only annotation with SOURCE retention. All the others are RUNTIME. |
|
|
2. javax.annotation.PostConstruct |
<post-construct> |
|
|
|
|
3. javax.annotation.PreDestroy |
<pre-destroy> |
|
|
|
|
4. javax.annotation.Resource |
1. <env-entry> |
|
|
|
|
4. javax.annotation.Resource |
2. <service-ref> |
|
|
|
|
4. javax.annotation.Resource |
3. <resource-ref> |
|
|
|
|
4. javax.annotation.Resource |
4. <message-destination-ref> |
|
|
|
|
4. javax.annotation.Resource |
5. <resource-env-ref> |
|
|
|
|
4. javax.annotation.Resource |
6. <webservice-context> |
|
|
|
|
5. javax.annotation.Resources |
|
|
Same as javax.annotation.Resource |
|
|
6. javax.annotation.security.DeclareRoles |
<security-role> |
|
|
|
|
7. javax.annotation.security.DenyAll |
<exclude-list> |
|
|
|
|
8. javax.annotation.security.PermitAll |
<method-permission> |
|
|
|
|
9. javax.annotation.security.RolesAllowed |
<role-name> |
|
|
|
|
10. javax.annotation.security.RunAs |
<run-as> |
|
|
|
|
11. javax.annotation.sql.DataSourceDefinition |
<data-source> |
|
|
|
|
12. javax.annotation.sql.DataSourceDefinitions |
|
|
Same as javax.annotation.sql.DataSourceDefinition |
|
|
13. javax.annotation.ManagedBean |
<managed-bean> |
|
|
|
JSR |
Annotation |
Deployment |
Supported in |
Notes |
|
JSR-315 |
1. javax.servlet.annotation.HandlesType |
<activation-config-property> |
|
|
|
|
2. javax.servlet.annotation.HttpConstraint |
<auth-constraint> |
|
|
|
|
3. javax.servlet.annotation.HttpMethodConstraint |
<user-data-constraint> |
|
|
|
|
4. javax.servlet.annotation.multipartConfig |
<multipart-config> |
|
|
|
|
5. javax.servlet.annotation.ServletSecurity |
<security-constraint> |
|
|
|
|
6. javax.servlet.annotation.WebFilter |
<filter> |
|
|
|
|
7. javax.servlet.annotation.WebInitParam |
<init-param> |
|
|
|
|
8. javax.servlet.annotation.WebListener |
<listener> |
|
|
|
|
9. javax.servlet.annotation.WebServlet |
<servlet-mapping> |
|
|
|
JSR |
Annotation |
Deployment |
Supported in |
Notes |
|
JSR-318 |
1. javax.ejb.AccessTimout |
<access-timeout> |
|
|
|
|
2. javax.ejb.ActivationConfigProperty |
<activation-config-property> |
|
|
|
|
3. javax.ejb.AfterBegin |
|
|
|
|
|
4. javax.ejb.ApplicationException |
<application-exception> |
|
|
|
|
5. javax.ejb.Asynchronous |
|
|
|
|
|
6. javax.ejb.BeforeCompletion |
|
|
|
|
|
7. javax.ejb.ConcurrencyManagement |
|
|
|
|
|
8. javax.ejb.DependsOn |
|
|
|
|
|
9. javax.ejb.EJB |
1. <ejb-ref> |
|
|
|
|
9. javax.ejb.EJB |
2. <ejb-local-ref> |
|
|
|
|
10. javax.ejb.EJBs |
|
|
Same as javax.ejb.EJB |
|
|
11. javax.ejb.Init |
<init-method> |
|
|
|
|
12. javax.ejb.Local |
<local> |
|
|
|
|
13. javax.ejb.LocalBean |
|
|
|
|
|
14. javax.ejb.LocalHome |
<local-home> |
|
|
|
|
15. javax.ejb.Lock |
|
|
|
RAR |
|
16. javax.ejb.MessageDriven |
<message-driven> |
|
|
|
|
17. javax.ejb.PostActivate |
<post-activate> |
|
|
|
|
18. javax.ejb.PrePassivate |
<pre-passivate> |
|
|
|
|
19. javax.ejb.Remote |
<remote> |
|
|
|
|
20. javax.ejb.RemoteHome |
<remote-home> |
|
|
|
|
21. javax.ejb.Remove |
<remote-method> |
|
|
|
|
22. javax.ejb.Schedule |
|
|
|
|
|
23. javax.ejb.Schedules |
|
|
|
|
|
24. javax.ejb.Singleton |
|
|
|
|
|
25. javax.ejb.Startup |
|
|
|
|
|
26. javax.ejb.Stateful |
<stateful> |
|
|
|
|
27. javax.ejb.StatefulTimout |
|
|
|
|
|
28. javax.ejb.Stateless |
<stateless> |
|
|
|
|
29. javax.ejb.Timeout |
<timeout-method> |
|
|
|
|
30. javax.ejb.TransactionAttribute |
<container-transaction> |
|
|
|
|
31. javax.ejb.TransactionManagement |
<transaction-type> |
|
|
|
JSR |
Annotation |
Deployment |
Supported in |
Notes |
|
JSR-318 |
1. javax.interceptor.AroundInvoke |
<around-invoke> |
|
|
|
|
2. javax.interceptor.AroundTimeout |
<around-timeout> |
|
|
|
|
3. javax.interceptor.ExcludeClassInterceptors |
<exclude-class-interceptors> |
|
|
|
|
4. javax.interceptor.ExcludeDefaultInterceptors |
<exclude-default-interceptors> |
|
|
|
|
5. javax.interceptor.Interceptor |
<interceptor> |
|
|
|
|
5. javax.interceptor.Interceptor |
<interceptor-class> |
|
|
|
|
6. javax.interceptor.InterceptorBinding |
<interceptor-binding> |
|
|
|
|
7. javax.interceptor.Interceptors |
<interceptors> |
|
|
|
JSR |
Annotation |
Deployment |
Supported in |
Notes |
|
JSR-317 |
1. javax.persistence.Access |
|
|
|
|
|
2. javax.persistence.AssociationOverride |
|
|
|
|
|
3. javax.persistence.AssociationOverrides |
|
|
Same as javax.persistence.AssociationOverride |
|
|
4. javax.persistence.AttributeOverride |
|
|
|
|
|
5. javax.persistence.AttributeOverrides |
|
|
Same asjavax.persistence.AttributeOverride |
|
|
6. javax.persistence.Basic |
|
|
|
|
|
7. javax.persistence.Cacheable |
|
|
|
|
|
8. javax.persistence.CollectionTable |
|
|
|
|
|
9. javax.persistence.Column |
|
|
|
|
|
10. javax.persistence.ColumnResult |
|
|
|
|
|
11. javax.persistence.DiscriminatorColumn |
|
|
|
|
|
12. javax.persistence.DiscriminatorValue |
|
|
|
|
|
13. javax.persistence.ElementCollection |
|
|
|
|
|
14. javax.persistence.Embeddable |
|
|
|
|
|
15. javax.persistence.Embedded |
|
|
|
|
|
16. javax.persistence.EmbeddedId |
|
|
|
|
|
17. javax.persistence.Entity |
|
|
|
|
|
18. javax.persistence.EntityListeners |
|
|
|
|
|
19. javax.persistence.EntityResult |
|
|
|
|
|
20. javax.persistence.Enumerated |
|
|
|
|
|
21. javax.persistence.ExcludeDefaultListeners |
|
|
|
|
|
22. javax.persistence.ExcludeSuperclassListeners |
|
|
|
|
|
23. javax.persistence.FieldResult |
|
|
|
|
|
24. javax.persistence.GeneratedValue |
|
|
|
|
|
25. javax.persistence.Id |
|
|
|
|
|
26. javax.persistence.IdClass |
|
|
|
|
|
27. javax.persistence.Inheritance |
|
|
|
|
|
28. javax.persistence.JoinColumn |
|
|
|
|
|
29. javax.persistence.JoinColumns |
|
|
Same as javax.persistence.JoinColumn |
|
|
30. javax.persistence.JoinTable |
|
|
|
|
|
31. javax.persistence.Lob |
|
|
|
|
|
32. javax.persistence.ManyToMany |
|
|
|
|
|
33. javax.persistence.ManyToOne |
|
|
|
|
|
34. javax.persistence.MapKey |
|
|
|
|
|
35. javax.persistence.MapKeyColumn |
|
|
|
|
|
36. javax.persistence.MapKeyEnumerated |
|
|
|
|
|
37. javax.persistence.MapKeyJoinColumn |
|
|
|
|
|
38. javax.persistence.MapKeyJoinColumns |
|
|
|
|
|
39. javax.persistence.MapKeyTemporal |
|
|
|
|
|
40. javax.persistence.MappedSuperclass |
|
|
|
|
|
41. javax.persistence.MapsId |
|
|
|
|
|
42. javax.persistence.NamedNativeQueries |
|
|
|
|
|
43. javax.persistence.NamedNativeQuery |
|
|
|
|
|
44. javax.persistence.NamedQueries |
|
|
|
|
|
45. javax.persistence.NamedQuery |
|
|
|
|
|
46. javax.persistence.OneToMany |
|
|
|
|
|
47. javax.persistence.OneToOne |
|
|
|
|
|
48. javax.persistence.OrderBy |
|
|
|
|
|
49. javax.persistence.OrderColumn |
|
|
|
|
|
50. javax.persistence.PersistenceContext |
<persistence-context-ref> |
|
|
|
|
51. javax.persistence.PersistenceContexts |
|
|
Same as javax.persistence.PersistenceContext |
|
|
52. javax.persistence.PersistenceProperty |
<persistence-property> |
|
|
|
|
53. javax.persistence.PersistenceUnit |
<persistence-unit-ref> |
|
|
|
|
54. javax.persistence.PersistenceUnits |
|
|
Same as javax.persistence.PersistenceUnits |
|
|
55. javax.persistence.PostLoad |
|
|
|
|
|
56. javax.persistence.PostPersist |
|
|
|
|
|
57. javax.persistence.PostRemove |
|
|
|
|
|
58. javax.persistence.PostUpdate |
|
|
|
|
|
59. javax.persistence.PrePersist |
|
|
|
|
|
60. javax.persistence.PreRemove |
|
|
|
|
|
61. javax.persistence.PreUpdate |
|
|
|
|
|
62. javax.persistence.PrimaryKeyJoinColumn |
|
|
|
|
|
63. javax.persistence.PrimaryKeyJoinColumns |
|
|
Same as javax.persistence.PrimaryKeyJoinColumn |
|
|
64. javax.persistence.QueryHint |
|
|
|
|
|
65. javax.persistence.SecondaryTable |
|
|
|
|
|
66. javax.persistence.SecondaryTables |
|
|
Same as javax.persistence.SecondaryTable |
|
|
67. javax.persistence.SequenceGenerator |
|
|
|
|
|
68. javax.persistence.SqlResultSetMapping |
|
|
|
|
|
69. javax.persistence.SqlResultSetMappings |
|
|
Same as javax.persistence.SqlResultSetMapping |
|
|
70. javax.persistence.Table |
|
|
|
|
|
71. javax.persistence.TableGenerator |
|
|
|
|
|
72. javax.persistence.Temporal |
|
|
|
|
|
73. javax.persistence.Transient |
|
|
|
|
|
74. javax.persistence.UniqueConstraint |
|
|
|
|
|
75. javax.persistence.Version |
|
|
|
|
|
76. javax.persistence.metamodel.StaticMetamodel |
|
|
|
|
JSR |
Annotation |
Deployment |
Supported in |
Notes |
|
JSR-181 |
1. javax.faces.application.ResourceDependencies |
|
|
|
|
|
2. javax.faces.application.ResourceDependency |
|
|
|
|
|
3. javax.faces.bean.ApplicationScoped |
<scope> |
|
|
|
|
4. javax.faces.bean.CustomScoped |
|
|
|
|
|
5. javax.faces.bean.ManagedBean |
<managed-bean> |
|
|
|
|
6. javax.faces.bean.ManagedProperty |
<managed-property> |
|
|
|
|
7. javax.faces.bean.NoneScoped |
|
|
|
|
|
8. javax.faces.bean.ReferencedBean |
<referenced-bean> |
|
|
|
|
9. javax.faces.bean.RequestScoped |
<scope> |
|
|
|
|
10. javax.faces.bean.SessionScoped |
<scope> |
|
|
|
|
11. javax.faces.bean.ViewScoped |
|
|
|
|
|
12. javax.faces.component.FacesBehavior |
|
|
|
|
|
13. javax.faces.component.FacesComponent |
<component> |
|
|
|
|
15. javax.faces.convert.FacesConverter |
<f:converter> |
|
|
|
|
16. javax.faces.event.ListenerFor |
|
|
|
|
|
17. javax.faces.event.ListenersFor |
|
|
Same as javax.faces.event.ListenerFor |
|
|
18. javax.faces.event.NamedEvent |
<f:event> |
|
|
|
|
19. javax.faces.render.FacesBehaviorRenderer |
<client-behavior-renderer> |
|
|
|
|
20. javax.faces.render.FacesRenderer |
<render> |
|
|
|
|
21. javax.faces.validator.FacesValidator |
<f:validator> |
|
|
|
JSR |
Annotation |
Deployment |
Supported in |
Notes |
|
JSR-303 |
1. javax.faces.bean.ApplicationScoped |
|
|
|
|
|
1. javax.validation.constraints.Null |
|
|
|
|
|
2. javax.validation.constraints.NotNull |
|
|
|
|
|
3. javax.validation.constraints.AssertTrue |
|
|
|
|
|
4. javax.validation.constraints.AssertFalse |
|
|
|
|
|
5. javax.validation.constraints.Min |
|
|
|
|
|
6. javax.validation.constraints.Max |
|
|
|
|
|
7. javax.validation.constraints.DecimalMin |
|
|
|
|
|
8. javax.validation.constraints.DecimalMax |
|
|
|
|
|
9. javax.validation.constraints.Size |
|
|
|
|
|
10. javax.validation.constraints.Digits |
|
|
|
|
|
11. javax.validation.constraints.Past |
|
|
|
|
|
12. javax.validation.constraints.Future |
|
|
|
|
|
13. javax.validation.constraints.Pattern |
|
|
|
|
JSR |
Annotation |
Deployment |
Supported in |
Notes |
|
JSR-299 |
1. javax.enterprise.inject.Alternative |
|
|
|
|
|
2. javax.enterprise.inject.Any |
|
|
|
|
|
3. javax.enterprise.inject.Default |
|
|
|
|
|
4. javax.enterprise.inject.Disposes |
|
|
|
|
|
5. javax.enterprise.inject.Model |
|
|
|
|
|
6. javax.enterprise.inject.New |
|
|
|
|
|
7. javax.enterprise.inject.Procedures |
|
|
|
|
|
8. javax.enterprise.inject.Specializes |
|
|
|
|
|
9. javax.enterprise.inject.Stereotype |
|
|
|
|
|
10. javax.enterprise.inject.Typed |
|
|
|
|
JSR |
Annotation |
Deployment |
Supported in |
Notes |
|
JSR-330 |
1. javax.inject.Inject |
|
|
|
|
|
2. javax.inject.Named |
|
|
|
|
|
3. javax.inject.Qualifier |
|
|
|
|
|
4. javax.inject.Scope |
|
|
|
|
|
5. javax.inject.Singleton |
|
|
|
|
JSR |
Annotation |
Deployment |
Supported in |
Notes |
|
JSR-318 |
1. javax.interceptor.AroundInvoke |
<around-invoke> |
|
|
|
|
2. javax.interceptor.AroundTimeout |
|
|
|
|
|
3. javax.interceptor.ExcludeClassInterceptors |
<exclude-class-interceptors> |
|
|
|
|
4. javax.interceptor.ExcludeDefaultInterceptors |
<exclude-default-interceptors> |
|
|
|
|
5. javax.interceptor.Interceptor |
<interceptor> |
|
|
|
|
6. javax.interceptor.InterceptorBinding |
|
|
|
|
|
7. javax.interceptor.Interceptors |
<interceptors> |
|
|
|
JSR |
Annotation |
Deployment |
Supported in |
Notes |
|
JSR-332 |
1. javax.ws.rs.Activation |
<activationspec> |
|
|
|
|
2. javax.resource.spi.AdministeredObject |
<adminobject> |
|
|
|
|
3. javax.resource.spi.AuthenticationMechanism |
<authentication-mechanism> |
|
|
|
|
4. javax.resource.spi.ConfigProperty |
<config-property> |
|
|
|
|
5. javax.resource.spi.ConnectionDefinition |
<connection-definition> |
|
|
|
|
6. javax.resource.spi.ConnectionDefinitions |
|
|
Same as javax.resource.spi.ConnectionDefinition |
|
|
7. javax.resource.spi.Connector |
<connector> |
|
|
|
|
8. javax.resource.spi.SecurityPermission |
<security-permission> |
|
|
|
JSR |
Annotation |
Deployment |
Supported in |
Notes |
|
JSR-311 |
1. javax.ws.rs.ApplicationPath |
|
|
|
|
|
2. javax.ws.rs.Consumes |
|
|
|
|
|
3. javax.ws.rs.CookieParam |
|
|
|
|
|
4. javax.ws.rs.DefautValue |
|
|
|
|
|
5. javax.ws.rs.DELETE |
|
|
|
|
|
6. javax.ws.rs.Encoded |
|
|
|
|
|
7. javax.ws.rs.FormParam |
|
|
|
|
|
8. javax.ws.rs.GET |
|
|
|
|
|
9. javax.ws.rs.HEAD |
|
|
|
|
|
10. javax.ws.rs.HeaderParam |
|
|
|
|
|
11. javax.ws.rs.HttpMethod |
|
|
|
|
|
12. javax.ws.rs.MatrixParam |
|
|
|
|
|
13. javax.ws.rs.OPTIONS |
|
|
|
|
|
14. javax.ws.rs.Path |
|
|
|
|
|
15. javax.ws.rs.PathParam |
|
|
|
|
|
16. javax.ws.rs.POST |
|
|
|
|
|
17. javax.ws.rs.Produces |
|
|
|
|
|
18. javax.ws.rs.PUT |
|
|
|
|
|
19. javax.ws.rs.QueryParam |
|
|
|
|
|
20. javax.ws.rs.core.Context |
|
|
|
|
|
21. javax.ws.rs.Provider |
|
|
|
|
JSR |
Annotation |
Deployment |
Supported in |
Notes |
|
JSR-181 |
1. javax.jws.HandlerChain |
<handler-chain> |
|
|
|
|
2. javax.jws.Oneway |
|
|
|
|
|
3. javax.jws.WebMethod |
|
|
|
|
|
4. javax.jws.WebParam |
|
|
|
|
|
5. javax.jws.WebResult |
|
|
|
|
|
6. javax.jws.WebService |
<service-ref-type> |
|
|
|
|
7. javax.jws.soap.InitParam |
|
|
|
|
|
8. javax.jws.soap.SOAPBinding |
|
|
|
|
|
9. javax.jws.soap.SOAPMessageHandler |
|
|
|
|
|
10. javax.jws.soap.SOAPMessageHandlers |
|
|
Same as javax.jws.soap.SOAPMessageHandler |
|
JSR |
Annotation |
Deployment |
Supported in |
Notes |
|
JSR-222 |
1. javax.xml.bind.annotation.XmlAccessorOrder |
|
|
|
|
|
2. javax.xml.bind.annotation.XmlAccessorType |
|
|
|
|
|
3. javax.xml.bind.annotation.XmlAnyAttribute |
|
|
|
|
|
4. javax.xml.bind.annotation.XmlAnyElement |
|
|
|
|
|
5. javax.xml.bind.annotation.XmlAttachmentRef |
|
|
|
|
|
6. javax.xml.bind.annotation.XmlAttribute |
|
|
|
|
|
7. javax.xml.bind.annotation.XmlElement |
|
|
|
|
|
8. javax.xml.bind.annotation.XmlElementDecl |
|
|
|
|
|
9. javax.xml.bind.annotation.XmlElementRef |
|
|
|
|
|
10. javax.xml.bind.annotation.XmlElementRefs |
|
|
Same as javax.xml.bind.annotation.XmlElementRef |
|
|
11. javax.xml.bind.annotation.XmlElementWrapper |
|
|
|
|
|
12. javax.xml.bind.annotation.XmlElements |
|
|
Same as javax.xml.bind.annotation.XmlElement |
|
|
13. javax.xml.bind.annotation.XmlEnum |
|
|
|
|
|
14. javax.xml.bind.annotation.XmlEnumValue |
|
|
|
|
|
15. javax.xml.bind.annotation.XmlID |
|
|
|
|
|
16. javax.xml.bind.annotation.XmlIDREF |
|
|
|
|
|
17. javax.xml.bind.annotation.XmlInlineBinaryData |
|
|
|
|
|
18. javax.xml.bind.annotation.XmlList |
|
|
|
|
|
19. javax.xml.bind.annotation.XmlMimeType |
|
|
|
|
|
20. javax.xml.bind.annotation.XmlMixed |
|
|
|
|
|
21. javax.xml.bind.annotation.XmlNs |
|
|
|
|
|
22. javax.xml.bind.annotation.XmlRegistry |
|
|
|
|
|
23. javax.xml.bind.annotation.XmlRootElement |
|
|
|
|
|
24. javax.xml.bind.annotation.XmlSchema |
|
|
|
|
|
25. javax.xml.bind.annotation.XmlSchemaType |
|
|
|
|
|
26. javax.xml.bind.annotation.XmlSchemaTypes |
|
|
Same as javax.xml.bind.annotation.XmlSchemaType |
|
|
27. javax.xml.bind.annotation.XmlTransient |
|
|
|
|
|
28. javax.xml.bind.annotation.XmlType |
|
|
|
|
|
29. javax.xml.bind.annotation.XmlValue |
|
|
|
|
|
30. javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter |
|
|
|
|
|
31. javax.xml.bind.annotation.adapters.XmlJavaTypeAdapters |
|
|
Same as javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter |
|
JSR |
Annotation |
Deployment |
Supported_in |
Notes |
|
JSR-224 |
1. javax.xml.ws.BindingType |
|
|
|
|
|
2. javax.xml.ws.RequestWrapper |
|
|
|
|
|
3. javax.xml.ws.ResponseWrapper |
|
|
|
|
|
4. javax.xml.ws.ServiceMode |
|
|
|
|
|
5. javax.xml.ws.WebEndpoint |
|
|
|
|
|
6. javax.xml.ws.WebFault |
|
|
|
|
|
7. javax.xml.ws.WebServiceClient |
|
|
|
|
|
8. javax.xml.ws.WebServiceProvider |
|
|
|
|
|
9. javax.xml.ws.WebServiceRef |
<service-ref> |
|
|
|
|
10. javax.xml.ws.WebServiceRefs |
|
|
Same as javax.xml.ws.WebServiceRef |
|
|
11. javax.xml.ws.addressing.Action |
|
|
|
|
|
12. javax.xml.ws.addressing.FaultAction |
|
|
|