13 Ekim 2010 Çarşamba

22 Temmuz 2010 Perşembe

logging in java apps

for starter, lets begin with java.util.logging..

http://www.java-tips.org/java-se-tips/java.util.logging/how-to-use-logger.html
http://www.rgagnon.com/javadetails/java-0501.html
http://www.roseindia.net/java/example/java/util/quintessential-logging-program.shtml

and log4j..
http://logging.apache.org/log4j/1.2/manual.html
http://www.basilv.com/psd/blog/2006/tips-for-using-log4j
http://homepage.mac.com/kelleherk/iblog/C1837526061/E2136921646/index.html

the interface:

package org.apache.log4j;

public class Logger {

// Creation & retrieval methods:
public static Logger getRootLogger();
public static Logger getLogger(String name);

// printing methods:
public void trace(Object message);
public void debug(Object message);
public void info(Object message);
public void warn(Object message);
public void error(Object message);
public void fatal(Object message);

// generic printing method:
public void log(Level l, Object message);
}

23 Haziran 2010 Çarşamba

Error : Java Web service. Unable to create JAXBContext

if you get the following error while deploying the web service:

Exception occured in the wsgen process javax.xml.ws.
WebServiceException: Unable to create JAXBContext build-impl.xml

it is probably because of a class with both publicly accessable members and getters/ setters..
If you make the members privately accessable or delete getter/setter methods, the error will be fixed:
see this: http://stackoverflow.com/questions/1198462/problem-with-java-web-service-unable-to-create-jaxbcontext