[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

RE: Changing routing SPI call



Hi Clayton,

It's all right for us. It's just one extra information, that could be useful for us too.

Cheers
Romain

-----Message d'origine-----
De : dev-bounces lists openshift redhat com [mailto:dev-bounces lists openshift redhat com] De la part de Clayton Coleman
Envoyé : mardi 17 décembre 2013 19:36
À : dev lists openshift redhat com
Objet : Changing routing SPI call


We realized yesterday that the add_gear mcollective call doesn't have a gear ID on it, so you can't construct a URL to the public gear DNS (<gearid>-<domain>.<suffix>) from the routing SPI endpoint.  As I was doing that I noticed that we were still calling it add_gear, when it's really add_public_endpoint, which I would like to change.

I'd like to maintain backward compatibility of the SPI wherever possible, so I was going to send both old and new message ids as two messages.  So where before you would get:

      {
        :action => :add_gear,
        :app_name => app.name,
        :namespace => app.domain.namespace,
        :public_port_name => endpoint_name,
        :public_address => public_ip,
        :public_port => public_port,
        :protocols => protocols,
        :types => types,
        :mappings => mappings
      }

now you'll get that, AND:

      {
        :action => :add_public_endpoint,
        :app_name => app.name,
        :namespace => app.domain.namespace,
        :public_port_name => endpoint_name,
        :public_address => public_ip,
        :public_port => public_port,
        :protocols => protocols,
        :types => types,
        :mappings => mappings
      }

Listen to one or the other, but not both.  The same applies for delete_gear and remove_public_endpoint.  We will deprecate add_gear and delete_gear in 2.0.2 enterprise, and remove it in 2.2 enterprise (origin 4 probably).

Also, we need to add the gear identifier to each endpoint that is published so that a consumer can construct a gear specific URL.  To do that, the RoutingService API will change in a non-backwards compatible manner - anyone implementing a custom RoutingProvider (i.e, not using activemq_routing_plugin) will have an API change in 2.0.2 enterprise / upcoming master.  These are the methods that will change:

    def notify_create_public_endpoint(app, endpoint_name, public_ip, public_port, protocols, types, mappings)
    def notify_delete_public_endpoint(app, public_ip, public_port)

to

    def notify_create_public_endpoint(app, gear, endpoint_name, public_ip, public_port, protocols, types, mappings)
    def notify_delete_public_endpoint(app, gear, public_ip, public_port)

The gear identifier will be sent as gear_id in the affected messages.

Any concerns or questions?

_______________________________________________
dev mailing list
dev lists openshift redhat com
http://lists.openshift.redhat.com/openshiftmm/listinfo/dev


Ce message et les pièces jointes sont confidentiels et réservés à l'usage exclusif de ses destinataires. Il peut également être protégé par le secret professionnel. Si vous recevez ce message par erreur, merci d'en avertir immédiatement l'expéditeur et de le détruire. L'intégrité du message ne pouvant être assurée sur Internet, la responsabilité de Worldline ne pourra être recherchée quant au contenu de ce message. Bien que les meilleurs efforts soient faits pour maintenir cette transmission exempte de tout virus, l'expéditeur ne donne aucune garantie à cet égard et sa responsabilité ne saurait être recherchée pour tout dommage résultant d'un virus transmis.

This e-mail and the documents attached are confidential and intended solely for the addressee; it may also be privileged. If you receive this e-mail in error, please notify the sender immediately and destroy it. As its integrity cannot be secured on the Internet, the Worldline liability cannot be triggered for the message content. Although the sender endeavours to maintain a computer virus-free network, the sender does not warrant that this transmission is virus-free and will not be liable for any damages resulting from any virus transmitted.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]