Skip to content
This repository has been archived by the owner on Mar 17, 2021. It is now read-only.

OpenShift connector: 'getImageStreamTagFromRepo' implementation should be more robust #334

Closed
ibuziuk opened this issue Sep 13, 2017 · 3 comments

Comments

@ibuziuk
Copy link
Member

ibuziuk commented Sep 13, 2017

After switching rhche recipes to devshift registry all stacks but vertx were broken. More details can be found in openshiftio/openshift.io#798

Basically, the problem was coupled with the fact that in getImageStreamTagFromRepo[1] method of OpenShiftConnector there was an assumption that image name would be less than 33 chars and with new registry it was not the case e.g. registry.devshift.net_che_spring-boot (Hot fix with increasing image name to 43 chars has been provided [2], but it is not ideal solution because it would still fail in future for images like registry.devshift.net_che_centos-wildfly-swarm

Some notes / ideas:

  • all this image name / tag limitations are coupled with the fact that max k8s names / labels max length is 63 chars[3]
  • Maybe it makes sense to limit tag size in convertPullSpecToTagName [4] (not sure but it looks like there is no real need in "che-ws-" prefix, and the size of tag itself could be limited to 12 chars. This would make k8s limitation more straight forward - 50 chars for image name : 12 chars for the tag

[1] https://github.com/eclipse/che/blob/master/plugins/plugin-docker/che-plugin-openshift-client/src/main/java/org/eclipse/che/plugin/openshift/client/OpenShiftConnector.java#L1108
[2] eclipse-che/che#6245
[3] kubernetes/kubernetes#12463 (comment)
[4] https://github.com/eclipse/che/blob/master/plugins/plugin-docker/che-plugin-openshift-client/src/main/java/org/eclipse/che/plugin/openshift/client/kubernetes/KubernetesStringUtils.java#L101

@ibuziuk
Copy link
Member Author

ibuziuk commented Sep 29, 2017

Upstream issue - eclipse-che/che#6500

@garagatyi
Copy link

@ibuziuk I think that this issue is not relevant anymore. There is no OpenshiftConnector in Che 6. Can we close this issue?

@ibuziuk
Copy link
Member Author

ibuziuk commented Feb 23, 2018

yeah, let's close it as outdated

@ibuziuk ibuziuk closed this as completed Feb 23, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants