Skip to content

Conversation

@denislavprinov
Copy link
Contributor

  • Introduces a new Model Context Protocol (MCP) server module (hawkbit-mcp) that enables AI assistants to interact with hawkBit
  • Provides MCP tools for managing all hawkBit entities: Targets, Distribution Sets, Software Modules, Rollouts, Actions, and Target Filters
  • Includes MCP resources for hawkBit documentation
  • Exposes predefined prompts
  • Supports credential pass-through authentication to hawkBit REST API

@denislavprinov denislavprinov force-pushed the feature/hawkbit-mcp-server branch from dc059b7 to b0d48e0 Compare January 15, 2026 16:47
Signed-off-by: Denislav Prinov <denislav.prinov@bosch.com>
@denislavprinov denislavprinov force-pushed the feature/hawkbit-mcp-server branch from f1f3e2d to 1607ecf Compare January 20, 2026 09:52
…er build

Signed-off-by: Denislav Prinov <denislav.prinov@bosch.com>
@denislavprinov denislavprinov force-pushed the feature/hawkbit-mcp-server branch from 1607ecf to 5946a09 Compare January 20, 2026 12:46
@sonarqubecloud
Copy link


```bash
# Linux/Mac
echo -n "<TENANT>\\<USERNAME>:<PASSWORD>" | base64

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

<TENANT>\\<USERNAME> does not work in hawkbit. Authentication should be only with <USERNAME> only.

*/
@Slf4j
@Component
public class HawkbitAuthenticationValidator {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider makingHawkbitAuthenticationValidator conditional on property hawkbit.mcp.validation.enabled

When disabled:

  • No HawkbitAuthenticationValidator bean will be created
  • No authentication cache will be created
  • The security filter chain will be lightweight

@Slf4j
@Configuration
@RequiredArgsConstructor
public class HawkbitClientConfiguration {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider separating Http and STDIO Client Configurations, making them conditional on a mode property.

Benefits of This Approach:

  • Each configuration class handles exactly one mode
  • Mode is set via property, not runtime guessing
  • Implementation is simpler and more readable
  • Easy to add new modes

* Rollout-specific operation configuration including lifecycle operations.
*/
@Data
public static class RolloutConfig extends EntityConfig {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider adding @EqualsAndHashCode(callSuper = true/false) if equals/hashCode implementation must (not) call super class.

Comment on lines +25 to +26
Long actionId,
List<Long> actionIds,

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you need both actionId and actionIds?

* @param createBody the request body for CREATE operation
* @param updateBody the request body for UPDATE operation
*/
public record ManageDistributionSetRequest(

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would rather create different Create/Update/Delete Requests.
The Sealed interface could be used. When migrating to Java 21, the switch with pattern match is a really good approach here.

Comment on lines +26 to +32
public record ManageRolloutRequest(
RolloutOperation operation,
Long rolloutId,
MgmtRolloutRestRequestBodyPost createBody,
MgmtRolloutRestRequestBodyPut updateBody,
String remark
) {}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See comment

Comment on lines +25 to +30
public record ManageSoftwareModuleRequest(
Operation operation,
Long softwareModuleId,
MgmtSoftwareModuleRequestBodyPost createBody,
MgmtSoftwareModuleRequestBodyPut updateBody
) {}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See comment

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants