[JBoss Cache] - JBossCache200Migration
by Michael Schechter
Michael Schechter [http://community.jboss.org/people/mschechter] modified the document:
"JBossCache200Migration"
To view the document, visit: http://community.jboss.org/docs/DOC-10246
--------------------------------------------------------------
This page is for users of JBoss Cache 1.x.x who wish to move to JBoss Cache 2.x.x, and talks about how things have changed, and how existing code can be migrated to the new APIs.
It is assumed that you have already read the JBoss Cache User Guide and FAQs (http://community.jboss.org/docs/DOC-12843).
*Q:* Where is TreeCache?
*A:* TreeCache, the central class in JBoss Cache 1.x.x, has been removed in favour of API access via a Cache interface. This gives the implementation more flexibility, and adds further safety by restricting the API methods exposed.
*Q:* Can Nodes be directly manipulated now, and will aspects such as locking, replication and cache loading still be applied?
*A:* Yes. JBoss Cache 1.x.x exposed Node objects but did not apply any of the JBoss Cache aspects when directly manipulating a Node. In 2.0.0 we have promoted Node to a top-level construct and it is in fact encouraged to use Nodes directly rather than operations on Cache.
*Q:* How do I create a Cache then?
*A:* Use a CacheFactory. JBoss Cache 2.0.0 ships with a DefaultCacheFactory implementation. See the http://community.jboss.org/docs/DOC-12843 User Guide for examples.
--------------------------------------------------------------
Comment by going to Community
[http://community.jboss.org/docs/DOC-10246]
Create a new document in JBoss Cache at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=102&co...]
14 years, 3 months
Re: [jboss-user] [JBoss Tools] - Extending the Eclipse Annotation Properties view
by Shane Clarke
Shane Clarke [http://community.jboss.org/people/shane_clarke] commented on
"Extending the Eclipse Annotation Properties view"
To view all comments on this blog post, visit: http://community.jboss.org/community/jbosstools/blog/2010/09/13/extending...
--------------------------------------------------
Hi Brian,
Nice post. Some good suggestions there.
Those other extension points are:
+org.eclipse.jst.ws.annotations.core.annotationProcessor+
It's used as a means to contribute annotation processors which are used for validating (JAX-WS) annotations to the APT Annotation processor factory in +org.eclipse.jst.ws.annotations.core+.
See the +org.eclipse.jst.ws.jaxws.core+ plug-in for examples on how this extension point is consumed.
+org.eclipse.jst.ws.annotations.core.annotationInitializer+
Classes contributed to this extension point can serve two purposes. The first when the annotation is being created using the view or the new bottom-up web service wizard (using CXF). The initializer can provide member value pairs for the annotation.
The second purpose is the ability to provide content assist proposals for an annotation when content assist is invoked from within the quotation marks of an annotations member string value.
See the +org.eclipse.jst.ws.jaxws.ui+ plug-in for examples there.
@Max,
Yes we can look at pulling the annotation information from the project in the workspace. Please log an enhancement request and i'll have a look into it.
Thanks guys,
Shane
--------------------------------------------------
14 years, 3 months
[EJB 3.0] - @EJB annotation for injection and lazy relations
by Nicolas Tanghe
Nicolas Tanghe [http://community.jboss.org/people/ntanghe] created the discussion
"@EJB annotation for injection and lazy relations"
To view the discussion, visit: http://community.jboss.org/message/561743#561743
--------------------------------------------------------------
Hi,
I develop a ejb3/jsf application.
I have lazy relations in my entity beans.
I remark that in my managed bean of my JSF, if I use @EJB annotation to inject session bean, I have no problem on lazy on entity beans returned by this session bean.
Example
JsfManageBean{
@EJB
Bean sessionBean ...
public void doSomething(){
Department d = sessionBean.findDepartmentBy...
// relation lazy
d.getEmployees()
-> Load of employees -> NO LAZY PROBLEM !
}
}
Someone can explain me why it works ?
For me, after the find method, my session is closed !
If I do a lookup to find my session bean (and so no injection @EJB here) -> I HAVE THE LAZY PROBLEM !
public void doSomething(){
SessionBean = ... context.lookup("blablabla")
Department d = sessionBean.findDepartmentBy...
// relation lazy
d.getEmployee()
-> LAZY EXCEPTION
thanks for help !
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/561743#561743]
Start a new discussion in EJB 3.0 at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 3 months
[JBoss Web Services] - Problem with naming an resource injection on AS 6.0.0.M4
by Frank Langelage
Frank Langelage [http://community.jboss.org/people/lafr] created the discussion
"Problem with naming an resource injection on AS 6.0.0.M4"
To view the discussion, visit: http://community.jboss.org/message/560516#560516
--------------------------------------------------------------
A WebService is using resources.
This works on 4.2.3.
On 6.0.0.M4 the deployment succeeds, but calling the URL to display the WSDL description fails.
Webservice class:
@WebService(endpointInterface = "biz.mbisoftware.fn.ws.sales.SalesOrderWSI", serviceName = "SalesOrderWS")
public class SalesOrderWS implements SalesOrderWSI
{
@Resource(mappedName = "java:/JmsXA")
private ConnectionFactory connectionFactory;
@Resource(mappedName = "queue/mbi2e-lafr-sb2000-ipc/SalesOrderImportQueue")
private Queue queue;
....
}
A look at the JNDI entries for the module containing the class above:
| | +- ws-sales
| | | +- UserTransaction[link -> UserTransaction]
| | | +- TransactionSynchronizationRegistry[link -> java:TransactionSynchronizationRegistry]
| | | +- env
| | | | +- security
| | | | | +- securityMgr[link -> java:/jaas/jboss-web-policy]
| | | | | +- subject[link -> java:/jaas/jboss-web-policy/subject]
| | | | | +- realmMapping[link -> java:/jaas/jboss-web-policy/realmMapping]
| | | | | +- security-domain[link -> java:/jaas/jboss-web-policy]
| | | | | +- authorizationMgr[link -> java:/jaas/jboss-web-policy/authorizationMgr]
| | | | +- SalesOrderImportQueue[link -> queue/mbi2e-lafr-sb2000-ipc/SalesOrderImportQueue]
| | | | +- biz.mbisoftware.fn.ws.sales.SalesOrderWS
| | | | | +- connectionFactory[link -> java:/JmsXA]
| | | | | +- queue[link -> queue/mbi2e-lafr-sb2000-ipc/SalesOrderImportQueue]
On access of the wsdl this happens
21:55:57,302 ERROR [org.jboss.wsf.common.injection.InjectionException] Resource 'connectionFactory' not found: javax.naming.NameNotFoundException: connectionFactory not bound
at org.jnp.server.NamingServer.getBinding(NamingServer.java:771) [:5.0.5.Final]
at org.jnp.server.NamingServer.getBinding(NamingServer.java:779) [:5.0.5.Final]
at org.jnp.server.NamingServer.getObject(NamingServer.java:785) [:5.0.5.Final]
at org.jnp.server.NamingServer.lookup(NamingServer.java:443) [:5.0.5.Final]
at org.jnp.server.NamingServer.lookup(NamingServer.java:399) [:5.0.5.Final]
at org.jnp.server.NamingServer.lookup(NamingServer.java:399) [:5.0.5.Final]
at org.jnp.server.NamingServer.lookup(NamingServer.java:399) [:5.0.5.Final]
at org.jnp.server.NamingServer.lookup(NamingServer.java:399) [:5.0.5.Final]
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:728) [:5.0.5.Final]
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:688) [:5.0.5.Final]
at org.jboss.wsf.common.injection.InjectionHelper.lookup(InjectionHelper.java:408) [:1.4.0.Beta2]
at org.jboss.wsf.common.injection.InjectionHelper.inject(InjectionHelper.java:390) [:1.4.0.Beta2]
at org.jboss.wsf.common.injection.InjectionHelper.injectResourceAnnotatedAccessibleObjects(InjectionHelper.java:292) [:1.4.0.Beta2]
at org.jboss.wsf.common.injection.InjectionHelper.injectResources(InjectionHelper.java:110) [:1.4.0.Beta2]
at org.jboss.wsf.stack.cxf.transport.ServletHelper.injectServiceAndHandlerResources(ServletHelper.java:120) [:3.4.0.Beta2]
at org.jboss.wsf.stack.cxf.transport.ServletHelper.initServiceEndpoint(ServletHelper.java:104) [:3.4.0.Beta2]
at org.jboss.wsf.stack.cxf.transport.ServletHelper.initEndpoint(ServletHelper.java:74) [:3.4.0.Beta2]
at org.jboss.wsf.stack.cxf.CXFNonSpringServletExt.loadBus(CXFNonSpringServletExt.java:61) [:3.4.0.Beta2]
at org.apache.cxf.transport.servlet.AbstractCXFServlet.init(AbstractCXFServlet.java:78) [:2.2.10]
at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1208) [:]
at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:955) [:]
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:188) [:]
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) [:]
at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:181) [:6.0.0-SNAPSHOT]
at org.jboss.modcluster.catalina.CatalinaContext$RequestListenerValve.event(CatalinaContext.java:285) [:1.1.0.CR3]
at org.jboss.modcluster.catalina.CatalinaContext$RequestListenerValve.invoke(CatalinaContext.java:261) [:1.1.0.CR3]
at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:88) [:6.0.0-SNAPSHOT]
at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:100) [:6.0.0-SNAPSHOT]
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127) [:]
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) [:]
at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158) [:6.0.0-SNAPSHOT]
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) [:]
at org.jboss.web.tomcat.service.request.ActiveRequestResponseCacheValve.invoke(ActiveRequestResponseCacheValve.java:53) [:6.0.0-SNAPSHOT]
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:362) [:]
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:877) [:]
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:653) [:]
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:951) [:]
at java.lang.Thread.run(Thread.java:619) [:1.6.0_21]
What's the problem?
Anything missing?
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/560516#560516]
Start a new discussion in JBoss Web Services at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 3 months