Hi all, I am having a slight issue on metaflow UI....
# dev-metaflow
i
Hi all, I am having a slight issue on metaflow UI. i am running metaflow service on AWS and running metaflow UI on a docker container locally. I was able to set my environment variable but i am getting CORS issues on the UI. any suggestion?
1
a
@average-beach-28850 can you help on this?
a
where is the UI backend service running?
i
AWS
a
is there auth? is there anything in front of it? For context, generally it is not a scenario that is very well supported at the moment. In theory it should work, since the backend does set the CORS header to
*
. However, if there is any kind of proxy in front, that may break things
i
@average-beach-28850 i have verified that there is no auth on the service.
however, when i make a curl to the /api/version endpoint, i get 404
the metaflow-service is hosted on AWS fargate and it is not behind a loadbalancer
a
i see, did you use the cloudformation template from https://github.com/Netflix/metaflow-tools/ to deploy it?
i
no, terraform was used
a
also the way the readme is written, it may be a bit confusing, but basically the idea is that there is : • metaflow metadata service (that existed before the UI) • UI backend service (that shares some of the code base with the service) • React App And the react app talks to the UI backend, not metaflow metadata service directly
i
ah! i see.
a
also you may want to take a look at this PR https://github.com/Netflix/metaflow-tools/pull/45, i used it to deploy https://demo.public.outerbounds.xyz/
i
so it means i cant use the UI with the current version of metaflow-service? and i have to redeploy when this PR is merged.
a
Depending on the version, I believe you don't have to upgrade the metaflow-service, but there are some features in the UI that won't work with older versions of the metaflow-service. And you'd need to deploy ui-backend service in addition to your existing metaflow-service, for UI to work
i
okay, i am using metaflow 2.3.5 but i guess that’s my client.
@average-beach-28850 i will wait for the PR to be merged then upgrade before i start using the UI.
Hi @ancient-application-36103 , i deployed the ui_server and the ui, yet i still get the
CORS
issue.
a
where do you see the CORS error exactly? maybe you can post a screenshot or something
i
i get the CORS issue on the metaflow-ui.
i am sending it now
WhatsApp Image 2021-11-15 at 8.11.38 PM.jpeg
a
is .21.176 the ui backend or metaflow service?
i
its the ui backend. i am running it on a container
a
i'd try looking at the response headers for
/api/version
there, either by curling the url or in the devtools in Chrome
unfortunately Chrome no longer shows CORS pre-flight requests in devtools that makes debugging those a little tricky
i
sure i can curl the url
WhatsApp Image 2021-11-15 at 8.20.52 PM.jpeg
i have 3 separate deployment: • metaflow-service • ui_server • ui
a
ok that response looks more like some static js/html rather than a response from the API
what environment variables do you have set for the ui_server?
i
i used what was on the doc with the values changed.
Copy code
$ docker run \
      -e MF_METADATA_DB_HOST='<instance_name>.<http://us-east-1.rds.amazonaws.com|us-east-1.rds.amazonaws.com>' \
      -e MF_METADATA_DB_PORT=5432 \
      -e MF_METADATA_DB_USER='postgres' \
      -e MF_METADATA_DB_PSWD='postgres' \
      -e MF_METADATA_DB_NAME='metaflow' \
      -p 8083:8083 netflixoss/metaflow_metadata_service \
      /opt/latest/bin/python3 -m services.ui_backend_service.ui_server
yeah, it is now working after i used the variables from your branch.
a
nice! we need to update the readme there
i
yeah, that will really help.
now i can see the UI saying that i am using old version of metaflow. Is there any document on how to upgrade metaflow?
a
metaflow itself you can upgrade via
pip
as any other python package
i
thank you. i will give it a try