inspectIT / inspectit-ocelot

inspectIT Ocelot - Java agent for collecting application performance, tracing and behavior data
http://www.inspectit.rocks/
Apache License 2.0
204 stars 69 forks source link

[Bug] - Config Server: Agent Mapping is not applied when no config file exists #1530

Open MariusBrill opened 2 years ago

MariusBrill commented 2 years ago

Describe the bug When there are no files in the working directory of the config server, the default mapping does not work for inspectIT Agents.

Expected behavior The default mapping should be usable when no custom files are in the file system.

danipaniii commented 1 year ago

I tried to reproduce the bug in 3 different ways:

  1. Way: Deleting all the config files in the config view filetree (the ocelot default config cannot be deleted, so this was the only directory left there). With this method I could not reproduce the bug.

  2. Way: Deleting all the agent mappings in the agent mapping view. This resulted the agent not having any mapping at all and throw an error. It sounds reasonable, that when there is no agent mapping, no agent mapping can be found, so I believe that this way is the intended way how things should work.

  3. Way: Deleting the working_directory folder in the inspectit-ocelot folder. The working_directory got created again after restarting the config server and the agent could find the default mapping. Also with this method I could not reproduce the bug.

MariusBrill commented 1 year ago

In regard to 2. : I think we should discuss if having no Agent Mappings at all is even a valid state for the configuration server, as the server does not really fulfil its use case-without Agent Mappings.