[Beginners Corner] - Problem with JBoss4.2.0GA&JDK6
by cornfield
Hi guys:
I update Jboss from 4.0.5GA to 4.2.0GA today,My program runing ok with jboss4.0.5GA&JDK6,but in jboss4.2.0GA&JDK6, jboss running ok,but my program shows error when login:
java.lang.NoSuchFieldError: TRACE
| at org.jboss.logging.Log4jLoggerPlugin.isTraceEnabled(Log4jLoggerPlugin.java:85)
| at org.jboss.logging.Logger.isTraceEnabled(Logger.java:122)
| at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:620)
| at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:587)
| at javax.naming.InitialContext.lookup(InitialContext.java:392)
| at org.columba.core.gui.util.SystemDB.getSessionBeanHome(SystemDB.java:81)
| at org.columba.core.gui.util.LoginDialog$6$1.run(LoginDialog.java:222)
| at java.lang.Thread.run(Thread.java:619)
I found the method org.jboss.logging.Log4jLoggerPlugin.isTraceEnabled is diffrent between jboss4.0.5GA and jboss4.2.0GA.
org.jboss.logging.Log4jLoggerPlugin.isTraceEnabled in JBoss4.0.5GA:
public boolean isTraceEnabled()
| {
| if(!log.isEnabledFor(XLevel.TRACE))
| return false;
| else
| return XLevel.TRACE.isGreaterOrEqual(log.getEffectiveLevel());
| }
|
org.jboss.logging.Log4jLoggerPlugin.isTraceEnabled in JBoss4.2.0GA:
| public boolean isTraceEnabled()
| {
| Level l = Level.TRACE;
| if (log.isEnabledFor(l) == false)
| return false;
| return l.isGreaterOrEqual(log.getEffectiveLevel());
| }
|
Has anyone met problem like this? How can I config it? Please help me! Thanks!
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4045734#4045734
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4045734
19 years, 1 month
[JBoss Seam] - Re: @Filter example
by anescu
"fernando_jmt" wrote :
| 3.- Set somewhere a value for #{currentAccessLevel}.
|
| | Contexts.getSessionContext().set("currentAccessLevel", bestRole.getAccessLevel());
| |
|
| 4.- Finally use the filtered Persistence Context.
|
|
| | @Name("nodeDAO")
| | @AutoCreate
| | @Transactional
| | public class NodeDAO {
| |
| | // Most of the DAO methods use this
| | @In protected EntityManager restrictedEntityManager;
| | ...
| | public Node findNode(Long nodeId) {
| | restrictedEntityManager.joinTransaction();
| | try {
| | return (Node) restrictedEntityManager
| | .createQuery("select n from Node n where n.id = :nodeId")
| | .setParameter("nodeId", nodeId)
| | .getSingleResult();
| | } catch (EntityNotFoundException ex) {
| | } catch (NoResultException ex) {
| | }
| | return null;
| | }
| |
| | }
| |
| |
|
So, i did steps 1 and 2, on no 3 i have an @Out(required = false, scope = ScopeType.SESSION) which should work, but how do I use step 4? I am using a Seam generated project, i can't find anywhere a entityManager, everything is done by Seam. I suppose i have to override a method, but hell if i know which one :(.
Also, now, i tried to deploy with the code i have, i just defined my entityMAnager with this:
<core:filter name="hubFilteredChannels">
| <core:name>hubFilteredChannels</core:name>
| <core:parameters>
| <key>currentHub</key>
| <value>#{currentHub}</value>
| </core:parameters>
| </core:filter>
|
| <core:managed-persistence-context name="entityManager"
| auto-create="true"
| persistence-unit-jndi-name="java:/entityManagerFactory">
| <core:filters><value>#{hubFilteredChannels}</value></core:filters>
| </core:managed-persistence-context>
And now i get an error when loading the first page:
anonymous wrote : Caused by: org.hibernate.HibernateException: Filter [hubFilteredChannels] parameter [currentHub] value not set
So what is wrong? Why does Seam loads everything on startup??? If I have a bad page I cannot see a thing, the page redirects me to the debug page...
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4045733#4045733
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4045733
19 years, 1 month
[Clustering/JBoss] - How to Disable default clustering in JBOSS?
by mrvora
Hi,
I am new to JBOSS and having one problem. I am having client-server application made in SWT and EJB3.0. I am using EAR file named 'DB2DSPRD.ear' to deploy on the server.
The problem i am facing is that even if my local server is DOWN it goes to search another server in the LAN in which the EAR named DB2DSPRD is deployed and fetches the data. I think it is a small thing related to clustering. on the server console it shows me all the JBOSS up in the LAN like..
[DefaultPartition] I am (192.168.1.70:1099) received membershipChanged event:
[DefaultPartition] Dead members: 1 ([192.168.1.220:1099])
[DefaultPartition] New Members : 0 ([])
[DefaultPartition] All Members : 3 ([192.168.1.9:1099, 192.168.1.70:1099, 192.168.1.217:1099])
[DefaultPartition] New cluster view for partition DefaultPartition: 5539 ([192.168.1.9:1099, 192.168.1.70:1099, 192.168.1.217:1099, 192.168.1.220....
I guess i have to change or disable default clustering in some XML file..but i m not aware of the specific location.. so need help.
Regards,
Mitesh
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4045727#4045727
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4045727
19 years, 1 month