It does not seem related to the reference being a superclass.
I added a second servlet which uses a reference to
RectangularWithDiagonalsPuzzle
directly.
@WebServlet(urlPatterns="/DiagonalSlitherlink/GetDiagonalSlitherlink")
public class GetDiagonalSlitherlinkImpl extends RemoteServiceServlet
implements GetDiagonalSlitherlink {
private static final long serialVersionUID = 1L;
public RectangularWithDiagonalsPuzzle getPuzzle(String category) {
try {
RectangularWithDiagonalsPuzzle puzzle =
(RectangularWithDiagonalsPuzzle)FileUtil.deSerialize(PathUtil.PUZZLES_DIR+
"/DiagonalSlitherlink/Challenging/DiagonalSlitherlink-00001-3.ser");
LogManager.getLogger(getClass()).warn("In DiagonalSlitherlinkImpl,
Loaded puzzle "+puzzle);
return puzzle;
} catch( Exception e ) {
LogManager.getLogger(getClass()).error(e);
return null;
}
}
}
And I see this in the server log:
WARN: In DiagonalSlitherlinkImpl, Loaded puzzle
com._3dmathpuzzles.slitherlink.RectangularWithDiagonalsPuzzle@76c929a9
Thank you,
Neil
--
Neil Aggarwal, (972) 834-1565, http://www.propfinancing.com
We offer 30 year loans on single family houses!
> -----Original Message-----
> From: Neil Aggarwal <[email protected]>
> Sent: Tuesday, December 17, 2024 5:43 PM
> To: '[email protected]' <google-web-
> [email protected]>
> Subject: Getting 500 error from RPC call
>
> Now, when I call my service, I am getting this error:
> 500 500 The call failed on the server; see server log for details
>
> Here is the code in my service:
> public Puzzle getPuzzle(String category) {
> try {
> Puzzle puzzle =
>
(Puzzle)FileUtil.deSerialize(PathUtil.PUZZLES_DIR+"/DiagonalSlitherlink/Ch
allengi
> ng/DiagonalSlitherlink-00001-3.ser");
> LogManager.getLogger(getClass()).warn("Loaded puzzle "+puzzle);
> return puzzle;
> } catch( Exception e ) {
> LogManager.getLogger(getClass()).error(e);
> return null;
> }
> }
>
> My server log has this:
> WARN: Loaded puzzle
> com._3dmathpuzzles.slitherlink.RectangularWithDiagonalsPuzzle@3f8ef4a0
>
> The only code after that line is the return.
>
> Does GWT not like that I am returning a subclass which is referenced by
a
> superclass reference?
>
> Thank you,
> Neil
>
> --
> Neil Aggarwal, (972) 834-1565, http://www.propfinancing.com We offer 30
year
> loans on single family houses!
--
You received this message because you are subscribed to the Google Groups "GWT
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion visit
https://groups.google.com/d/msgid/google-web-toolkit/98644197646de7d18f489dca2f08bec0%40mail.gmail.com.