[jBPM] - jBPM3 on Sybase
by Administrator Administrator
Administrator Administrator [http://community.jboss.org/people/admin] modified the document:
"jBPM3 on Sybase"
To view the document, visit: http://community.jboss.org/docs/DOC-12936
--------------------------------------------------------------
***
#Configuration_highlights Configuration highlights
****
#Lock_scheme Lock scheme
****
#Number_of_locks Number of locks
****
#Distributed_transactions Distributed transactions
***
#Known_anomalies Known anomalies
****
#Page_size Page size
****
#Gaps_in_the_autogenerated_IDs Gaps in the auto-generated IDs
***
#Past_pests_which_may_bite_again Past pests (which may bite again)
****
#JDBC_drivers JDBC drivers
****
#Wide_table_support Wide table support
****
#Binary_datatypes Binary datatypes
h3. Configuration highlights
h4. Lock scheme
Sybase offers three http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.dc20021_125... locking schemes: allpages, datapages and datarows. The locking scheme can be indicated at table creation time, and falls back to a server-wide configuration parameter. When the server is first installed, the +lock scheme+ parameter is set to allpages. The allpages scheme may be too coarse to applications like jBPM where many small rows share a single page.
Our tests with concurrent job processing reveal that page locking is prone to deadlock. Our suggestion is converting execution and log tables to datarows locking for alleviating the incidence of deadlocks. Such a conversion is not recommended for definition tables as they are mostly read only and do not offer any gains in exchange for the extra overhead.
The locking scheme for jBPM tables created with the SQL data definition script distributed with the product can be changed on an individual basis using the alter table command.
alter table table_name
lock {allpages | datapages | datarows}
Changing the server-wide configuration parameter is not advisable in a production environment as it might impact other databases. However, should you find yourself in need for a quick fix for deadlocks in development, you can set the parameter using the *sp_configure* procedure.
sp_configure 'lock scheme', 0, datarows
h4. Number of locks
You may encounter the beast labeled http://infocenter.sybase.com/help/topic/com.sybase.dc00729_1500/html/errM... Error 1204 under heavy job execution.
04:31:30,309 WARN (main) [org.hibernate.util.JDBCExceptionReporter] SQL Error: 1204, SQLState: ZZZZZ
04:31:30,309 ERROR (main) [org.hibernate.util.JDBCExceptionReporter] ASE has run out of LOCKS. Re-run
your command when there are fewer active users, or contact a user with System Administrator (SA) role
to reconfigure ASE with more LOCKS.
The number of locks available is controlled by the configuration parameter *number of locks*. To chech the current value, call the *sp_configure* procedure.
[sybase]$ isql -Usa
Password: <sa-password>
1> sp_configure 'number of locks'
2> go
Parameter Name Default Memory Used Config Value Run Value
--------------------- ----------- ----------- ------------ -----------
number of locks 10000 1630 10000 10000
To fix the problem, try doubling the number of locks.
1> sp_configure 'number of locks', 20000
2> go
h4. Distributed transactions
Sybase 15.0.2. Developer Edition supports Distributed Transaction Management (DTM) and other features described in the http://infocenter.sybase.com/help/topic/com.sybase.infocenter.dc00468.150... Quick Installation Guide. The developer edition is available as a free download on Linux and does not require installing a license file.
Use the *sp_lmconfig* procedure to determine which edition of Adaptive Server your are running. Sybase returns EE, SE, DE or XE based on the edition.
sp_lmconfig 'edition'
DTM features are +not+ enabled by default. The instructions for enabling DTM are provided in the jConnect http://infocenter.sybase.com/help/topic/com.sybase.dc39001_0605/html/prjd... Programmer's Reference and the ASE http://infocenter.sybase.com/help/topic/com.sybase.infocenter.dc31650.150... Using DTM Features guide, and summarized here.
Enable basic DTM Features and transaction coordination with the *sp_configure* procedure. Restart Adaptive Server for the changes to take effect.
sp_configure 'enable DTM', 1
sp_configure 'enable xact coordination', 1
Grant the *dtm_tm_role* to any user who will participate in distributed transactions with the *sp_role* procedure.
sp_role 'grant', 'dtm_tm_role', 'jbpmtest'
h3. Known anomalies
h4. Page size
Sybase 15 installations have a default page size of 4KB. The page size impacts applications because it imposes a limit on the length of a record. The row size for a few jBPM tables could exceed the 4KB page size if every column was occupied in full. The DBMS warns about this potential issue after running the SQL data definition script supplied with the jBPM distribution.
Warning: Row size (14372 bytes) could exceed row size limit, which is 4012 bytes.
It is worth emphasizing that Sybase will only fail to write a record that +actually+ exceeds the size limit. In the jBPM case, the limit is unlikely to be crossed because tables with large row sizes map complete class hierarchies. Each concrete subclass occupies only a subset of the table columns.
While switching to a larger page size is unnecessary for general use, you might want to change the type of VARCHAR(4000) columns to TEXT if your application manipulates data that in fact exceeds the row size limits. According to the http://infocenter.sybase.com/help/topic/com.sybase.help.ase_15.0/title.htm documentation, Sybase stores text data in a list of pages that are separate from the rest of the table. For guidance on the type change procedure, refer to http://community.jboss.org/docs/DOC-16177 jBPM3 Text Columns.
h4. Gaps in the auto-generated IDs
Some users in the http://www.jboss.com/index.html?module=bb&op=viewtopic&t=89119 forum reported seeing a sudden jump in the generated IDs, such as
select ID_ from JBPM_PROCESSINSTANCE
1
2
3
4
5000000000000002
This is a known issue with ASE, known as the 'identity gap'. As described in an http://www.sypron.nl/idgaps.html article by Rob Verschoor on the subject:
> An 'identity gap' is a large, sudden, and unexpected jump of values in an identity column, usually as a result of a shutdown with nowait, although it can also occur as a result of certain dump/load scenarios.
Refer to the http://manuals.sybase.com/onlinebooks/group-as/asg1250e/sqlug/@Generic__B... Sybase Manuals for more information and for configuration options.
h3. Past pests (which may bite again)
h4. JDBC drivers
At least two viable driver options exist for Sybase.
* http://infocenter.sybase.com/help/topic/com.sybase.help.jconnjdbc_6.05/ti... jConnect, the driver delivered with Sybase ASE
* http://jtds.sourceforge.net/ jTDS, an open souce driver for Sybase and MS SQL
The jBPM team made extensive testing with jConnect 6.05 and jTDS 1.2.2. Both were found to be useable with jBPM 3.2.4 and up. However, jTDS failed inside the application server, due to incomplete XA support in the data source. The failure manifests itself as follows.
org.jboss.resource.JBossResourceException: Could not create connection; - nested throwable: (java.sql.SQLException: I/O Error: Unknown packet type 0x0)
at org.jboss.resource.adapter.jdbc.xa.XAManagedConnectionFactory.createManagedConnection(XAManagedConnectionFactory.java:144)
...
Caused by: java.io.IOException: Unknown packet type 0x0
at net.sourceforge.jtds.jdbc.SharedSocket.readPacket(SharedSocket.java:851)
...
h4. Wide table support
Since version 12.5, Sybase ASE provides http://infocenter.sybase.com/help/topic/com.sybase.dc39001_0605/html/prjd... wide table support, which means larger limits than in previous versions.
* Tables can contain 1,024 columns.
* varchar and varbinary columns can contain more than 255 bytes of data.
* Column names more than 30 character long.
The larger limits are relevant to jBPM in the following ways.
* Several columns have long names.
* Binary data associated to a process are stored in blocks whose size defaults to 1024 KB.
Wide table support is related to the underlying http://jtds.sourceforge.net/faq.html#longColumnNames TDS protocol version. Both jConnect and jTDS support TDS 5.0 and wide limits starting from version 6 and 0.3 respectively.
In order for wide limits to be enacted, both the server and the driver must support them. If you must use jConnect 5.5, you can still take advantage of wide table support by setting the http://infocenter.sybase.com/help/topic/com.sybase.help.jconnjdbc_5.5.prj... jConnect version to VERSION_6. Failure to do so may result in data truncation, as reported in http://jira.jboss.com/jira/browse/JBPM-703 JBPM-703.
h4. Binary datatypes
The database schema generated by Hibernate includes a few varbinary columns. The manner Sybase handles varbinary data affects jBPM as it results in data truncation in valid data being lost. From the http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.help.ase_15... Transact-SQL user guide:
> Use the variable-length binary type, +varbinary(n)+, for data that is expected to vary greatly in length. Storage size is the actual size of the data values entered, not the column length. *Trailing zeros are truncated*.
>
The above +feature+ was brought to our attention in https://jira.jboss.org/jira/browse/JBPM-702 JBPM-702. The solution consisted in restoring the truncated zeros while retrieving the binary data from Java code. Nevertheless you must be aware that the stored data is not identical to the original data.
--------------------------------------------------------------
Comment by going to Community
[http://community.jboss.org/docs/DOC-12936]
Create a new document in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=102&co...]
13 years, 8 months
[jBPM] - jBPM3 Platform Support
by Administrator Administrator
Administrator Administrator [http://community.jboss.org/people/admin] modified the document:
"jBPM3 Platform Support"
To view the document, visit: http://community.jboss.org/docs/DOC-13763
--------------------------------------------------------------
The information presented in this document applies to *release 3.2.10*.
h3. SOA Platform Releases
Below is a table showing the latest jBPM versions and their corresponding SOA Platform releases.
|| jBPM || SOA-P ||
| 3.2.10 | 5.1.0 |
| 3.2.9 | 5.0.2, 4.3 CP04 |
| 3.2.8 |
|
| 3.2.7 | 5.0.0, 5.0.1, 4.3 CP02, 4.3 CP03 |
| 3.2.6 | |
| 3.2.5 SP5 | 4.3 CP01, 4.2 CP04 |
| 3.2.5 |
|
| 3.2.4 |
|
| 3.2.3 |
|
| 3.2.2 SOA 4.2 r2494 | 4.3 GA |
| 3.2.2 SOA 4.2.0 CP03 | 4.2 CP03 |
| 3.2.2 SOA 4.2.0 CP02 | 4.2 CP02 |
| 3.2.2 |
|
h3. Operating Systems
jBPM is 100% pure Java and therefore interoperable with most operating systems capable of running a Java Virtual Machine (JVM), including Linux, UNIX and Windows.
h3. Java Virtual Machines
jBPM has been verified to run on the JVMs listed below.
* Sun JRE 1.4.2, 1.5.0 and 1.6.0
* OpenJDK 1.6.0
h3. Databases
jBPM is evaluated with the following relational database systems.
|| Database System || JDBC Driver || Dialect ||
| DB2 9.1.3 | IBM DB2 JDBC Driver 3.1.57 | org.hibernate.dialect.DB2Dialect |
| MS SQL Server 9.00.2047 | MS SQL 2005 Driver 1.2.2828.100 | org.hibernate.dialect.SQLServerDialect |
| MySQL 5.0.27 | MySQL JDBC Driver 5.0.7 | org.hibernate.dialect.MySQL5InnoDBDialect |
| PostgreSQL 8.2.3 | PostgreSQL Driver 8.2 JDBC3 (build 504) | org.hibernate.dialect.PostgreSQLDialect |
| Sybase ASE 15.0.2 | jConnect for JDBC 6.05 (Build 26023) | org.jbpm.db.hibernate.SybaseRowLockDialect |
| Oracle 10g Release 10.2.0.4.0 | Oracle JDBC Driver 10.2.0.4.0 | org.hibernate.dialect.Oracle9Dialect |
Source: http://community.jboss.org/docs/DOC-12860 jBPM3 Target Databases
h3. Containers
jBPM is compatible with the containers listed below. Bear in mind that jBPM works outside of a container as well.
|| Server || Primary JVM
||
| JBoss AS 4.0.5 | Sun JRE 1.4.2 |
| JBoss AS 4.2.3 | Sun JRE 1.5.0 |
| JBoss AS 5.0.1 | Sun JRE 1.6.0 |
| JBoss AS 5.1.0 | Sun JRE 1.6.0 |
| Tomcat 6.0 | Sun JRE 1.5.0 |
| Tomcat 5.5 | Sun JRE 1.4.2 |
Source: http://community.jboss.org/docs/DOC-12859 jBPM3 Target Containers
h3. Optional Modules
jBPM comes with the following optional modules, provided in the hope they will be useful, but without any support guarantee.
|| Module || Description ||
| Enterprise | Message and scheduler services based on JMS and EJB timers respectively |
| Simulation | Process analysis and optimization tool donated by Camunda GmbH (http://www.camunda.com/) |
--------------------------------------------------------------
Comment by going to Community
[http://community.jboss.org/docs/DOC-13763]
Create a new document in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=102&co...]
13 years, 8 months
[jBPM] - jBPM3 Deploy Web App to SOA-P
by Administrator Administrator
Administrator Administrator [http://community.jboss.org/people/admin] modified the document:
"jBPM3 Deploy Web App to SOA-P"
To view the document, visit: http://community.jboss.org/docs/DOC-16025
--------------------------------------------------------------
Until now, how to package a jBPM web application for deployment into SOA-P has been a source of confusion. In particular, it has never been clear whether the WAR should include the process definition or any jBPM libraries or configuration files. The objective of the present article is to clarify and establish a best practice.
h3. Deploy the process definition(s) separately
Process definitions, being longevous artifacts, saved in an external database and unattached to the lifecycle of the web application or the application server itself, should be deployed separately from the web application. It is advisable to deploy the process before the web app so that the application can comfortably operate under the assumption the process is available at all times.
Options for process deployment include the GPD deployment tab, the JSF console upload form and the Ant DeployProcessTask.
h3. Do not include jBPM libraries
In SOA-P, the jbpm.esb module already provides the libraries and configuration files required to run jBPM applications. Sticking with the provided versions and settings comes with the benefit of the extensive Quality Engineering effort spent by Red Hat, and prevents issues such as class loading conflicts or configuration mismatches.
h3. Give alternate configuration files a unique name
In multitenancy use cases, a single application server installation hosts separate applications which require different configurations. The suggestion here is to give each configuration file a unique name other than jbpm.cfg.xml, to avoid overriding the default configuration file provided with the platform.
--------------------------------------------------------------
Comment by going to Community
[http://community.jboss.org/docs/DOC-16025]
Create a new document in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=102&co...]
13 years, 8 months
[EJB3] - Logging Contextual Information
by Administrator Administrator
Administrator Administrator [http://community.jboss.org/people/admin] modified the document:
"Logging Contextual Information"
To view the document, visit: http://community.jboss.org/docs/DOC-12847
--------------------------------------------------------------
h4. Introduction
Informative, granular log statements are essential to any server-side application. JBoss relies on the popular Log4J framework to bring this capability to users. However, typical logging statments may not always contain enough information to truly understand what's happening.
Almost everything that happens within the scope of a Java EE service invocation -- whether it be Servlet, EJB or anything else -- has interesting context that can be useful to someone reading the log file. We might like to know the JTA Transaction ID during an EJB invocation or the name of the current user during a Servlet request. This is quite simple using Log4J, but in a busy application, you might end up with hundreds of log lines every second and have no way to correlate one flow through the application from another.
h4. Contextual Logging with Log4J
Logging something trivial from an EJB such as the number of rows returned by a query may be useful, but it would be far better if we knew what context it happened in. Most EJBs execute in within a JTA Transaction so why not add that to the log? It's relatively easy to log Transaction information at the beginning of a method:
UserTransaction utx = (UserTransaction) new InitialContext().lookup("java:/UserTransaction");
log.debug(utx.toString());
But what about container managed transactions? What if we don't want to pollute our business code with endless logging details?
Log4J includes a very useful feature called Mapped Diagnostic Contexts, or http://logging.apache.org/log4j/1.2/apidocs/org/apache/log4j/MDC.html MDC for short. MDC gives us a way to add contextual information orthogonally to the code that's actually logging information. The MDC class contains static methods used to put and remove key/value pairs which can then be accessed by the Appender through named tokens.
We can manage information in the MDC like such:
MDC.put("name", "value");
...
log.debug("Hello!");
...
MDC.remove("name");
In the above snippet, we have the option to output the value of the "name" information in the logs. To do this, we modify our conversion pattern using the %X token, specifying "name" as a parameter. By default, the Log4J configuration file resides in $JBOSS_HOME/server/<config>/conf/jboss-log4j.xml.
<layout class="org.apache.log4j.PatternLayout">
<param name="ConversionPattern" value="%d{ABSOLUTE} %-5p [%X{name}] [%c{1}] %m%n"/>
</layout>
In this example, the [%X{name}] token will result in a log line similar to this:
15:33:59,694 DEBUG [value] [MyClass] Hello!
h4. Logging Transaction ID for EJB3 Calls
Now let's do something useful with this. I mentioned earlier that it would be interesting to log the JTA Transaction ID for EJB calls. I also showed that we can do this orthogonally to our business code so as not to pollute every method with nasty references to transaction APIs. What we need now is a place to add the Transaction ID to the MDC before a call begins and remove it after it returns. For this we'll use a standard EJB3 Interceptor. Here's an example implementation:
public class LogContextInterceptor {
private static final String TX_UID_KEY = "txid";
@Resource(mappedName="java:/TransactionManager") private TransactionManager tm;
@AroundInvoke
public Object intercept(InvocationContext ctx) throws Exception {
TransactionImple tx = (TransactionImple) tm.getTransaction();
MDC.put(TX_UID_KEY, tx.get_uid());
try {
return ctx.proceed();
} finally {
MDC.remove(TX_UID_KEY);
}
}
}
Note that this implementation uses the JBoss specific Arjuna TransactionImple so is isn't portable. This class can be compiled and shipped as part of your EJB Jar. By itself, however, it won't intercept anything! Next we need a deployment descriptor that specifies that this Interceptor be appled to every method. Here's an example ejb-jar.xml:
<?xml version="1.0" encoding="UTF-8"?>
<ejb-jar version="3.0" xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd">
<assembly-descriptor>
<interceptor-binding>
<ejb-name>*</ejb-name>
<interceptor-class>org.jboss.example.logging.LogContextInterceptor</interceptor-class>
</interceptor-binding>
</assembly-descriptor>
</ejb-jar>
Don't forget to add the "txid" token to Log4J's ConversionPattern:
<layout class="org.apache.log4j.PatternLayout">
<param name="ConversionPattern" value="%d{ABSOLUTE} %-5p [%X{txid}] [%c{1}] %m%n"/>
</layout>
Now let's look at the output from a basic SLSB invocation:
16:39:10,184 INFO [7f000001:c958:48fe3ca7:124] [TransactionalServiceBean] Echoing string Hello World!
That's it! Now you've got something to tie log lines to or use as a grep token. This general pattern can be used to output anything imaginable.
--------------------------------------------------------------
Comment by going to Community
[http://community.jboss.org/docs/DOC-12847]
Create a new document in EJB3 at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=102&co...]
13 years, 8 months
[EJB3] - DNA integration with Java EE
by Administrator Administrator
Administrator Administrator [http://community.jboss.org/people/admin] modified the document:
"DNA integration with Java EE "
To view the document, visit: http://community.jboss.org/docs/DOC-12952
--------------------------------------------------------------
h2. JBoss DNA integration with enterprise services or one of possible answers to the Ultimate Question of Life, the Universe, and Everything
Well, while the answer is not that simple like *42 (http://en.wikipedia.org/wiki/42_(number))* but considering that JBoss DNA will utilize other JBoss technologies and frameworks (http://www.jboss.org/projects) it is not that complex either - the integration picture might look like following:
http://community.jboss.org/servlet/JiveServlet/showImage/102-12952-1-1073... http://community.jboss.org/servlet/JiveServlet/downloadImage/102-12952-1-...
# (#)
h3. Why Seam?
Basically it explained in short here http://seamframework.org/Home/WhySeam
Many people think that JBoss Seam is just another JSF integration framework. No, it’s not just. J
It’s all about integration infrastructure, conversation management (http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/concepts.html), various services support, and bijection (http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/concepts.html#d...). One might call it “*+universal glue for services+*” – at least in Java world.
Some advantages of using *Seam* as the core of web service layer infrastructure (from DNA prospective):
*View & presentation layer*:
- built-in support for *JSF* (generic);
- built-in support for *RichFaces* and *Facelets* (Rich JSF implementation – *AJAX**+XHTML*)
- http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/remoting.html Seam Remoting
- integration with alternative view layers (http://seamframework.org/Documentation/AlternativeViewLayersOverview): http://seamframework.org/Documentation/GWT GWT, http://seamframework.org/Documentation/Hessian Hessian, http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/wicket.html Wicket, and http://seamframework.org/Documentation/Flex Flex
+- + flexible http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/jbpm.html#d0e6504 page flow: - +stateless navigation model(+Using JSF or Seam navigation rules+)+ and +stateful navigation model (JBPM)+
- +support for reporting services: http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/itext.html iText PDF, http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/excel.html MS Excel, http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/mail.html e-mail,+
*Services layer*:
- built-in support for business processes and decisions: JBoss *Rules* (*Drools) and JBoss JBPM (http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/jbpm.html#d0e68...;
- advanced security model (http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/security.html) based on JAAS.
- Spring framework integration (http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/spring.html);
- Web services (http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/webservices.html);
- http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/rss.html RSS support;
- Flexible http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/configuration.html packaging model;
h2. View & presentation layer
I respectfully disagree with romney (DNA user interface discussion (http://www.jboss.com/index.html?module=bb&op=viewtopic&t=132054)) and not convinced that “+FLEX would be *the preferred choice* because it would support a dynamic user interface which will support a very expressive type of user interface. I[romney] believe html/Ajax have some limitation in this area especially when dealing with large amount of data/information.+”
I’m not against it as one of possible implementations but Flex may have as many limitations as any other RIA framework (http://www.hciidc.in/2008/07/21/flex-limitations/) – everything depends on a design - for example, loading millions of records at a time (instead of paging) might “kill” any even native application. Also in order to integrate with Flex some intermediate framework(s)/service(s) needs to be deployed/configured onto application server – like Granite Data Services (http://www.graniteds.org/confluence/pages/viewpage.action?pageId=229378) which adds an extra level of complexity.
On the other hand there are other ways to implement rich UI while still having it simple, maintainable and thin.
Java Server Faces technology (http://java.sun.com/javaee/javaserverfaces/) allows abstracting particular presentation format from middle tier UI controller layer and follows MVC pattern (http://java.sun.com/javaee/5/docs/tutorial/doc/bnaqd.html) - it separates model (*UIComponent*) from RenderKits which in turn allows using different render kits while still having same POJO Web controller layer.
*JSF* has flexible functionality to substitute not only different rendering kits on the fly or by configuration but also it allows plugging in *JSF phase listeners* to do custom work – e.g. invoke business rules to decide, load or create view page on the fly, etc. Other frameworks like *JBoss Seam* are going much further than that.
Different *free rendering kits exists on JSF market* – such as JBoss RichFaces (http://www.jboss.org/jbossrichfaces/) (XHTML, JS, AJAX), Facelets (https://facelets.dev.java.net/) (JSF templates + declarative composition of UI components using XHTML), XulFaces (http://xulfaces.sourceforge.net/) (JSF + XUL), project Woodstock (http://woodstock.dev.java.net/), ICESoft ICEfaces (http://www.icefaces.org/main/product/product-overview.iface), Mobile JSF (https://mobilejsf.dev.java.net/) (WML, XHTML-MP), and many more.
*JBoss RichFaces* (JSF+AJAX) is very powerful, feature rich, lightweight and simple to use AJAX framework that implements *Java Server Faces* spec and supports dynamic interface based on *JS + XHTML* – de-facto standards for dynamic web applications:
- 100+ components and UI controls (http://www.jboss.org/file-access/default/members/jbossrichfaces/freezone/...) (including but not limiting to calendar (http://livedemo.exadel.com/richfaces-demo/richfaces/calendar.jsf?c=calend...), inplace input (http://livedemo.exadel.com/richfaces-demo/richfaces/inplaceInput.jsf?c=in...) and select (http://livedemo.exadel.com/richfaces-demo/richfaces/inplaceSelect.jsf?c=i...), tree (http://livedemo.exadel.com/richfaces-demo/richfaces/tree.jsf?c=tree&tab=u...), toolbar (http://livedemo.exadel.com/richfaces-demo/richfaces/toolBar.jsf?c=toolBar...), menu (http://livedemo.exadel.com/richfaces-demo/richfaces/dropDownMenu.jsf?c=me...), tabbed panels (http://livedemo.exadel.com/richfaces-demo/richfaces/tabPanel.jsf?c=tabPan...), etc);
- http://www.jboss.org/file-access/default/members/jbossrichfaces/freezone/... Ajax-ed files upload to server (an example - http://livedemo.exadel.com/richfaces-demo/richfaces/fileUpload.jsf?c=file... http://livedemo.exadel.com/richfaces-demo/richfaces/fileUpload.jsf?c=file...)
- Plug-n-skin (http://livedemo.exadel.com/richfaces-demo/richfaces/plugnskin.jsf?c=plugn...)
- Standard JSF controls extended to support AJAX;
- drag (http://livedemo.exadel.com/richfaces-demo/richfaces/dragSupport.jsf?c=dra...) and drop (http://livedemo.exadel.com/richfaces-demo/richfaces/dragSupport.jsf?c=dro...) support.
- JQuery support (http://www.jboss.org/file-access/default/members/jbossrichfaces/freezone/...) (see example with *+Fisheye effect+* - http://livedemo.exadel.com/richfaces-demo/richfaces/jQuery.jsf?c=jQuery&t... );
- JS effects (http://livedemo.exadel.com/richfaces-demo/richfaces/effect.jsf?c=effect&t...);
-
It is very easy to develop rich UI while still having thin client (without any necessity to download any plug-ins or virtual machines). See more examples here - http://livedemo.exadel.com/richfaces-demo/richfaces/support.jsf
On the other hand, same company (http://www.exadel.com/web/portal/home) that gave us *RichFaces* and *Ajax4Jsf* – also gave another alternative - Exadel Flamingo (http://exadel.com/web/portal/flamingo) – an integration of *Flex and JavaFX* with JBoss Seam, and Exadel Fiji (http://exadel.com/web/portal/fiji) that extends JSF by allowing the use of *Flex with JSF* components and within a jsf page. See examples here - http://exadel.com/web/portal/flamingo/demo and here - http://livedemo.exadel.com/fiji-demo/
Another alternative would be to use XULFaces (http://xulfaces.sourceforge.net/) – an integration of *Java Server Faces* and XUL (http://www.mozilla.org/projects/xul/) – powerful +XML User Interface Language+ that relies on multiple existing web standards and technologies, including http://en.wikipedia.org/wiki/Cascading_Style_Sheets CSS, http://en.wikipedia.org/wiki/JavaScript JavaScript, and http://en.wikipedia.org/wiki/Document_Object_Model DOM and *integrates with native UI*. For example, XulRunner (http://en.wikipedia.org/wiki/XULRunner) might be very serious alternative to other approaches, and already used to some degree in famous IDEs like Eclipse (http://ftp.mozilla.org/pub/mozilla.org/xulrunner/eclipse/) and NetBeans (http://wiki.netbeans.org/EmbeddedBrowser) as embedded Internet browser widget.
I believe that *putting all eggs into single UI basket might be disastrous* to any project with UI functionality – a number of new RIA frameworks are emerging as we speak. Who knows, the *Java FX* might be the next killer RIA in the nearest future – based on declarative language + extremely mature MVC UI framework *Swing* + newest enhancements in deployment model, Swing and applet in JRE 6u10 (http://java.sun.com/javase/6/webnotes/6u10.html) might completely change the picture of RIA and desktop.
I don’t want to start another thread about which platform/framework is better - *that’s not the point that I’m trying to make*. My point is simple: *I believe in “AND” (integration) - in contrast with “OR” or “VS” (**segregation**)*. J
*Proper infrastructure for middle layer that rely on standards is the key to success for an enterprise application* - that will enable and simplify access to an application from different existing and new clients and let community to do any other way.
h2. Services layer
h3. Java Content Repository API (a.k.a. JSR-170 (http://jcp.org/en/jsr/detail?id=170) and JSR-283 (http://jcp.org/en/jsr/detail?id=283))
No questions here – it simple and powerful way to access hierarchical and flat content *from Java applications* using loose coupling like following:
// Get the Repository object
InitialContext ctx = ... Repository repository = (Repository)ctx.lookup("myrepo");
// Get a Credentials object
Credentials credentials = new SimpleCredentials("MyName", "MyPassword".toCharArray());
// Get a Session
Session mySession = repository.login(credentials, "MyWorkspace");
// get root node
Node root = mySession.getRootNode();
// get child node
Node node = root.getNode(“/a/b/c”);
Apache JackRabbit (http://jackrabbit.apache.org/) s a fully conforming implementation of the Content Repository for Java Technology API (JCR) and supports different deployment modes including *embedded JCR container (http://jackrabbit.apache.org/deployment-models.html)* mode. However, it has some performance limitations (in the current design) – http://wiki.apache.org/jackrabbit/Performance
One of other possible implementations might use *JBoss Cache (http://www.jboss.org/jbosscache/)* in its core – together with graph API. Sounds strange? From bird's-eye view prospective – perhaps. But closer look shows similarity in architecture: transactional tree structure of nodes (http://www.jboss.org/file-access/default/members/jbosscache/freezone/docs...) with caching, clustering (http://www.jboss.org/file-access/default/members/jbosscache/freezone/docs...) and persistence support (http://www.jboss.org/file-access/default/members/jbosscache/freezone/docs...) (*JDBCCacheLoader*, FileCacheLoader, Amazon S3 CacheLoader, ETC) out of box – it might be an excellent choice for lightweight implementation of JCR API.
Typical JBoss usage example:
// Let's get a hold of the root node.
Node rootNode = cache.getRoot();
// Remember, JBoss Cache stores data in a tree structure.
// All nodes in the tree structure are identified by Fqn objects.
Fqn peterGriffinFqn = Fqn.fromString("/griffin/peter");
// Create a new Node
Node peterGriffin = rootNode.addChild(peterGriffinFqn);
// let's store some data in the node
peterGriffin.put("isCartoonCharacter", Boolean.TRUE);
peterGriffin.put("favoriteDrink", new Beer());
It looks very similar to JCR access code example above, isn’t it?
What about applications that built using technologies other than Java? The answer is also simple –it is essential to support widely deployed open standard’s and de-facto implementations - see below.
h3. WebDAV (http://www.webdav.org/)
Despite on critique and its limitations this standard is not dead yet and might be useful by allowing external clients such as Microsoft Windows and Apple OS X to connect to, read and edit the content from JCR compliant repository. However, it has some issues in http://en.wikipedia.org/wiki/Windows_Vista Windows Vista, only the WebDAV redirector is present by default; the original "Web folders" client has been removed. The "Web folders" client is only present if the http://www.microsoft.com/downloads/details.aspx?familyid=17C36612-632E-4C... Microsoft Update for Web Folders is installed.
For example, Apache JackRabbit has http://jackrabbit.apache.org/jackrabbit-webdav-library.html WebDAV module in the form of Servlet packaged in http://jackrabbit.apache.org/jackrabbit-web-application.html WAR application – specifically http://jackrabbit.apache.org/api/1.4/org/apache/jackrabbit/webdav/jcr/JCR... JCRWebdavServerServlet.
h3. +Common Internet File System+ +(CIFS)+ support
Another possible extension for JBoss DNA is to support CIFS (http://www.samba.org/cifs/). CIFS is the standard file sharing protocol on the Microsoft Windows platform (e.g. Map Network Drive ...).
http://jcifs.samba.org/ JCIFS is a client library that implements the CIFS/SMB networking protocol in 100% Java.
*http://www.alfresco.com/products/aifs/ Alfresco JLAN* uses a virtual file system interface that allows plugging in custom file system implementation with the core server handling all of the network protocol exchange between the client and server. JLAN is Java implementation of Window's CIFS (Common Internet File System), in addition to supporting NFS and FTP.
*Apache commons VFS* provides http://commons.apache.org/vfs/filesystems.html#CIFS access to the files on a CIFS server.
h3. Service auto discovery (zero configuration networking (http://en.wikipedia.org/wiki/Zeroconf))
Federated repository works with multiple resources that require some sort of configuration and automatic discovery of services on IP networks. While it is might be difficult to enable *zeroconf* for some external resources without prior deploying some agents – it worth to at least enable auto-discovery of JBoss DNA Federated repository – it might be very important for JBoss DNA clients and for JBoss DNA itself in a scenario where DNA repository might sit on top of hierarchy of other DNA repositories. It is very likely scenario for global companies that have distributed, independently managed offices but still want to benefit from federated repository features.
*http://www.apple.com/macosx/technology/bonjour.html Bonjour*, formerly *Rendezvous*, is Apple Inc.'s trade name for its implementation of *Zeroconf*, a service discovery protocol. Bonjour locates devices such as printers, as well as other computers, and the services that those devices offer on a local network using multicast Domain Name System service records. This feature used in *iTunes* to advertise playlist.
http://www.apple.com/support/downloads/bonjourforwindows.html Bonjour for Windows includes a plug-in for Internet Explorer, so you can set up a Bonjour-enabled device without knowing its IP address.
*http://jmdns.sourceforge.net/ JmDNS* as a pure Java implementation of *mDNS/DNS-*SD might help with implementing discovery of other instances of JBoss DNA repository. It is used by http://activemq.apache.org/discovery.html Apache ActiveMQ which implements Discovery Agent to detect remote services such as remote JMS brokers.
h3. Atom based publishing service
JCR + Atom Publishing Protocol (http://www.ietf.org/rfc/rfc5023.txt) – seams to be a winning combination based on REST (http://en.wikipedia.org/wiki/Representational_State_Transfer) principles.
It is especially important for those who don’t want to use JCR or Java APIs directly.
JAX-RS (https://jsr311.dev.java.net/) (a.k.a JSR-311 (http://jcp.org/en/jsr/detail?id=311) The Java^TM^ API for RESTful Web Services) and its implementations like JBoss RestEasy (http://www.jboss.org/resteasy/), Jersey (https://jersey.dev.java.net/) plus Apache Abdera (http://incubator.apache.org/abdera/) (high performance implementation of Atom Syndication Format ( http://www.ietf.org/rfc/rfc4287.txt RFC 4287) and Atom Publishing Protocol ( http://www.ietf.org/rfc/rfc5023.txt RFC 5023) specifications) and Rome (https://rome.dev.java.net/) (+RSS 0.90, RSS 0.91 Netscape, RSS 0.91 Userland, RSS 0.92, RSS 0.93, RSS 0.94, RSS 1.0, RSS 2.0, Atom 0.3, and Atom 1.0+), will make an implementation as simple as possible.
Not to mention that RestEasy now implements Atom (http://bill.burkecentral.com/2008/11/10/jax-rs-atom-support-with-resteasy/) (thanks to Randall for pointing that out) and supports various marshallers like JAXB, JAXB +JSON.
h3. Content Management Interoperability Services API (a.k.a CMIS)
An emerging standard (http://en.wikipedia.org/wiki/Content_Management_Interoperability_Services) is a nice addition to *JCR* and *APP* way to access content repositories of any sort based on *Web Services*. It is already been supported by open source community – Alfresco CMIS (http://wiki.alfresco.com/wiki/CMIS) – is an example). Basically, it completes the picture of the repository API - JCR, Atom Publishing Protocol, and WebDAV may work together to satisfy any customer needs.
h3. Open Search
It is difficult to imagine having any sort of repository without ability to search. It is not surprising that JCR API specification has at least ¼ of entire spec space allocated for search capability. But again, what about applications that built using technologies other than Java?
The Open Search (http://www.opensearch.org/) might be the answer together with Lucene Web Service (http://lucene-ws.net/) implementation – which is a *REST-compliant Java servlet* capable of searching and managing multiple *Lucene indices via the web*. It is built upon the Atom Publishing Protocol and *conforms to the OpenSearch 1.1* standard. It sounds very promising.
h3. JBoss DNA packaging and deployment
JBoss DNA consist of lots of modules and services – so it is very important to define proper packaging that suits most of use cases and deployment models while still having small number of artifacts.
IMO, RESTful service (any other WS planned?) as well as web UI application components as well as other DNA services might be deployed in any particular combination – part of standard enterprise archive (*EAR* ) as two independent *WAR* modules + DNA JCR implementationas JBoss service archive http://community.jboss.org/docs/DOC-12212 SAR and/or as JEE standard http://java.sun.com/j2ee/connector/overview.html JCA Connector + DNA other services (EJB3 artefacts likeSLSB/SFSB, MDB, TB, etc) .
For example, Apache JackRabbit has http://jackrabbit.apache.org/jackrabbit-jca-resource-adapter.html JCA Resource Adapter and http://jackrabbit.apache.org/deployment-models.html various deployment scenarios.
Additionally, having standard packaging artefacts like above actually will enable JBoss DNA deployment onto JEE servers different from JBoss AS (for instance, if a client will require).
http://docs.codehaus.org/display/MAVENUSER/Creating+JBoss+SAR+(Service+AR... Maven has support for standard and non standard JBoss packaging artefacts – thanks to guys from Codehouse.org and http://maven.apache.org/plugins/index.html Maven plugins comunity.
h2. References
http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/ JBoss Seam 2.1.0.SP1, Builtin support for JSF and Richfaces
http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/concepts.html#d... Context Management
http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/webservices.html Webservices, REST (RestEasy integration)
http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/remoting.html ... Remoting/AJAX
http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/events.html#d0e... URL rewriting / bookmarkable pages
http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/events.html#eve... Flexible Navigation
http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/jbpm.html Support for JBPM
http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/drools.html Support for Drools
http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/spring.html Spring Framework integration
http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/groovy.html Groovy integration
http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/wicket.html Wicket integration
http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/gwt.html Google Web Toolkit integration
http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/security.html JAAS Security
http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/itext.html iText/PDF integration
http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/rss.html RSS support
http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/configuration.html Flexible packaging in JEE5 (http://docs.jboss.com/seam/2.1.0.SP1/reference/en-US/html/configuration.h...) / JSE
http://java.dzone.com/articles/flex-j2ee-developers-case-gran Flex for J2EE Developers (using Seam)
http://www.seamframework.org/Community/FlexAndSeamIntegration Flex and Seam Integration
http://livedemo.exadel.com/richfaces-demo/richfaces/support.jsf RichFaces Demo
http://exadel.com/web/portal/flamingo With Exadel Flamingo, Flex or JavaFX can be easily *glued to Seam or Spring*. And, in the future, Flamingo will be extended to provide glue for other RIA technologies.
http://www.infoq.com/news/2008/06/flamingo-flex-and-java-dev Introductory article
http://www.jamesward.com/wordpress/2008/09/05/integrating-flex-and-jsf-wi... Another article
http://exadel.com/web/portal/flamingo/demo Exadel Flamingo demo
http://demo.flamingo.exadel.com/booking/
http://livedemo.exadel.com/fiji-demo/ Exadel Fiji extends JSF by allowing the use of Flex with JSF components and within a jsf page.
--------------------------------------------------------------
Comment by going to Community
[http://community.jboss.org/docs/DOC-12952]
Create a new document in EJB3 at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=102&co...]
13 years, 8 months
[EJB3] - StarterSkeletonEclipseProject
by Administrator Administrator
Administrator Administrator [http://community.jboss.org/people/admin] modified the document:
"StarterSkeletonEclipseProject"
To view the document, visit: http://community.jboss.org/docs/DOC-12307
--------------------------------------------------------------
h3. Getting Your EJB3 Project Started
The purpose of this page is to provide a skeleton project that you can use to get an EJB3 project started quickly. It has an ANT script, Eclipse project settings, Eclipse External Tools definitions and some infrastructure like skeleton deployment descriptors and Hibernate Tools configuration files.
Use this if you are starting a brand new EJB3 project and you don't want to start from scratch.
Attached is a .zip file that contains a skeleton Eclipse project. Unzip its contents and create a new Eclipse Project with it.
Use this to get a head start putting a new EJB3 project together. This skeleton project includes:
* Eclipse .project and .classpath files so you can import this as an Eclipse project
* An ANT build script:
** Compile, clean, prepare tagets
** Package ejb-jar, war, ear targets
** Deploy/undeploy targets to deploy/undeploy the ear to JBossAS (tested on 4.0.4RC1)
** Backup target that zips up the project contents, excluding generated files
** build.properties that allow you to switch databases
** Targets that let you create, drop and insert test data to your database
** Test target that runs TestNG and puts the test results as HTML in build/test-results
* SQL scripts that you can use to create/drop a DB schema and insert test data (use this if you are starting completely from scratch and you are more comfortable building your data model first, then using the Hibernate tools to generate the EJB3 entity beans from the data model)
* Eclipse External Tools definitions that allow you to easily run the above ANT targets within the Eclipse IDE. You can find most of these in the External Tools drop down button, click "External Tools..." to see all of them.
** Backup
** Build and Deploy
** Create Database
** Purge Database
** Insert Test Data in Database
** Undeploy
** Deploy and Run (allows you to run JBossAS via ANT, as opposed to JBoss-IDE)
** Test
** et. al.
* EJB-JAR, WAR, EAR, JBossAS DataSource deployment descriptor skeletons
* Unit test infrastructure. A superclass that your test classes can extend - AbstractTestCase - that provide some convienence methods to start and shutdown the EJB3 embedded server. The build.xml has a test target that compiles all classes under test/ and any that end with Test.class will be run by TestNG.
h2. Things that are missing:
* No webapp source (an empty WAR with DDs is generated, you can use this as a starting point)
* You can grab the TestNG Eclipse plugin, but to use it you need to either put the embeddable-ejb3 jars that contain the bootstrap classes in your build class or you have to create your own TestNG debug launchers with the classpaths set up properly.
h2. Things you still need to do manually
The purpose of this project is to help you get a kickstart in creating a project that you can use to quickly begin coding your EJB3 project. There are, however, a few manual steps you still need to do:
1. Create a new Eclipse project and point the project directory to the contents of the attached zip file. This will import the project into Eclipse. Do a File->New and select Java Project. You then select the radio button "create project from existing source"
2. Create a JBoss-IDE JBoss Server Configuration called "EJB3-Server". It must point to a JBossAS server that is configured for EJB3. I tested using JBossAS 4.0.4RC1. Once you create this, you must restart Eclipse so the build classpath can pick up the JBossAS jars properly.
3. Modify build.properties to your environment - the settings should be self explanatory.
4. lib/ directories needs to get populated with the specific JDBC drivers (not shipped in the attached zip to keep the zip file very small). See the contents.txt in these directories for the names of the JDBC drivers I tested with. You also need to get the embeddable EJB3 zip and put it in lib/embeddable-ejb3. Extract jboss-ejb3.jar and put it in the same directory. See the contents.txt for more info.
5. Create a Hibernate Console Configuration and configure for your database. See etc/hibernate/(database) for the hibernate configuration files - tweak these to conform to your database settings. These are needed if you want to generate EJB3 code from an existing database schema. See the Hibernate Tools tutorials for help. If you don't plan on generating code from a database, don't worry about this step.
I think that's it - once you do these things, you can generate code using the Hibernate Tools (optional), you can build and deploy your EAR and you can run your app (using either JBoss-IDE to start JBossAS or use the ANT task to run JBossAS if you want to run outside of Eclipse) and you can run tests (which utilize the embeddable EJB3).
h2. More information
See http://www.ericgar.com/2006/10/17/eclipse-jbossas-ejb-30-setup-instructions http://www.ericgar.com/2006/10/17/eclipse-jbossas-ejb-30-setup-instructions for some more instructions on setting up with Eclipse.
--------------------------------------------------------------
Comment by going to Community
[http://community.jboss.org/docs/DOC-12307]
Create a new document in EJB3 at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=102&co...]
13 years, 8 months
[EJB3] - Configuring Applications For Both Clustered And Non Clustered Environments
by Administrator Administrator
Administrator Administrator [http://community.jboss.org/people/admin] modified the document:
"Configuring Applications For Both Clustered And Non Clustered Environments"
To view the document, visit: http://community.jboss.org/docs/DOC-13208
--------------------------------------------------------------
The aim of this wiki is to explain how to configure applications so that they can be deployed both as clustered and as non-clustered applications in the most efficient way.
h1. Do I Really Need To Do This?
It's worth noting that often, one of the reasons to deploy a clustered application in a non-clustered environment is for development purpouses. Maintaining a network where different developers are creating their clusters can be quite tricky from a multicast traffic management perspective but there're workarounds available to disable multicast traffic from landing on the network. Tricks like http://community.jboss.org/docs/DOC-10211 setting up clustering via localhost or setting clustering traffic ttl to 0 via -Djgroups.udp.ip_ttl=0, constrain multicast traffic to the local machine, hence allowing developers to run their own clusters locally without affecting others. If you feel you still need to configure your application for both clustered and non-clustered environments, please read ahead.
h1. EJB2 or EJB3 Deployments
The easiest way to get EJBs deployed in as clustered in clustered environments and as non-clustered in non-clustered environments, is to define the clustering aspect via META-INF/jboss.xml rather than using @Clustered annotation in the case of EJB3s. JBoss has the capability of substituting pieces of XML with a specific value defined as a system property. So, for example, the following META-INF/jboss.xml allows you to control whether EJBs are deployed as clustered or not depending on whether -Dmyapp.is.clustered is defined or not. If -Dmyapp.is.clustered=true is passed when the server is started up, TimeTellerEjb will be deployed as clustered. If -Dmyapp.is.clustered=false is passed or no system property is defined on startup, the EJB will be deployed as non-clustered:
<?xml version="1.0"?>
<!DOCTYPE jboss PUBLIC -//JBoss//DTD JBOSS 4.0//EN
http://www.jboss.org/j2ee/dtd/jboss_4_0.dtd>
<jboss>
<enterprise-beans>
<session>
<ejb-name>TimeTellerEjb</ejb-name>
<jndi-name>ejb/TimeTellerEjb</jndi-name>
<clustered>${myapp.is.clustered:false}</clustered>
</session>
</enterprise-beans>
</jboss>
Unfortunately, there's currently no way of defining globally whether EJBs should be deployed as clustered or non-clustered.
h1. Web Deployments
In the of case WAR deployments, the way a web application is marked as clustered is by setting <distributable/> XML configuration element in WEB-INF/web.xml. Unfortunately, <distributable/> is an empty element and hence the same trick used with EJBs cannot be used. However, there's no problem in deploying a web application marked as <distributable/> in a non-clustered environment. Worst case scenario you'll get a WARN message like this during deployment but the application will work fine:
16:32:58,567 WARN [TomcatDeployer] Failed to setup clustering, clustering disabled. NoClassDefFoundError: org/jgroups/blocks/MethodCall
--------------------------------------------------------------
Comment by going to Community
[http://community.jboss.org/docs/DOC-13208]
Create a new document in EJB3 at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=102&co...]
13 years, 8 months
[EJB3] - Clustered EJB3 Bean Serializable Requirements
by Administrator Administrator
Administrator Administrator [http://community.jboss.org/people/admin] modified the document:
"Clustered EJB3 Bean Serializable Requirements"
To view the document, visit: http://community.jboss.org/docs/DOC-13230
--------------------------------------------------------------
The aim of this wiki is to explain the clustered EJB3 bean serializable requirements that a developer must be aware of.
h2. Clustered Session Beans (SLSB & SFSB)
First of all, clustered EJB3 SLSBs or SFSBs do not need to implement Serializable. In fact, it's recommended that they don't. In the case of clustered SLSBs, no state replication occurs, so their instance variables do not even need to be Serializable. With clustered SFSBs though, the same serialization rules used for SFSB passivation apply to SFSB state replication. In other words, all non-transient instance variables that are not references to beans, sessions contexts or user transactions must be serializable, or null at replication time. For further information on the SFSB passivation (and by extension replication because in both cases the SFSB bean context needs to be serialized), please check section 4.2.1 of the EJB3 core specification.
h2. Clustered Entity Beans
These only need to be marked Serializable if the clustered entity instances are to be passed by value as a detached object (e.g., through a remote interface). Otherwise, there's no need to mark them as Serializable.
h2. Seam Booking Examples
Finally, please note that currently, clustered beans in Seam's Booking example implement Serializable but as mentioned above, there's no need to do that and in fact, it's not recommended.
--------------------------------------------------------------
Comment by going to Community
[http://community.jboss.org/docs/DOC-13230]
Create a new document in EJB3 at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=102&co...]
13 years, 8 months
[EJB3] - EJB3Q12009
by Administrator Administrator
Administrator Administrator [http://community.jboss.org/people/admin] modified the document:
"EJB3Q12009"
To view the document, visit: http://community.jboss.org/docs/DOC-13226
--------------------------------------------------------------
h1. EJB 3 Q1 2009
This document outlines the strategy and direction of EJB 3 for 2009 quarter 1 (and beyond).
All of the previously outlined strategy still aplies ( http://community.jboss.org/docs/DOC-9626 EJB3Q42007), so I won't repeat those parts here.
h2. Components
Before stepping into here keep in mind: think big, take small steps. It's better to have a small well tested component, than something large unwieldy.
h3. Core
Which immediately makes ejb3-core spring to mind. It's large, mostly untested (via unit tests) and has wicked dependencies. The breakout of ejb3-core out of AS is a success. By being in control of our own code and tests we managed to bring JBoss EJB3 to a state were it is releasable. The next step is to further clean up ejb3-core so it becomes a proper component.
h3. Cache / Pool
Part of that cleanup is the usage of ejb3-cache (/ clustered-cache) and ejb3-pool. While not a true must have, we should at least move towards a position were proper integration can take place.
For example configuration of the cache and pool objects have been left out of scope until so far. This time round we can build deployers which will create the appropriate cache/pool object from meta data and attach it into a certain scope. The container can then pick it up with a @Search or @Inject annotation.
h3. Injection
It would be nice if the injection component could be integrated with core. Also it would be better if it used the MC injection facilities. Both of these are nice to haves and one must dream.
h3. New Functionality
Other steps that need to be taking is adding functionality.
Instead of weaving functionality into an existing component, layer functionality on top of existing components. This allows existing components to not only remain backwards compatible, but effectively stay in their tested state.
In some cases this might not be possible without changing the existing component. There we should create extension points which are backwards compatible or even create new tree of components.
h2. Q1 Goals
h3. EAP 5
For JBoss Enterprise Application Platform 5 every component we have must reach GA level. In short that means it must behave predictably and be maintainable.
With the passing of all testsuites the predictability has been proven, but at the cost of maintainability. The component layout is becoming more complex and the release tools/procedures are not accommodating us.
h3. EJB 3.1
We need an alpha implementation of EJB 3.1. For this reason we'll create a new component: profile3_1. The goal of this component is to provide an EJB 3.1 profile configuration for use in JBoss Reloaded. Since Profile Service isn't ready yet, we'll use JBoss Bootstrap and 1 hard-coded bootstrap for starters.
--
Rules are meant to be broken, but the reason better be real good.
--------------------------------------------------------------
Comment by going to Community
[http://community.jboss.org/docs/DOC-13226]
Create a new document in EJB3 at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=102&co...]
13 years, 8 months