iternity-dotcom / minio

High Performance, Kubernetes Native Object Storage
https://min.io/download
GNU Affero General Public License v3.0
6 stars 1 forks source link

Enable StartProfilingHandler for gateway mode #25

Closed rluetzner closed 2 years ago

rluetzner commented 2 years ago

The only reason why the useful profiling function of the admin API doesn't work for gateway modes is, that the gateway-main doesn't init the global variable globalLocalNodeName.

We simply use the same initialization logic as in server mode.

Description

Motivation and Context

Due to some unitizialed global values, the profiling endpoints are not available for gateway modes.

How to test this PR?

mc admin profile start <alias> should now no longer throw an error.

Types of changes

Checklist:

rluetzner commented 2 years ago

This fixes #22 .