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

Re: Problems with setting up a new cartridge




On Jul 13, 2013, at 11:02 AM, Neil Armitage <neil armitage continuent com> wrote:

> Hi
> 
> I'm hoping you can help with this. We are building a new cartridge to set up Tungsten replication between MySQL instances. Basically I have taken a MySQL cartridge and added our replication software into it.
> 
> The cartridge works fine but now I am having problems when I scale the cartridge. I have set up the manifest so if publishes a proxy port for the port for the replicator to attach to and I am receiving this information in all of the cartridges ok. My problem is the proxy variable does not appear to exist then the setup, install or post_install scripts are run, it is empty at that point.

That seems wrong - proxy should be visible during setup.  It is definitely available when connection hooks are run.  Although that may be because expose-port is being run after setup.... But if that's the case it's something we're going to be fixing very soon.  

Dan/Jhon?

If so, your subscribe hooks will have access.  Connection hooks will run before "control start" is called though, so you could do it in a hook you subscribe to yourself or in "control start"

> In order to configure the software I need to me able to access this information at some point when the gear is built. Is there any point in the deployment process where I can access this information and use it to configure some files within the replicator? Or have I configured something wrong?
> 
> Basically I am set up as follows
> 
> manifest
> 
> Publishes:
>  publish-tungsten-messaging:
>    Type: "NET_TCP:tungsten-messaging-info"
> Subscribes:
>  set-tungsten-messaging:
>    Type: "NET_TCP:tungsten-messaging-info"
> Scaling:
>  Min: 1
>  Max: -1
> Endpoints:
>  - Private-IP-Name:   DB_HOST
>    Private-Port-Name: MESSAGING_PORT
>    Private-Port:      5445
>    Public-Port-Name:  MESSAGING_PROXY_PORT
> 
> When I start the gear the variable is available from the command line
> 
> [51e1134c4382ecc119000235-narmitag.rhcloud.com 51e1134c4382ecc119000235]\> env|grep MESSAGING
> OPENSHIFT_TUNGSTEN_MESSAGING=51e1134c4382ecc119000235-narmitag.rhcloud.com[50116],51e115e45973cab71700007e-narmitag.rhcloud.com[47681]
> 
> But if I try and look the the variable in the build scripts it is empty
> 
> [51e1134c4382ecc119000235-narmitag.rhcloud.com 51e1134c4382ecc119000235]\> cat tungsten/log/boot.log
> In setup OPENSHIFT_TUNGSTEN_MESSAGING = '  ' :
> In install  OPENSHIFT_TUNGSTEN_MESSAGING = '  ':
> In post install OPENSHIFT_TUNGSTEN_MESSAGING = '  ' :
> 
> If any one could shed some light on this it would be very helpful
> 
> Thanks
> 
> 
> 
> 
> 
> -- 
> Neil Armitage
> Cluster Implementation Engineer
> neil armitage continuent com
> Skype : narmitag
> 
> _______________________________________________
> dev mailing list
> dev lists openshift redhat com
> http://lists.openshift.redhat.com/openshiftmm/listinfo/dev


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