Groovy Documentation

org.linkedin.glu.orchestration.engine.delta
[Groovy] Interface DeltaService


interface DeltaService

Method Summary
CustomGroupByDelta computeCustomGroupByDelta(SystemModel expectedModel, CustomDeltaDefinition deltaDefinition)

Compute the custom "group by" delta using the custom delta definition provided

CustomGroupByDelta computeCustomGroupByDelta(SystemModel expectedModel, UserCustomDeltaDefinition userDeltaDefinition)

Compute the custom "group by" delta using the custom delta definition provided

java.util.Map computeDelta(SystemModel expectedModel)

Computes the delta between the expected model and the current one (which will be computed) In this version the delta is a set

java.lang.String computeDeltaAsJSON(java.lang.Object params)

params.expectedModel:
expected model
params.currentModel:
current model (null means compute it)
params.errorsOnly:
filter to show only errors (true/false)
params.prettyPrint:
if json should be pretty printed (true/false)
@params.flatten flatten the model (true/false)

java.util.Map computeGroupByDelta(SystemModel expectedSystem, java.util.Map groupByDefinition, java.util.Map groupBySelection)

This method used to be in DashboardController and as been moved here to be able to share/test more easily

java.util.Map computeRawDelta(SystemModel expectedModel)

Computes the raw delta between the expected model and the current one (which will be computed)

boolean deleteUserCustomDeltaDefinition(UserCustomDeltaDefinition definition)

delete from storage

java.util.Map findAllUserCustomDeltaDefinition(boolean includeDetails, java.lang.Object params)

Return all the entries for the 'current' user

java.util.Map findAllUserCustomDeltaDefinitionShareable(boolean includeDetails, java.lang.Object params)

Return only the shareable entries

UserCustomDeltaDefinition findDefaultCustomDeltaDefinition()

Return the default value

UserCustomDeltaDefinition findDefaultUserCustomDeltaDefinition(java.lang.String defaultName)

Return the default configuration for the user with the given name but if not found will create a default one based on findDefaultCustomDeltaDefinition()

UserCustomDeltaDefinition findUserCustomDeltaDefinitionByName(java.lang.String name)

Return the unique entry for a given username by name

UserCustomDeltaDefinition saveAsNewUserCustomDeltaDefinition(UserCustomDeltaDefinition definition)

Duplicate the definition provided instead of renaming

boolean saveDefaultCustomDeltaDefinition(CustomDeltaDefinition definition)

Initializes the default user custome delta definition

boolean saveUserCustomDeltaDefinition(UserCustomDeltaDefinition definition)

Save in the storage

 

Method Detail

computeCustomGroupByDelta

CustomGroupByDelta computeCustomGroupByDelta(SystemModel expectedModel, CustomDeltaDefinition deltaDefinition)
Compute the custom "group by" delta using the custom delta definition provided


computeCustomGroupByDelta

CustomGroupByDelta computeCustomGroupByDelta(SystemModel expectedModel, UserCustomDeltaDefinition userDeltaDefinition)
Compute the custom "group by" delta using the custom delta definition provided


computeDelta

java.util.Map computeDelta(SystemModel expectedModel)
Computes the delta between the expected model and the current one (which will be computed) In this version the delta is a set
Returns:
a map with 2 entries: accuracy and delta.


computeDeltaAsJSON

java.lang.String computeDeltaAsJSON(java.lang.Object params)
params.expectedModel:
expected model
params.currentModel:
current model (null means compute it)
params.errorsOnly:
filter to show only errors (true/false)
params.prettyPrint:
if json should be pretty printed (true/false)
params.flatten:
flatten the model (true/false)
Returns:
json representation of the delta


computeGroupByDelta

java.util.Map computeGroupByDelta(SystemModel expectedSystem, java.util.Map groupByDefinition, java.util.Map groupBySelection)
This method used to be in DashboardController and as been moved here to be able to share/test more easily
Parameters:
groupByDefinition - TODO MED YP (in the meantime look at consoleConfig.defaults.dashboard)
groupBySelection - TODO MED YP (params from the request)
Returns:
the delta grouped by according to the definition and selection


computeRawDelta

java.util.Map computeRawDelta(SystemModel expectedModel)
Computes the raw delta between the expected model and the current one (which will be computed)
Returns:
a map with 2 entries [accuracy: accuracy, delta: SystemModelDelta]


deleteUserCustomDeltaDefinition

@ExpectPrincipal
boolean deleteUserCustomDeltaDefinition(UserCustomDeltaDefinition definition)
delete from storage


findAllUserCustomDeltaDefinition

@ExpectPrincipal
java.util.Map findAllUserCustomDeltaDefinition(boolean includeDetails, java.lang.Object params)
Return all the entries for the 'current' user params can be what grails accept for paginating queries: max, offset, sort, order
Returns:
a map with list: the list of UserCustomDeltaDefinition or LightUserCustomDeltaDefinition and count: the total number of entries


findAllUserCustomDeltaDefinitionShareable

java.util.Map findAllUserCustomDeltaDefinitionShareable(boolean includeDetails, java.lang.Object params)
Return only the shareable entries params can be what grails accept for paginating queries: max, offset, sort, order
Returns:
a map with list: the list of UserCustomDeltaDefinition or LightUserCustomDeltaDefinition and count: the total number of entries


findDefaultCustomDeltaDefinition

UserCustomDeltaDefinition findDefaultCustomDeltaDefinition()
Return the default value


findDefaultUserCustomDeltaDefinition

@ExpectPrincipal
UserCustomDeltaDefinition findDefaultUserCustomDeltaDefinition(java.lang.String defaultName)
Return the default configuration for the user with the given name but if not found will create a default one based on findDefaultCustomDeltaDefinition()


findUserCustomDeltaDefinitionByName

@ExpectPrincipal
UserCustomDeltaDefinition findUserCustomDeltaDefinitionByName(java.lang.String name)
Return the unique entry for a given username by name
Returns:
null if no such entry


saveAsNewUserCustomDeltaDefinition

@ExpectPrincipal
UserCustomDeltaDefinition saveAsNewUserCustomDeltaDefinition(UserCustomDeltaDefinition definition)
Duplicate the definition provided instead of renaming
Returns:
the saved object (check for errors on it)


saveDefaultCustomDeltaDefinition

boolean saveDefaultCustomDeltaDefinition(CustomDeltaDefinition definition)
Initializes the default user custome delta definition


saveUserCustomDeltaDefinition

@ExpectPrincipal
boolean saveUserCustomDeltaDefinition(UserCustomDeltaDefinition definition)
Save in the storage


 

Groovy Documentation