push notifications on all 3 platforms (android,ios,windows phone) [closed]

In Android push notification is handled by Google c2dm servers and same for iphone(Apple Servers) and Windows(MPNS). You have to register your app to all three services separately to enable push notification in your app. So while registering user you should send the the information which phone user is currently using to your server and … Read more

What is antiJARLocking attribute?

Tomcat 7 From the Tomcat 7.0 documentation for Context Configuration: “antiJARLocking – If true, the Tomcat classloader will take extra measures to avoid JAR file locking when resources are accessed inside JARs through URLs. This will impact startup time of applications, but could prove to be useful on platforms or configurations where file locking can … Read more

How to hot-reload properties in Java EE and Spring Boot?

After further research, reloading properties must be carefully considered. In Spring, for example, we can reload the ‘current’ values of properties without much problem. But, special care must be taken when resources were initialized at the context initialization time based on the values that were present in the application.properties file (e.g. Datasources, connection pools, queues, … Read more

log4j: package-specific logging

You have to create two new appenders and set additivity accordingly. log4j.appender.FRED=org.apache.log4j.RollingFileAppender log4j.appender.FRED.File=/path/to/fred.log log4j.appender.FRED.layout=org.apache.log4j.PatternLayout log4j.appender.DEREK=org.apache.log4j.RollingFileAppender log4j.appender.DEREK.File=/path/to/derek.log log4j.appender.DEREK.layout=org.apache.log4j.PatternLayout log4j.additivity.com.myname.fred=false log4j.additivity.com.myname.derek=false log4j.logger.com.myname.fred=DEBUG, FRED log4j.logger.com.myname.derek=DEBUG, DEREK Update: Just check if you need to add the below line. log4j.rootLogger=DEBUG, R, FRED, DEREK Where R is your regular log file that logs everything except FRED and DEREK.

Get specific element in a list or array using EL

You can use the brace notation [] wherein you specify the (zero-based) index of the element you’d like to retrieve. <p>This is the 3rd item of the list: #{bean.list[2]}</p> This syntax does basically the same as bean.getList().get(2). This is equivalent for arrays. <p>This is the 3rd item of the array: #{bean.array[2]}</p> This syntax does basically … Read more

Default EJB transaction mode for asynchronous methods?

Similar to an MDB the transaction is started by the container just before your @Asynchronous, @Schedule or @Timeout method (and applicable interceptors) is actually invoked and committed just after the method (and interceptors) completes. As per usual, the transaction propagates to all beans called in said method and all beans those beans call, recursively. Of … Read more

Hibernate exception _$$_javassist_0 cannot be cast to javassist.util.proxy.Proxy

I use with hibernate 4.3.5.Final and have similar problem with javassist, the problem is that javassist is missing, and you can get the latest from the Maven repositorty. <dependency> <groupId>org.javassist</groupId> <artifactId>javassist</artifactId> <version>3.18.1-GA</version> </dependency> In later editions it is fixed again With this all works in my case,

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)