Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Functions] The argument and description for dead letter topic is wrong #6101

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -185,13 +185,17 @@ public void testCreateFunction() throws Exception {
"--tenant", "sample",
"--namespace", "ns1",
"--className", DummyFunction.class.getName(),
"--dead-letter-topic", "test-dead-letter-topic",
"--custom-runtime-options", "custom-runtime-options"
});

CreateFunction creater = cmd.getCreater();
assertEquals(fnName, creater.getFunctionName());
assertEquals(inputTopicName, creater.getInputs());
assertEquals(outputTopicName, creater.getOutput());
assertEquals(new Boolean(false), creater.getAutoAck());
assertEquals("test-dead-letter-topic", creater.getDeadLetterTopic());
assertEquals("custom-runtime-options", creater.getCustomRuntimeOptions());

verify(functions, times(1)).createFunction(any(FunctionConfig.class), anyString());

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -299,9 +299,9 @@ abstract class FunctionDetailsCommand extends BaseCommand {
protected Long timeoutMs;
@Parameter(names = "--max-message-retries", description = "How many times should we try to process a message before giving up")
protected Integer maxMessageRetries;
@Parameter(names = "--dead-letter-topic", description = "The topic where messages that are not processed successfully are sent to")
protected String customRuntimeOptions;
@Parameter(names = "--custom-runtime-options", description = "A string that encodes options to customize the runtime, see docs for configured runtime for details")
protected String customRuntimeOptions;
@Parameter(names = "--dead-letter-topic", description = "The topic where messages that are not processed successfully are sent to")
protected String deadLetterTopic;
protected FunctionConfig functionConfig;
protected String userCodeFile;
Expand Down