LambdaInvokerFactory Unsupported Operation: Cannot evaluate












0















I am invoking an AWS Lambda function directly from my Android app. I have the Request class:



private class MyRequest
{
String param;
public SetIdentityRequest() {}
public SetIdentityRequest(String param) {this.param = param;}
public String getParam() { return param; }
public void setParam(String param) { this.param = param; }
}


I don't need any values returned, so I don't have a Response class. I tried making an empty one in case that was causing my problem, but I got a lot more errors.



My interface class:



private interface MyLambda
{
@LambdaFunction
void myLambda(MyRequest req);
}


And finally my code for calling it:



LambdaInvokerFactory factory = new LambdaInvokerFactory(getApplicationContext(), Regions.US_EAST_1, credentialsProvider);
MyLambda lambda = factory.build(MyLambda.class);
lambda.myLambda(new MyRequest(someString));


Now, the lambda does actually go through and execute properly, so this isn't a dealbreaking kind of error; but I've been seeing when I step through it in debug that the line that has factory.build gets an error Method threw 'java.lang.UnsupportedOperationException' exception. Cannot evaluate com.myapp.$Proxy1.toString(). What is this error about? Do I need to worry about it? What do I need to do to stop getting this error?










share|improve this question

























  • Hello! Can you confirm the code for constructing the factory object compiled? It should be Regions.US_EAST_1 however you don't have the plurality (Regions). Can you post the complete stacktrace? What is the frequency of this exception?

    – Karthikeyan
    Nov 19 '18 at 18:13











  • Yes, it was a transcription error here in the question; it's Regions in the original code. I have updated the question. I don't have a stacktrace for where the error is actually occurring; the build method that is reporting the error still returns successfully, but the debugger tells me it threw an exception, but I don't have an exception object to analyze. This seems to be happening every time I slow down the debug to look at it.

    – Trevortni
    Nov 26 '18 at 18:38











  • You can get the stacktrace from Logcat. Without a stacktrace it is difficult to analyze the issue further.

    – Karthikeyan
    Nov 26 '18 at 21:42
















0















I am invoking an AWS Lambda function directly from my Android app. I have the Request class:



private class MyRequest
{
String param;
public SetIdentityRequest() {}
public SetIdentityRequest(String param) {this.param = param;}
public String getParam() { return param; }
public void setParam(String param) { this.param = param; }
}


I don't need any values returned, so I don't have a Response class. I tried making an empty one in case that was causing my problem, but I got a lot more errors.



My interface class:



private interface MyLambda
{
@LambdaFunction
void myLambda(MyRequest req);
}


And finally my code for calling it:



LambdaInvokerFactory factory = new LambdaInvokerFactory(getApplicationContext(), Regions.US_EAST_1, credentialsProvider);
MyLambda lambda = factory.build(MyLambda.class);
lambda.myLambda(new MyRequest(someString));


Now, the lambda does actually go through and execute properly, so this isn't a dealbreaking kind of error; but I've been seeing when I step through it in debug that the line that has factory.build gets an error Method threw 'java.lang.UnsupportedOperationException' exception. Cannot evaluate com.myapp.$Proxy1.toString(). What is this error about? Do I need to worry about it? What do I need to do to stop getting this error?










share|improve this question

























  • Hello! Can you confirm the code for constructing the factory object compiled? It should be Regions.US_EAST_1 however you don't have the plurality (Regions). Can you post the complete stacktrace? What is the frequency of this exception?

    – Karthikeyan
    Nov 19 '18 at 18:13











  • Yes, it was a transcription error here in the question; it's Regions in the original code. I have updated the question. I don't have a stacktrace for where the error is actually occurring; the build method that is reporting the error still returns successfully, but the debugger tells me it threw an exception, but I don't have an exception object to analyze. This seems to be happening every time I slow down the debug to look at it.

    – Trevortni
    Nov 26 '18 at 18:38











  • You can get the stacktrace from Logcat. Without a stacktrace it is difficult to analyze the issue further.

    – Karthikeyan
    Nov 26 '18 at 21:42














0












0








0








I am invoking an AWS Lambda function directly from my Android app. I have the Request class:



private class MyRequest
{
String param;
public SetIdentityRequest() {}
public SetIdentityRequest(String param) {this.param = param;}
public String getParam() { return param; }
public void setParam(String param) { this.param = param; }
}


I don't need any values returned, so I don't have a Response class. I tried making an empty one in case that was causing my problem, but I got a lot more errors.



My interface class:



private interface MyLambda
{
@LambdaFunction
void myLambda(MyRequest req);
}


And finally my code for calling it:



LambdaInvokerFactory factory = new LambdaInvokerFactory(getApplicationContext(), Regions.US_EAST_1, credentialsProvider);
MyLambda lambda = factory.build(MyLambda.class);
lambda.myLambda(new MyRequest(someString));


Now, the lambda does actually go through and execute properly, so this isn't a dealbreaking kind of error; but I've been seeing when I step through it in debug that the line that has factory.build gets an error Method threw 'java.lang.UnsupportedOperationException' exception. Cannot evaluate com.myapp.$Proxy1.toString(). What is this error about? Do I need to worry about it? What do I need to do to stop getting this error?










share|improve this question
















I am invoking an AWS Lambda function directly from my Android app. I have the Request class:



private class MyRequest
{
String param;
public SetIdentityRequest() {}
public SetIdentityRequest(String param) {this.param = param;}
public String getParam() { return param; }
public void setParam(String param) { this.param = param; }
}


I don't need any values returned, so I don't have a Response class. I tried making an empty one in case that was causing my problem, but I got a lot more errors.



My interface class:



private interface MyLambda
{
@LambdaFunction
void myLambda(MyRequest req);
}


And finally my code for calling it:



LambdaInvokerFactory factory = new LambdaInvokerFactory(getApplicationContext(), Regions.US_EAST_1, credentialsProvider);
MyLambda lambda = factory.build(MyLambda.class);
lambda.myLambda(new MyRequest(someString));


Now, the lambda does actually go through and execute properly, so this isn't a dealbreaking kind of error; but I've been seeing when I step through it in debug that the line that has factory.build gets an error Method threw 'java.lang.UnsupportedOperationException' exception. Cannot evaluate com.myapp.$Proxy1.toString(). What is this error about? Do I need to worry about it? What do I need to do to stop getting this error?







android amazon-web-services aws-lambda






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Nov 26 '18 at 18:30







Trevortni

















asked Nov 15 '18 at 22:00









TrevortniTrevortni

223115




223115













  • Hello! Can you confirm the code for constructing the factory object compiled? It should be Regions.US_EAST_1 however you don't have the plurality (Regions). Can you post the complete stacktrace? What is the frequency of this exception?

    – Karthikeyan
    Nov 19 '18 at 18:13











  • Yes, it was a transcription error here in the question; it's Regions in the original code. I have updated the question. I don't have a stacktrace for where the error is actually occurring; the build method that is reporting the error still returns successfully, but the debugger tells me it threw an exception, but I don't have an exception object to analyze. This seems to be happening every time I slow down the debug to look at it.

    – Trevortni
    Nov 26 '18 at 18:38











  • You can get the stacktrace from Logcat. Without a stacktrace it is difficult to analyze the issue further.

    – Karthikeyan
    Nov 26 '18 at 21:42



















  • Hello! Can you confirm the code for constructing the factory object compiled? It should be Regions.US_EAST_1 however you don't have the plurality (Regions). Can you post the complete stacktrace? What is the frequency of this exception?

    – Karthikeyan
    Nov 19 '18 at 18:13











  • Yes, it was a transcription error here in the question; it's Regions in the original code. I have updated the question. I don't have a stacktrace for where the error is actually occurring; the build method that is reporting the error still returns successfully, but the debugger tells me it threw an exception, but I don't have an exception object to analyze. This seems to be happening every time I slow down the debug to look at it.

    – Trevortni
    Nov 26 '18 at 18:38











  • You can get the stacktrace from Logcat. Without a stacktrace it is difficult to analyze the issue further.

    – Karthikeyan
    Nov 26 '18 at 21:42

















Hello! Can you confirm the code for constructing the factory object compiled? It should be Regions.US_EAST_1 however you don't have the plurality (Regions). Can you post the complete stacktrace? What is the frequency of this exception?

– Karthikeyan
Nov 19 '18 at 18:13





Hello! Can you confirm the code for constructing the factory object compiled? It should be Regions.US_EAST_1 however you don't have the plurality (Regions). Can you post the complete stacktrace? What is the frequency of this exception?

– Karthikeyan
Nov 19 '18 at 18:13













Yes, it was a transcription error here in the question; it's Regions in the original code. I have updated the question. I don't have a stacktrace for where the error is actually occurring; the build method that is reporting the error still returns successfully, but the debugger tells me it threw an exception, but I don't have an exception object to analyze. This seems to be happening every time I slow down the debug to look at it.

– Trevortni
Nov 26 '18 at 18:38





Yes, it was a transcription error here in the question; it's Regions in the original code. I have updated the question. I don't have a stacktrace for where the error is actually occurring; the build method that is reporting the error still returns successfully, but the debugger tells me it threw an exception, but I don't have an exception object to analyze. This seems to be happening every time I slow down the debug to look at it.

– Trevortni
Nov 26 '18 at 18:38













You can get the stacktrace from Logcat. Without a stacktrace it is difficult to analyze the issue further.

– Karthikeyan
Nov 26 '18 at 21:42





You can get the stacktrace from Logcat. Without a stacktrace it is difficult to analyze the issue further.

– Karthikeyan
Nov 26 '18 at 21:42












0






active

oldest

votes











Your Answer






StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");

StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53328506%2flambdainvokerfactory-unsupported-operation-cannot-evaluate%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























0






active

oldest

votes








0






active

oldest

votes









active

oldest

votes






active

oldest

votes
















draft saved

draft discarded




















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53328506%2flambdainvokerfactory-unsupported-operation-cannot-evaluate%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Bressuire

Vorschmack

Quarantine