Page MenuHomePhabricator

Bad Request error when starting a Kubernetes service
Closed, ResolvedPublicBUG REPORT

Description

Today I have restarted my tool replacer after some weeks/months.

After logging in with my user _benjavalero_ and becoming _replacer_, I have run as usual:

webservice start

but I get the following error trace:

Traceback (most recent call last):
  File "/usr/local/bin/webservice", line 460, in <module>
    start(job, "Starting webservice")
  File "/usr/local/bin/webservice", line 83, in start
    job.request_start()
  File "/usr/lib/python3/dist-packages/toolsws/backends/kubernetes.py", line 571, in request_start
    self.api.create_object("deployments", self._get_deployment())
  File "/usr/lib/python3/dist-packages/toolsws/backends/kubernetes.py", line 788, in create_object
    version=K8sClient.VERSIONS[kind],
  File "/usr/lib/python3/dist-packages/toolsws/backends/kubernetes.py", line 749, in _post
    r.raise_for_status()
  File "/usr/lib/python3/dist-packages/requests/models.py", line 940, in raise_for_status
    raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 400 Client Error: Bad Request for url: https://k8s.tools.eqiad1.wikimedia.cloud:6443/apis/apps/v1/namespaces/tool-replacer/deployments

Thanks for your help.

Event Timeline

Change 789655 had a related patch set uploaded (by Majavah; author: Majavah):

[operations/software/tools-webservice@master] kubernetes: fix DEFAULT_JDK_RESOURCES

https://gerrit.wikimedia.org/r/789655

Change 789655 merged by jenkins-bot:

[operations/software/tools-webservice@master] kubernetes: fix DEFAULT_JDK_RESOURCES

https://gerrit.wikimedia.org/r/789655

taavi claimed this task.
taavi subscribed.

Looks like I managed to sneak in a bug in the last webservice update which broke starting all Java web services. Fixed now, sorry about that!

Mentioned in SAL (#wikimedia-cloud) [2022-05-05T17:28:04Z] <taavi> deploy tools-webservice 0.83 T307693

Thanks for such a quick reaction!