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

DBAL Transport #54

Merged
merged 13 commits into from
Apr 24, 2017
Merged

DBAL Transport #54

merged 13 commits into from
Apr 24, 2017

Conversation

ASKozienko
Copy link
Member

No description provided.

@ASKozienko ASKozienko changed the title DBAL Transport [WIP] DBAL Transport Apr 19, 2017
*/
private function establishConnection()
{
return $this->registry->getConnection($this->config['connectionName']);
Copy link
Member

Choose a reason for hiding this comment

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

I guess we should call connect at this stage

} catch (\LogicException $e) {
$this->dbal->rollBack();
throw $e;
} catch (\Exception $e) {
Copy link
Member

Choose a reason for hiding this comment

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

why do you need two catch statements here?

$message->setId($dbalMessage['id']);
$message->setBody($dbalMessage['body']);
$message->setPriority((int) $dbalMessage['priority']);
$message->setRedelivered((bool) $dbalMessage['redelivered']);
Copy link
Member

Choose a reason for hiding this comment

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

there is no such thing for now

{
$builder
->children()
->scalarNode('connectionName')
Copy link
Contributor

Choose a reason for hiding this comment

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

other transport factories use snake_case

Copy link
Member

Choose a reason for hiding this comment

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

+1

@makasim
Copy link
Member

makasim commented Apr 21, 2017

partly address #32

$clientMessage->setMessageId($message->getMessageId());
$clientMessage->setTimestamp($message->getTimestamp());
$clientMessage->setPriority(MessagePriority::NORMAL);
$clientMessage->setDelay($message->getDelay());
Copy link
Member

Choose a reason for hiding this comment

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

setReplyTo
setCorreltationId

$transportMessage->setProperties($properties);
$transportMessage->setMessageId($message->getMessageId());
$transportMessage->setTimestamp($message->getTimestamp());
$transportMessage->setDelay($message->getDelay());
Copy link
Member

Choose a reason for hiding this comment

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

replyTo,correlationId

throw new \LogicException('Topic name parameter is required but is not set');
}

$topic = $this->createRouterTopic();
Copy link
Member

Choose a reason for hiding this comment

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

better to use

$queue = $this->createQueue($this->config->getRouterQueueName());

*
* @return DbalMessage|null
*/
public function receive($timeout = 0)
Copy link
Member

Choose a reason for hiding this comment

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

timeout in miliseconds, if you need seconds do $timeout / 1000

pkg/dbal/LICENSE Outdated
@@ -0,0 +1,20 @@
The MIT License (MIT)
Copyright (c) 2016 Kotliar Maksym
Copy link
Member

Choose a reason for hiding this comment

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

oro copyright

{
new DbalDriver(
$this->createPsrContextMock(),
new Config('', '', '', '', '', '')
Copy link
Member

Choose a reason for hiding this comment

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

Config::create()

"name": "enqueue/dbal",
"type": "library",
"description": "Message Queue Doctrine DBAL Transport",
"keywords": ["messaging", "queue", "dbal"],
Copy link
Member

Choose a reason for hiding this comment

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

doctrine

@makasim makasim changed the title [WIP] DBAL Transport DBAL Transport Apr 24, 2017
@makasim
Copy link
Member

makasim commented Apr 24, 2017

LGTM, you can start with SQS. I'll take care of the rest.

@makasim makasim merged commit 7aa1c68 into master Apr 24, 2017
@makasim makasim deleted the dbal-transport branch April 24, 2017 07:56
ASKozienko pushed a commit that referenced this pull request Nov 2, 2018
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.

3 participants