Hello Team! Based on your inputs from yesterday, ...
# ask-questions
b
Hello Team! Based on your inputs from yesterday, I have moved my local setup of growthbook proxy to our server which points to Growthbook CDN. Alongside this, I have enabled remote evaluation on cloud. I'm unsure how to proceed post this i.e. to how to point proxy-server to private backend server for evaluation of feature-flag based on user attributes. Could you point me to some helpful documentation / examples ?
h
Your proxy server is the private backend for remote evaluation. It should just work out of the box now provided you've set up your SDK Connection for remote eval mode. Are you running into specific issues here?
b
I'm getting this error -
Copy code
{
  "status": 400,
  "error": "Failed to get features (remote eval required)"
}
h
to confirm, have you set your SDK implementation to remote eval mode?
remoteEval: true,
https://docs.growthbook.io/lib/js#remote-evaluation
b
That is correct, here's my config
Copy code
apiHost: "<https://proxy-host.mydomain.com>",
            clientKey: "client-key",
            remoteEval: true,
            enableDevMode: true,
            backgroundSync: true,
            streamingHost: "<https://cdn.growthbook.io>",
            subscribeToChanges: true,
            trackingCallback: (experiment, result) => {
                // TODO: Use your real analytics tracking system
                console.log("Viewed Experiment", {
                experimentId: experiment.key,
                variationId: result.key
                });
            }
Screenshot 2024-01-09 at 00.37.26.png
PS: I have edited the GB Proxy domain in image above to hide the real domain in this public space
h
got it. that error you're getting is what shows when the SDK Connection is not set for remote evaluation. Could you double check that is set to true for the specific client key connection
the other possibility is that the proxy isn't being "informed" by the GB app about remote eval being turned on. That could happen if there is an initial handshake error, which we could try to figure out by looking at the first few lines in your proxy logs
(to clarify, check that Remote Eval is turned on within the GB app in SDK Connections)
b
Screenshot 2024-01-09 at 00.45.13.png
I have above setup configured.
h
i think we'll need to dig into your proxy setup/logging if your SDK Connection and SDK implementation are correctly set up (which they seem to be). Some logs from your proxy might help, as well as the version/image of the proxy you are using
if you DM me your sdk key, i can do some digging on my end as well