user84592
user84592

Reputation: 4882

GWT serialization policy file

I have a GWT2.6.1 application. I uses a RPC call. I defined service, serviceAsync, serviceImpl. But I consistently got following errors:

INFO: javax.servlet.ServletContext log: logLevelServlet: ERROR: The serialization policy file '/analytics/E4322B1E292CEFFC5E147EAE677D2BFF.gwt.rpc' was not found; did you forget to include it in this deployment?

com.google.appengine.tools.development.ApiProxyLocalImpl log INFO: javax.servlet.ServletContext log: logLevelServlet: ERROR: The serialization policy file '/analytics/E4322B1E292CEFFC5E147EAE677D2BFF.gwt.rpc' was not found; did you forget to include it in this deployment?

com.google.appengine.tools.development.ApiProxyLocalImpl log INFO: javax.servlet.ServletContext log: logLevelServlet: Downloaded serialization policy from http://localhost:9876/policies/E4322B1E292CEFFC5E147EAE677D2BFF.gwt.rpc

EPARecord.java

public class EPARecord implements Serializable {
private static final long serialVersionUID = -6723643433565890894L;
private String timeStamp;
private String logLevel;
private String event;
private String comment;

public EPARecord(){}

public String getTimeStamp() {
    return timeStamp;
}

public void setTimeStamp(String timeStamp) {
    this.timeStamp = timeStamp;
}

public String getLogLevel() {
    return logLevel;
}

public void setLogLevel(String logLevel) {
    this.logLevel = logLevel;
}

public String getEvent() {
    return event;
}

public void setEvent(String event) {
    this.event = event;
}

public String getComment() {
    return comment;
}

public void setComment(String comment) {
    this.comment = comment;
}

}

LogLevelService.java

@RemoteServiceRelativePath("loglevel")
public interface LogLevelService extends RemoteService {
    EPARecord[] getEAPRecords(String level) throws IllegalArgumentException;
}

LogLevelServiceAysnc.java

public interface LogLevelServiceAsync {
void getEAPRecords(String level, AsyncCallback<EPARecord[]> callback) throws IllegalArgumentException;
}

I cleard browser cache, and I clear the project and rebuild it. It always give the same erorr. I suppose EPARecord file has all String attributes and it is serializable. And in remote interface, it transfer array of EPARecord, it shall be ok without customerized implementation of serializable.

Upvotes: 0

Views: 1513

Answers (2)

user2258777
user2258777

Reputation: 71

I had this problem when I wanted to connect to the local database with the GAE application. When I recreated my applications without GAE the problem disappeared.

Upvotes: 1

ryuzaki
ryuzaki

Reputation: 15

i take some problem.you can remove it and run again your app,if you have "inherits name='com.google.gwt.user.theme.clean.Clean'" code line into your *.gwt.xml file.

Upvotes: 1

Related Questions