elastically icon indicating copy to clipboard operation
elastically copied to clipboard

Add a bridge : A bundle for Symfony

Open lyrixx opened this issue 4 years ago • 5 comments

Note: early wip!

lyrixx avatar Jul 23 '21 17:07 lyrixx

How can we move forward with this idea?

From what I see, we miss some documentation?

damienalexandre avatar Jun 22 '22 15:06 damienalexandre

I need some time...

And we need to take a decission: Do we support only one connection, or do we allow many?

lyrixx avatar Jun 22 '22 15:06 lyrixx

IMO, we should go simple as first implementation and support only one connection, if someone has needs for more we can create a new issue and make a new iteration of that feature later.

Korbeil avatar Jun 22 '22 15:06 Korbeil

I would like to avoid that.

Because supporting theses two configuration is really boring

client:
    host: 127.0.0.1
    mapping: data/mapping.yaml

client:
    default:
        host: 127.0.0.1
        mapping: data/mapping.yaml
    another:
        host: 127.0.0.2
        mapping: data/mapping2.yaml

I already have a POC on my computer to support N connexion. I need not so much time to finish it I guess

lyrixx avatar Jun 22 '22 16:06 lyrixx

I agree with @lyrixx, multiple connexion from the start is good. We must solve the autowiring that's all.

damienalexandre avatar Jun 23 '22 07:06 damienalexandre

I just pushed a new version. still in WIP

The configuration has the following shape:

elastically:
    connections:
        default:
            prefix:               null
            index_class_mapping:
                my-index:            My\Dto
            serializer:
                context_mapping:
                    foo:                 bar
            client:               []
            mapping_directory:    ~
  • You can have as much as client as you want.
  • If there is only one client, this is the default one (for autowire)
  • If there are more, you can specify one (for autowire)
  • I'll add support for Target Attribute & named parameter

lyrixx avatar Dec 23 '22 16:12 lyrixx

Here we go! New version published. I added everything I wanted. I wrote some documentation. Can I have a review please? And if it's okay, I'll write some tests eventually

lyrixx avatar Dec 23 '22 18:12 lyrixx

Thanks!

damienalexandre avatar Jan 03 '23 10:01 damienalexandre