@Component
class GithubDataService(val issuePileService: IssuePileService, @Qualifier(value = "graphglueNeo4jOperations") val neoOperations: ReactiveNeo4jOperations, val labelInfoRepository: LabelInfoRepository, val tokenManager: GithubTokenManager, val helper: JsonHelper, val objectMapper: ObjectMapper, val jsonNodeMapper: JsonNodeMapper, val gropiusUserRepository: GropiusUserRepository) : SyncDataService

Service to handle data from GitHub

Parameters

issuePileService

the issue pile service to use

neoOperations

Reference for the spring instance of ReactiveNeo4jOperations

labelInfoRepository

the label info repository to use

tokenManager

Reference for the spring instance of GithubTokenManager

helper

Reference for the spring instance of JsonHelper

objectMapper

Reference for the spring instance of ObjectMapper

jsonNodeMapper

Reference for the spring instance of JsonNodeMapper

gropiusUserRepository

Reference for the spring instance of GropiusUserRepository

Constructors

Link copied to clipboard
constructor(issuePileService: IssuePileService, @Qualifier(value = "graphglueNeo4jOperations") neoOperations: ReactiveNeo4jOperations, labelInfoRepository: LabelInfoRepository, tokenManager: GithubTokenManager, helper: JsonHelper, objectMapper: ObjectMapper, jsonNodeMapper: JsonNodeMapper, gropiusUserRepository: GropiusUserRepository)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val logger: Logger?

Logger used to print notifications

Link copied to clipboard
val neoOperations: ReactiveNeo4jOperations
Link copied to clipboard
val objectMapper: ObjectMapper
Link copied to clipboard

Functions

Link copied to clipboard
suspend fun issueState(imsProject: IMSProject, isOpen: Boolean): IssueState

Find and ensure the IMSIssueTemplate in the database

Link copied to clipboard
suspend fun issueTemplate(imsProject: IMSProject): IssueTemplate

Find and ensure the IMSTemplate in the database

Link copied to clipboard
suspend fun issueType(imsProject: IMSProject): IssueType

Find and ensure the IMSIssueTemplate in the database

Link copied to clipboard
suspend fun mapLabel(imsProject: IMSProject, labelData: LabelData): Label?

Map a Label from GitHub to Gropius

Link copied to clipboard
suspend fun mapUser(imsProject: IMSProject, userData: UserData?): User

Get a IMSUser for a GitHub user

Link copied to clipboard
inline suspend fun <D : Mutation.Data> mutation(imsProject: IMSProject, users: List<User>, body: Mutation<D>, owner: List<GropiusUser>): Pair<IMSUser, ApolloResponse<D>>

Send a mutation to the IMS

Link copied to clipboard
inline suspend fun <D : Query.Data> query(imsProject: IMSProject, users: List<User>, body: Query<D>): Pair<IMSUser, ApolloResponse<D>>

Send a query to the IMS

Link copied to clipboard
suspend fun tokenInTimeout(token: String): Boolean

Check windup timer for token

Link copied to clipboard
suspend fun windToken(token: String, seconds: Int)

Windup request blocking timer