Project

General

Profile

Actions

Architecture #5817

closed

Refactor agent type

Added by Vincent MEMBRÉ almost 10 years ago. Updated almost 7 years ago.

Status:
Rejected
Priority:
2
Category:
Web - Nodes & inventories
Target version:
Effort required:
Name check:
Fix check:
Regression:

Description

Agent type classes are not correct

sealed abstract class AgentType {
  def toString() : String
  def fullname() : String = "CFEngine "+this
  // Tag used in fusion inventory ( > 2.3 )
  lazy val tagValue = s"cfengine-${this}".toLowerCase
  def toRulesPath() : String
}

toString should not be defined like (or with override)
fullname should be a lazy val
toRulesPath should not be in Invetory project, we are not aware here that we should generate rules

Actions

Also available in: Atom PDF