I was placing the divert in wrong part of subsystem, this can be easily achieved by running the following command using jboss-cli /subsystem=messaging/hornetq-server=default/divert=my-divert:add(divert-address=jms.topic.topic1,forwarding-address=jms.queue.queue1,exclusive=true) ...
rest,jboss,ejb,jboss7.x,java-ee-6
I am checking one of my projects using rest and in the annotation I use a slash / before the resource name both in @ApplicationPath("/rest") as in the rest service `@Path("/current"), so your EJB seems like must be something like: @Stateless @Path("/current") public class ServiceImpl { @GET public Date getCurrentDate(){...
java-ee,ejb,jboss7.x,entitymanager
As suggested by BalusC and jgitter, here is my previous edit as an answer: If you come across a similar problem feel free to bathe in my stupidity for the problem mentioned below. In the application i needed to migrate from JBoss 3.x to 7.x a number of projects were...
spring,jboss7.x,jndi,openam,opendj
If you're using Spring LDAP, the actual configuration of the ldap-context-source goes in the a spring config file, and might look like this: <jee:jndi-lookup jndi-name="ldap/idp/url" id="ldapUrl"/> <jee:jndi-lookup jndi-name="ldap/idp/userDN" id="ldapUserDN"/> <jee:jndi-lookup jndi-name="ldap/idp/password" id="ldapPassword"/> <jee:jndi-lookup jndi-name="ldap/idp/baseDN" id="ldapBaseDN"/> <ldap:context-source url="#{ldapUrl}" username="#{ldapUserDN}" password="#{ldapPassword}" base="#{ldapBaseDN}"...
You can just leave it as default ${jboss.bind.address.management:127.0.0.1}" You can pass IP address in args when you want to run JBoss. standalone-fu-ha.xml -b xx.xx.xx.xx ...
1) Remove the welcome root. In the standalone.xml set: <virtual-server name="default-host" enable-welcome-root="false"> 2) Set the context root. In your archive.war add a jboss-web.xml file in the WEB-INF folder: <?xml version="1.0"?> <jboss-web> <context-root>/</context-root> </jboss-web> 3) Set the http port to 80. In the standalone.xml change: <socket-binding name="http" port="8080"/> to <socket-binding name="http"...
There isn't a way. The web console doesn't generate CLI commands it generates DMR which is a detyped management model similar to JSON. CLI does the same thing. It takes CLI commands and converts them to DMR operations. The CLI does have tab complete which might help you. Some helpful...
I do not know exact circumstances when your server is restarted, but in case when e.g. server is shut down at 22.20 and started up at 22.35 then container is obliged to fire callback method for persistent timers after restart. As specification says (18.4.3): Any interval persistent timers or schedule...
The issue is this: java.net.BindException: Address already in use When you bind to 0.0.0.0 you are binding to all IP addresses on the host. If there is something else already bound to one of the ports that JBoss is using on any of the IP addresses you will see this...
java,security,jboss7.x,ejb-3.0,invocation
The messages you see in your log is because java.security.AccessControlException is an unchecked exception (it is a RuntimeException). When a java.lang.RuntimeException is thrown from the ejb method, the container will roll back the transaction discard the EJB Bean instance Throw the RuntimeException wrapped by javax.ejb.EJBException to the client. In JBoss...
java-ee,jboss7.x,single-sign-on,infinispan
Thanks to some clarifications by @FedericoSierra, calling super.reauthenticateFromSSO before super.invoke(request, response); solved my problem. I have attached the code below. In theory checking for request.getPrincipal() == null && ssoID != null might have been sufficient also. ClusteredSSOFailoverValve.java package com.mycompany.valve; import java.io.IOException; import javax.servlet.ServletException; import org.apache.catalina.authenticator.Constants; import org.apache.catalina.connector.Request; import...
java,jboss7.x,message,wildfly,persistent-storage
HornetQ, the JMS implementation bundled with WildFly, uses persistent storage by default. This is true at least for 8.2.0.Final, I didn't check earlier releases. "Persistent" and "database" are not synonymous. HornetQ uses the filesystem for persistence, but that shouldn't really make a difference to your application....
deployment,liferay,jboss7.x,liferay-6
Most of the tutorials say that the META-INF should be placed in the ext-impl/src or ext-impl/src/main folder. Doing so was not placing my ext-spring.xml in the jar build. Shifting the jar to ext-impl/src/main/resources helped and the META-INF was detected. Upon restarting, the changes took effect.
java,spring,maven,deployment,jboss7.x
Apparently those nodes under my web applications are Web fragments that my applications depend on. There was a Java EE configuration problem with my Web fragment (commons-web), as I wrote here. This error wasn't causing a maven build to fail but Eclipse wasn't recognising my project as a web fragment...
java,spring,spring-mvc,jboss7.x,spring-transactions
Hi the confusion was caused due to using annotations for configuring the transaction manager rather then XML. Typical XML Configuration for SpringTransaction: 1. <tx:annotation-driven /> ^It scans all beans in the application context and creates AOP interceptor for those which are annotated.This is done via the SpringTransactionAnnotationParser, which is used...
Use the following standalone.xml, this will solve your problem. <extensions> <extension module="org.jboss.as.clustering.infinispan"/> <extension module="org.jboss.as.configadmin"/> <extension module="org.jboss.as.connector"/> <extension module="org.jboss.as.deployment-scanner"/> <extension module="org.jboss.as.ee"/> <extension module="org.jboss.as.ejb3"/> <extension module="org.jboss.as.jaxrs"/> <extension module="org.jboss.as.jdr"/> <extension...
maven,deployment,jboss,jboss7.x,maven-3
After a lot of hit and trial finally I got my EAR deployed but it ran only 2 times after that it is showing me the error that EAR structure is not proper. I googled it and found that it is a bug in jBoss 7.1.1. link...
java-ee,jpa,jboss7.x,dao,jboss-arquillian
The error your posted is pretty clear, it can't find NetworkDaoLocal in your JAR. Even the deployment you shared is not including it, instead including NetworkServiceLocal
java,jboss7.x,resteasy,swagger
The problem is that you're trying to serve both the application and static context from the same resource root, and there are some technical issues behind it. I believe this SO question - JAX-RS Application on the root context - how can it be done? - refers to the same...
java,spring,rest,jboss7.x,resteasy
If you want to access Spring beans in your REST endpoint classes, then you have to integrate Spring with RestEasy, so that RestEasy is able to find your Spring beans. If you don't have this requirement, then it's not necessary.
The error that you are experiencing is because you are trying to start wildfly without being connected to the internet or with an intermittent connection. Remember that jBPM is a community project so you guys can help with the documentation to make it better. Try by removing the .niogit (hidden)...
hi did you create a module for your JDBC connections? https://developer.jboss.org/wiki/DataSourceConfigurationInAS7 if so then you need to create a module dependency in your WAR / EAR to the module create. eg in your MANIFEST.MF you should have a line: Dependencies: com.mysql See https://docs.jboss.org/author/display/AS7/Class+Loading+in+AS7 for more info....
Check if your document_library folder is actually the one that is used. I'm not 100% sure with the versions, but there are some things for you to check: If you didn't change the document library's storage location, it'll be $liferay_home/data/document_library. Some versions define $liferay_home in portal-setup-wizard.properties (or you can do...
1)create your data source in server using web console "in your example use the INDI "java:/MySqlDS" 2)take the JNDI OF Data Source that you created "java:jboss/testdatasource" Note that JNDI must start with java:/ or java:boss/ this link will help you how to create data source in jboss http://www.techpaste.com/2014/05/08/how-to-configure-datasource-in-jboss-wildfly/ 3)in your...
jboss,jboss7.x,wildfly,wildfly-8
Two solutions: 1) move java to folder that does not have spaces in it. 2) double quote path when you set it SET JAVA_HOME=""C:\Program Files\Java\jdk1.7.0_40""...
I've found 2 solutions with my problem: 1.) Move the authentication classes (picketlink) to the web layer, so that the message can be set and localized. 2.) Implement a JPA IDMConfiguration in the ejb layer. And an authentication class in the web layer. Refer to this project from github: picketlink-authorization-idm-jpa....
java,java-ee,jboss,jboss7.x,ejb-2.x
UPDATED 6 jun 2015 I am migrating from jboss 4 to 7 and yes EJB 2 is supported. Please note that class loading and JNDI names conventions have changed and you probably have to change the definition of your JNDI names and the corresponding code doing the lookup: In AS7...
jsp,servlets,jboss,jboss7.x,jsp-tags
It's get resolved after adding <module name="javax.servlet.jsp.api"/> dependency in module.xml file as shown below: <?xml version="1.0" encoding="UTF-8"?> <module xmlns="urn:jboss:module:1.1" name="com"> <resources> ... <resource-root path="jsp-api-2.1.jar"/> ... </resources> <dependencies> <module name="sun.jdk"/> <module name="javax.api"/> <module name="javax.servlet.api"/> <module name="javax.servlet.jsp.api"/> <module name="org.jboss.logging"/> <module...
java-ee,jboss,jboss7.x,wildfly,wildfly-8
You should probably set the Thread.setDaemon(true). As far as detecting if WildFly is running you could try to connect a ModelControllerClient and check the state of the server. If it doesn't connect it's likely down. Or at least the management connection is down. Example: public static boolean isServerRunning() throws IOException...
The inet-address you're looking at is for telling JBoss which IP Address to bind to, not which addresses are allowed to access the component. To address your problem of only allowing certain hosts to have access to your management console, you will require something like an Apache server fronting your...
For shared authentication across applications you must enable the Single Signon functionality. The Single Signon configuration allows a centralized login configuration for corporate sites that use different Web context. To enable SSO in JBoss7 you need add the sso option in the web subsystem (SSO is configured per host): <subsystem...
if you are using spring 3.1 then why will go for properties.read this http://docs.spring.io/spring/docs/2.5.6/reference/jms.html
java,spring,spring-mvc,jboss,jboss7.x
I was able to get this solved. It was an issue due to jboss 7. Jboss 7 doesnot have the files for javax.xml.ws.Service and hence the error. I got this resolved by adding the following dependencies to my project. <dependency> <groupId>javax.xml.ws</groupId> <artifactId>jaxws-api</artifactId> <version>2.2.8</version> </dependency> <dependency> <groupId>com.sun.xml.ws</groupId> <artifactId>jaxws-rt</artifactId> <version>2.1.4</version> </dependency>...
You can expose the XML configs in your JAR my-faces-test-0.1.jar by adding the export true tag to the jboss-deployment-structure.xml <module name="org.myfacestest.faces" export="true" meta-inf="export"/> this will expose the dependency to the EAR / WAR ...
The solution I found was to create a proprietary jboss-web.xml file in my WEB-INF directory in my WAR. In the WAR, WEB-INF/jboss-web.xml contains: <?xml version="1.0" encoding="UTF-8"?> <jboss-web> <resource-ref> <res-ref-name>jdbc/TradeDataSource</res-ref-name> <res-type>javax.sql.DataSource</res-type> <jndi-name>java:jboss/datasources/PostgreSQLDS</jndi-name> </resource-ref> </jboss-web> In the WAR, WEB-INF/web.xml contains: ... <resource-ref id="ResourceRef_1">...
Finally got it resolved: From the maven documentation Generating a manifest classpath I have set the property addClasspath to false. Now there is no warnings in the console. <manifest> <packageName>blabla</packageName> <addClasspath>false</addClasspath> .... <addExtensions>false</addExtensions> .... </manifest> ...
The most important line in the stack trace is: javax.ejb.EJBTransactionRolledbackException: org.jboss.as.jpa.container.TransactionScopedEntityManager cannot be cast to javax.persistence.criteria.CriteriaBuilder These two types are incompatible therefore casting fails. Try to replace findById method with: public List<Session> findById(int id) { CriteriaBuilder cb = em.getCriteriaBuilder(); CriteriaQuery<Session> cq = cb.createQuery(Session.class); Root<Session> e = cq.from(Session.class);...
We can set value for Protocol attribute as "TLSv1.2". But this wont work for JDK 1.6. We have to use JDK 1.7 or later.
ejb,jboss7.x,ejb-3.0,illegalstateexception,wildfly-8
The EJB proxy delivered by the container (JBOSS) passes the arguments for the respective method with type Object. Thus, if there are overloading methods maybe the proxy can't resolve wich one to call @Stateless public class TableService extends GenericService<Table> implements ITableService { @Override public void update(Table table) throws Exception {...
hibernate,jboss,ejb,jboss7.x,java-ee-6
I was able to solved this issue but not until I've changed the logging of org.jboss and org.hibernate to DEBUG mode. In my case there was an OptimisticLockException that was thrown and was wrapped that's why it was hard to figure out without the full log trace.
java,postgresql,persistence,jboss7.x,openshift
This is problem totally related to wrong clustering and messaging inside openshift settings. To fix it you will need to locate standalone.xml in .openshift/config/ and change clustering pools to lower values, along with messages pool look at the example below https://gist.github.com/sigrlami/9da34d3dd539dc6d7730...
Try with following steps: Enter to web console (http://<host>:9990) Select Profile Select Core/Logging Select Tab Handler Edit and change the log level See image below. ...
If nothing else you can make use of external entities: <!DOCTYPE domain [ <!ENTITY section1 SYSTEM "section1.xml"> ]> and then use §ion1; to include it at the appropriate place....
Your definition on standalone.xml is valid for outgoing connections to websphere MQ (send a message to a Queue). On an application we migrate from HornetQ to WebSphere we add ejb-jar.xml in your META-INF folder with something like this: <?xml version='1.0' encoding='UTF-8' ?> <ejb-jar id="ejb-jar_1" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/ejb-jar_2_1.xsd" version="2.1"> <enterprise-beans>...
Have a look at each logging.properties file in each configuration directory. You might just need to update those, once, to change the path to {jboss.server.log.dir}/server.log. Then when you start each server you'll need to specify the jboss.server.log.dir directory. ./bin/standalone.sh -Djboss.server.log.dir=$JBOSS_HOME/target/standalone8080/log There might be a clever way to handle it in...
jboss,jboss7.x,wildfly,wildfly-8
In standalone it's probably too late to set it in the configuration files. You'll need to add it to the standalone.conf or standalone.conf.bat in the JAVA_OPTS environment variable. A global property like that needs to be set before anything else attempts to use java.util.Arrays.
You can exclude the folder using # character For example: test.war #dontDeployThis file1.wave ... ... WEB-INF index.html ... jboss won't deploy dontDeployThis folder Hope it helps!...
soap,cxf,jboss7.x,ws-trust,picketlink
I found the answer, I post it here, it could help someone. You need to define a new SOAPHandler and link it to your webService endpoint. This is done by annotating the endpoint with: @HandlerChain(file = "soap-handler.xml") For example: package org.picketlink.identity.federation.app.sts; /** * imports... */ @WebServiceProvider(serviceName = "PicketLinkSTS", portName =...
Well, after some digging I found an way using JBoss CLI (just google a little about it and the special syntax called Detyped Management Model). With that in mind just call this command at the CLI: /deployment=<YOUR-EAR-NAME>.ear/subdeployment=<YOUR-WAR-NAME>.war/subsystem=\"web\"/:read-attribute(name=active-sessions) With that you can know the connected users for that specific war. This...
No, WAR files are not unpacked by default. ShrinkWrap is now used to parse the archive. If you want to edit these files, I would recommend continuing to create the myapp.war/ folder, which you can do using a maven assembly....
I couldn't find any documentation on this but it turns out to be pretty simple. Just download the driver and set it up as a module in JBoss like this. Then add a dependency to the META-INF/MANFEST.MF file of your EAR. If you're using Maven you can add something like...
web-services,java-ee,soap,jboss7.x,jboss-eap-6
The problem is bundling asm.jar in your deployment. Try remove it and add this to your jboss-deployment-structure.xml: <jboss-deployment-structure> <deployment> <dependencies> ... <module name="asm.asm" /> ... </dependencies> </deployment> </jboss-deployment-structure> See more: https://developer.jboss.org/message/823745...
According Understanding the HornetQ Wildcard Syntax: A HornetQ wildcard expression contains words delimited by the character '.' (full stop). The special characters '#' and '*' also have special meaning and can take the place of a word. The character '#' means 'match any sequence of zero or more words'. The...
Seems Red Hat doesn't recommend changing the roles after the authentication has been done. So the only solution was to logout and re-login the user with the new role.
java,hibernate,jboss,jboss7.x,wildfly
The container version of the Hibernate is given precedence over your application packaged version in Java EE conatiners. And hence the error. To avoid this situation you need to control classloading explicitly and exclude the container library. read here Basically you will need to provide a jboss-deployment-structure.xml for fine grain...
java,maven,jboss,jboss7.x,jboss-arquillian
You can use the JBoss CLI to script the configuration of your JBoss instance. You'll need to make sure you have the JAR files available somewhere though. If you create a file, e.g. module-add.cli with the following in it: module add --name=org.mysql --resources=mysql-connector-java-5.1.18-bin.jar --dependencies=javax.api,javax.transaction.api /subsystem=datasources/jdbc-driver=mysql:add(driver-module-name=org.mysql,driver-name=mysql,driver-class-name=com.mysql.jdbc.Driver)...
jboss,jboss7.x,jndi,jboss6.x,java-ee-7
I can answer doubt 2: All the names are the same thing but with different contexts. The global name is a full JNDI context that is used to bind globally, ie. from a client or from another EAR file The module name can be used to bind within the same...
jboss,jboss7.x,hibernate-search,jboss-eap-6
I fixed this by defining the lucene-core module as global. i followed this explanation: http://www.javacodegeeks.com/2012/09/jboss-as-7-classloading-explained.html
Every artifact deployed in JBoss has his own classloader. From your question it is not clear what you want to do or what is inside the jar files. In general cases web applications are deployed as war or as ear file. Both can contain different jar files and share one...
You can prepackage them inside your war under /WEB-INF/services so that they are automatically deployed with the war file. e.g. /WEB-INF /services /service_a.aar /service_b.aar /services.list The services.list file in the same directory is a text file listing your aar files ... one per line The aar files are just zipped...
java,jboss,jboss7.x,ubuntu-14.04
When changing the address and or port the server listens on you need to ensure the firewall allows that port to be accessed. Something like sudo iptables -A INPUT -p tcp --dport 9990 -j ACCEPT ...
Is this the expected behavior? Well, no. At least not as far as Java EE, JSF and EJBs are concerned. So there's that. But the project (and enough of the pom file of the new test project I used to try and triangulate the problem) is a bastard of...
You may use :read-resource-description(operations=true) and process the result in result.operations. Another option would be to use tab complete to see the list or use the operation :read-operation-names and read-operation-description to see details about a specific operation....
java-ee,jboss7.x,wildfly,jboss-eap-6
I've discovered that I need to use JMX to obtain this value as its exposed via an MBean to the JVM (verifyable via JConsole....) So answering my own question: try { ObjectName serverMBean = new ObjectName("jboss.as:management-root=server"); MBeanServer server = ManagementFactory.getPlatformMBeanServer(); String serverGroupName = (String) ManagementFactory.getPlatformMBeanServer().getAttribute(serverMBean, "serverGroup"); logger.info("JBoss server group name...
From the stack trace you posted, it seems this dependency is missing: jboss-common-jdbc-wrapper.jar Can you check if there a version of this jar on your classpath?...
To solve your issue you need to have one ear with 3 modules - 2 wars and 1 ejb. Do not include EJB in the WARs as you will have duplicates. Dependency should result only in classpath setting, not including jar in war files. Classpath entry might be created via...
maven,amazon-web-services,jboss,jboss7.x,java-ee-6
Ok I got eventually thanks to @Federico Sierra, here is the sdk-core module.xml (nb. I had to drop the commons-logging, httpclient and httpcore jars into the module folder as the ones shipped with JBoss arent compatible, I added the jackson and joda libs as their own modules)... <module xmlns="urn:jboss:module:1.1" name="com.amazonaws.aws-java-sdk-core">...
Your Jboss seems to run on JDK 7. from your log: at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_17] but you compile your source using JDK 8, so JDK7 cannot run the compiled code from JDK 8. Please add source and target when you compile the source code. e.g. javac -source 1.7 -target 1.7...
I was not able to solve this problem but I have a work-around solution and that is to move the picketlink module to the web layer and just pass the identity instance to the services that need it.
java,apache,jboss7.x,load-balancing,high-availability
The answer is mod_cluster. Currently 1.3.1.Final. loadbalancing with load calculated on the worker nodes High-Availablity in conjunction with worker clustering before the worker is contacted, either AJP cping/cpong logic takes place or OPTIONS method is sent (in case of HTTP(S)) in order to assert worker's availability seamless failover sticky sessions...
Found the answer for this. we have property as follows. message.getStringProperty("_HQ_ORIG_ADDRESS"); This property give originating address.
servlets,classpath,jboss7.x,osgi-bundle
Eventually I solved it. I had to put the right combination of settings together to reach my goal: Deploy the bundle per: File - Export - "Deployable plug-ins and fragments" into folder: "jboss/standalone/deployments" Bundle-Manifest: Bundle-SymbolicName: TestBundle Bundle-Version: 1.0.0 Export-Package: "package-which-includes-my-service" Servlet-Manifest: Dependencies: org.osgi.core,org.jboss.osgi.framework,deployment.TestBundle:1.0.0 Import-Package: "package-which-includes-my-service" ...
Actions are managed by the Struts Container. EntityManager is managed by CDI Container. You can Inject it in CDI Managed objects (EJBs in EJB Container, CDI managed beans, servlets, ecc...), but not in Actions. You need to either use the Struts2-CDI-Plugin or to perform a lookup to get it. You...
Use JAVA_OPTS_EXT instead. Remember to put trailing and leading spaces, like: export JAVA_OPTS_EXT=" -Duser.timezone=GMT " ...
dependencies,jboss7.x,noclassdeffounderror,openam,jboss-modules
The problem was that when I created my default configuration after installing openAM, I had accessed the openAM server via localhost:8181 instead of openam.example.com:8181. So openAM automatically created a Server configuration with the name localhost:8181/openam. These configurations can be found on the admin console under Configuration > Servers and sites....
jboss,environment-variables,jboss7.x,java-home
If you really want to use sudo, you have to add the -E parameter to preserve the environment variables.
authentication,ldap,jboss7.x,jsf-2.2,wildfly
i presumed that this security realms were meant to authenticate the application server console access You're partially correct there. The name="ManagementRealm" does indeed specify a realm config for accessing admin functions. name="ApplicationRealm" would be the attribute to specify for securing a web application Your current realm config is missing...
Wildfly 8 is the next iteration of the jboss application server after Jboss AS 7 / EAP 6 basically: Jboss AS 7.x = JEE6 Jboss EAP 6.x = JEE6 Wildfly 8.x = JEE7 Redhat typically backports security fixes from newer versions into older versions, Redhat also typically releases "feature packs"...
spring,intellij-idea,jboss7.x,wicket,jrebel
Change the deployment artifact from 'war' to 'war exploded' did the job.
java-ee,ejb,jboss7.x,ear,data-sharing
You could use a Singleton or ApplicationScope component holding your cache and let it inject by each application in your WARs. Alternatively, you could build a REST service around your Cache and use it by each application. But still, I would suggest not to try to build your own cache....
java,java-ee,jboss7.x,jboss5.x
@IgnoreDependency annotation on injected Beans will resolve this issue. Please Modify BeanA.java and BeanB.java as follows: BeanA.java package com.xyz; import javax.ejb.EJB; import javax.ejb.Stateless; import org.jboss.ejb3.annotation.IgnoreDependency; @Stateless public class BeanA implements BeanALocalInterface { @IgnoreDependency @EJB(name="ejb/BeanBLocalInterface") private BeanBLocalInterface beanBLocalInterface; public BeanA() {} public void executeLocal() {System.out.println("executing in BeanA"); beanBLocalInterface.executeLocal();}...
java,java-ee,jms,jboss7.x,hornetq
on jboss hornetQ is configured in the messaging domain of jboss configuration (standalone/domain.xml) <subsystem xmlns="urn:jboss:domain:messaging:1.1"> <hornetq-server> <persistence-enabled>true</persistence-enabled> [...] you can also set it on the message itself while posting it messageProducer.send(objectMessage, DeliveryMode.PERSISTENT, priority, timeToLive); also be sure that the queue is not configured with durable flag to false <jms-queue name="myQueueName">...
Put a barebones webserver in front of JBoss AS, acting as a proxy. Usually, Apache HTTPD is being used for this (you know, that server which PHP folks overgeneralize as "Apache"). Then, configure that maintenance screen as its HTTP 404/503 error page. The serveradmin should know how to do this....
java,jax-rs,jboss7.x,cdi,resteasy
You need to ensure that your application is CDI aware. Here are some of the key requirements: In JAX-RS, don't list out your classes/singletons. Allow the container to discover them. Basically create an empty Application implementation. Make sure you have a valid beans.xml Make sure your rest endpoints have a...
For correct redirect to https you need add in your web.xml (of the application mywebapp): <security-constraint> <web-resource-collection> <web-resource-name>Restricted application</web-resource-name> <url-pattern>/*</url-pattern> <http-method>GET</http-method> <http-method>POST</http-method> </web-resource-collection> <user-data-constraint> <transport-guarantee>CONFIDENTIAL</transport-guarantee> </user-data-constraint>...
java,hibernate,jboss7.x,ejb-3.2
Here's what fixed it: //grabs the primaryKeyClass from generic type argument list (this was AbstractService<PK, T>) @SuppressWarnings("unchecked") protected Class<PK> primaryKeyClass = (Class<PK>) GenericTypeResolver.resolveTypeArguments(getClass(), AbstractService.class)[0]; protected Class<PK> getPrimaryKeyClass() { return primaryKeyClass; } //code to retrieve generic list based on primary key public List<T> getEntitiesByPrimaryKey(List<PK> pks) { if(pks == null || pks.size()...
Seems to be a bug in EAP 6.2.4. Attaching the link (https://issues.jboss.org/browse/WFLY-1419).
jboss7.x,datasource,persistence.xml
I use a method that works well for hibernate. 1) put the hibernate configuration properties in a xml file (call it hibernate.cfg.xml but it's not mandatory) this is an example: <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE hibernate-configuration PUBLIC "-//Hibernate/Hibernate Configuration DTD 3.0//EN" "http://www.hibernate.org/dtd/hibernate-configuration-3.0.dtd"> <hibernate-configuration> <session-factory> <property name="hibernate.dialect">org.hibernate.dialect.PostgreSQLDialect</property>...
jboss7.x,cdi,entitymanager,jboss-weld
Error found: the EJB module was present twice in the generated EAR, once on the root path of the EAR file and a second time in the WEB-INF/lib folder of the WAR file. I changed the dependency declaration in the WAR project's POM file from: <dependency> <groupId>br.com.sigga</groupId> <artifactId>siot-mobility-ejb</artifactId> </dependency> to:...
jboss,classpath,jboss7.x,wildfly,wildfly-8
Run standalone.sh -h to see the valid options. -p is not a valid option. Besides, WildFly uses modular classloading via JBoss Modules. The classpath is almost meaningless in this context, exception for bootstrapping JBoss Modules....
You can start JBoss AS with -b 0.0.0.0 to listen on any IP. You should see a message on the console indicating it's listening on 0.0.0.0:8080. You'll also have to open port 8080 on your firewall. How you do that will be specific to your operating system....
http,jboss,jboss7.x,wildfly,wildfly-8
Support for range requests was added to undertow(web server used in WildFly) in version 1.2. Version 1.2 included in WildFly 9. WildFly 9 CR1 is out, with .Final version coming in few days. so in short, upgrade to WildFly 9...
java,spring,hibernate,transactions,jboss7.x
You probably configured a JTA DataSource in JBoss, which is a managed transactional resource and then you are using a non-JTA HibernateTransactionManager. To fix it, you have two options: You either use a RESOURCE_LOCAL DataSource and provide it via JNDI You keep the JTA DataSource and configure Hibernate to use...
You can use a ModelControllerClient and change everything you can from the CLI. Eg: ModelNode op = new ModelNode(); op.get(ClientConstants.OP).set("change-file"); //change MYHANDLER op.get(ClientConstants.OP_ADDR).set("/subsystem=logging/periodic-rotating-file-handler=MYHANDLER"); //set new file name as new_file_name.log ModelNode file = new ModelNode(); file.get("relative-to").set("jboss.server.log.dir"); file.get("path").set("new_file_name.log"); op.get("file").set(file); ModelControllerClient client =...