Skip to content

Commit

Permalink
Simplification of spec doc generation by using Asciidoc attribute ins…
Browse files Browse the repository at this point in the history
…tead of maven resource filtering.

(cherry picked from commit 1024490)
  • Loading branch information
antoinesd committed Jan 23, 2017
1 parent 2c8385f commit eee92e1
Show file tree
Hide file tree
Showing 3 changed files with 62 additions and 0 deletions.
22 changes: 22 additions & 0 deletions spec/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# CDI Specification document generation

This module contains Asciidoc sources and configuration to generate CDI documentation in HTML and PDF format
for both Apache License 2 and Java Community Process License.

## Generating the documentation

Just enter `mvn` at the command line. Maven will generate final doc in `target/publish/html` and `target/publish/docbook/publish/en-US/pdf` directories

## License in doc

The documentation can be generated for 2 licenses : Apache License v 2.0 (by default) and JCP license.
To generate doc with JCP license just enter `mvn -Pjcp`

## Working on the doc in liverelaod mode

There are helpers to ease the work on the doc. If you have ruby installed you can use bundle to install needed gems:

`bundle install`

After that, just launch `guard.sh` script to have the html version of the spec generated at each change. You may need to install the liverelaod plugin for your browser to have it relaoding automatically the generated page.

2 changes: 2 additions & 0 deletions spec/guard.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#!/usr/bin/env bash
bundle exec guard
38 changes: 38 additions & 0 deletions spec/src/main/doc/preface.asciidoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
:numbered!:
["preface",sectnum="0"]

== Preface

=== Evaluation license

include::license-{license}.asciidoc[]

=== Foreword

Contexts and Dependency Injection 1.2 is a maintenance release of Contexts and Dependency Injection 1.1 (link:https://jcp.org/en/jsr/detail?id=346[JSR-346^]).

A full changelog can be found link:https://issues.jboss.org/secure/ReleaseNote.jspa?version=12323655&styleName=Html&projectId=12311062[here^].

=== Major changes

These major changes have been introduced for CDI 1.2:

* Improvement regarding the `annotated` bean discovery mode to ensure compatibility with other JSR-330 in <<default_bean_discovery>>.
* Clarification about conversation resolution in <<conversation_context>>.
* Multiple clarifications about events and observers resolution in <<events>>.
* Clarification and restriction loosening on some `BeanManager` method calls in <<beanmanager>>.
* Clarification on the limitation of container lifecycle events use in <<init_events>>.
* Multiple clarification on the whole initialization phase ordering in <<init_events>> and <<initialization>>.

More minor changes have been introduced as well :

* Clarification about legal bean type and array in <<legal_bean_types>> and <<producer_field>>.
* Clarification on the fact that CDI built-in scope can be extended by third-party extensions in <<builtin_scopes>> and <<context>>.
* Clarification on `Iterator` returned by `Instance.iterator()` in <<dynamic_lookup>>.
* Clarification on interceptor binding on producer method in <<binding_interceptor_to_bean>>.
* Clarification on `ProcessAnnotatedType` in <<process_annotated_type>>.
* Clarification on EJB related terms or example to conform to EJB specification.
* Correction of differences between specification and Javadoc.
* Correction of wrong examples.

:numbered:

0 comments on commit eee92e1

Please sign in to comment.