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

New gateway 'service' - part 1 #663

Merged
merged 3 commits into from
Oct 30, 2023
Merged

New gateway 'service' - part 1 #663

merged 3 commits into from
Oct 30, 2023

Conversation

nicoloboschi
Copy link
Member

@nicoloboschi nicoloboschi commented Oct 27, 2023

Changes:

  • added new gateway type service, very similar to the chat one but only for http. The user must send a input and the gateways wait for a message from the output topic
- id: g4
  type: service
  service-options:
    input-topic: input
    output-topic: output
    headers:
    - value-from-parameters: v1
{
 "key": "k1", 
  "value": "translate .."
  headers: {..}
}

@nicoloboschi nicoloboschi changed the title Gateway: accept HTTP request for producing messages New gateway 'service' Oct 27, 2023
@nicoloboschi nicoloboschi marked this pull request as ready for review October 30, 2023 08:23
Copy link
Member

@eolivelli eolivelli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@NotBlank @PathVariable("tenant") String tenant,
@NotBlank @PathVariable("application") String application,
@NotBlank @PathVariable("gateway") String gateway,
@RequestBody ProduceRequest produceRequest)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

where do you set the timeout ?
I guess that we should give the client the ability to set the timeout for waiting for the message to arrive

throw new ResponseStatusException(HttpStatus.UNAUTHORIZED, e.getMessage());
}

try (final ConsumeGateway consumeGateway =
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we have to follow up with a cache for this

@eolivelli eolivelli changed the title New gateway 'service' New gateway 'service' - part 1 Oct 30, 2023
@eolivelli eolivelli merged commit 5eea50c into main Oct 30, 2023
9 of 10 checks passed
@eolivelli eolivelli deleted the service-gw branch October 30, 2023 11:18
benfrank241 pushed a commit to vectorize-io/langstream that referenced this pull request May 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants