Skip to content

Commit

Permalink
Added these subsystems back to 2.0 schema subsystem list: ENC, STR, M…
Browse files Browse the repository at this point in the history
…2S, M3S, TINS
  • Loading branch information
abrighton committed Jun 4, 2020
1 parent e95e683 commit b2e9713
Show file tree
Hide file tree
Showing 3 changed files with 42 additions and 24 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ See also [JsonSchemaChanges.md](JsonSchemaChanges.md) for a list of changes in t

- Fixed a bug that requires rebuilding the icd database. This is done automatically when you run icdwebserver,
or you can run `icd-git --ingest` to do it manually.

- Added the following subsystems back to the allowed list for the 2.0 model file schema: ENC, STR, M2S, M3S, TINS
and created the related repos under https://github.com/tmt-icd/.


## [ICD v1.2.1] - 2020-06-01

Expand Down
9 changes: 7 additions & 2 deletions icd-db/src/main/resources/2.0/subsystem.conf
Original file line number Diff line number Diff line change
@@ -1,9 +1,14 @@
// Enumeration including all available subsystems

enum = [
SUM, // (SUM, Components: FMCS, HBS)
ENC, // Enclosure
SUM, // Summit Facilities
STR, // Structure
M2S, // M2 System
M3S, // M3 System
CLN, // Mirror Cleaning System
TCS, // Telescope Control System (Components K, CM, MCS, SHS, ENC, M2, M3, PFC, GMS...)
TINS, // Test Instruments
TCS, // Telescope Control System
M1CS, // M1 Control System
APS, // Alignment and Phasing System
OSS, // Observatory Safety System
Expand Down
53 changes: 31 additions & 22 deletions icd-git/src/main/scala/csw/services/icd/github/IcdGitManager.scala
Original file line number Diff line number Diff line change
Expand Up @@ -282,8 +282,13 @@ object IcdGitManager {
* @param updateTag if true, update the version tag on GitHub
* @return the entry for the removed API, if found
*/
def unpublish(sv: SubsystemAndVersion, user: String, password: String, comment: String,
updateTag: Boolean = true): Option[ApiVersionInfo] = {
def unpublish(
sv: SubsystemAndVersion,
user: String,
password: String,
comment: String,
updateTag: Boolean = true
): Option[ApiVersionInfo] = {
import ApiVersions._

def unpublishRelatedIcds(gitWorkDir: File): Unit = {
Expand Down Expand Up @@ -351,8 +356,14 @@ object IcdGitManager {
* @param updateTag if true, update the version tag on GitHub
* @return an object describing the published API
*/
def publish(subsystem: String, majorVersion: Boolean, user: String, password: String, comment: String,
updateTag: Boolean = true): ApiVersionInfo = {
def publish(
subsystem: String,
majorVersion: Boolean,
user: String,
password: String,
comment: String,
updateTag: Boolean = true
): ApiVersionInfo = {
// Checkout the icds repo in a temp dir
val gitWorkDir = Files.createTempDirectory("icds").toFile
try {
Expand Down Expand Up @@ -740,27 +751,25 @@ object IcdGitManager {
// This is used to speed up the check if a repo is empty. If the commit id changes,
// then we assume somebody added something.
private val emptyRepos = Map(
"CIS" -> "7f42a42871015c5e5bdaea64f49bd26619217314",
"CLN" -> "29eefda09df5b1415ca69724ee131aafadcb2f87",
"CRYO" -> "73714a1bee9fc38c4a14ab4e9e5d3bfa731c7136",
"CSW" -> "0be40700817fb3ffd4393aba58207a696ae16321",
"DMS" -> "f9b257eded51a2daf1b13b28ef16a781f21882c7",
"DPS" -> "132c3aacfb1f13bed0751bf4ead3ae14827b4092",
// "FMCS" -> "cc40c0589cbcfe299ed2166de85f2d6a83743643",
// "GMS" -> "ed5023527d099a042bbddd1c85d9ecdec9bf4942",
"CIS" -> "7f42a42871015c5e5bdaea64f49bd26619217314",
"CLN" -> "29eefda09df5b1415ca69724ee131aafadcb2f87",
"CRYO" -> "73714a1bee9fc38c4a14ab4e9e5d3bfa731c7136",
"CSW" -> "0be40700817fb3ffd4393aba58207a696ae16321",
"DMS" -> "f9b257eded51a2daf1b13b28ef16a781f21882c7",
"DPS" -> "132c3aacfb1f13bed0751bf4ead3ae14827b4092",
"ENC" -> "c950920d4c39fcf27d59e4c8d7566d7d2a4fb72f",
"LGSF" -> "b01dfa73a1f3e5c677f819aa855e8158e12c1bc5",
"M2S" -> "cfaaacc833812f210354db9d38befa80bdf00e4b",
"M3S" -> "c1d43e5289dd9cdbac379daad5ffb641db6ee29f",
"MODHIS" -> "6139728cc2e1c1ba64724c5cff40c16452ee8da9",
"NSCU" -> "5f26e4dd18bee60f0c631e625d4b02558dccd3e1",
// "PFCS" -> "a01b55689f5d36436c7018acfa0888f598bf6a7d",
// "PSFR" -> "21413dae346a90dba6e3dfb1fca53dab96d46d31",
"REFR" -> "e57687a18f61875deea19cb1ba83ceca3d1fc9a5",
// "RPG" -> "a62a7d5ee0354d5402124bfc56a88c46f9845979",
// "RTC" -> "45a2a564c0e57fe628e10214aa9f0924bfc4e8fe",
"SCMS" -> "13916c6a742b3f37f8c6a131a1ff9291edf3f781",
"SOSS" -> "48684f6dc2a54d290c69edbfdd4909528a2b27a7",
"SUM" -> "2864dbc7ec2dbdc5762405d57683c1c97a31cd12",
// "TINS" -> "4acb42a07e098f5acd3998a638ca11184b6e3110",
"WFOS" -> "330391bb97a21ff5c888594517019cb65f5c34fc"
"REFR" -> "e57687a18f61875deea19cb1ba83ceca3d1fc9a5",
"SCMS" -> "13916c6a742b3f37f8c6a131a1ff9291edf3f781",
"SOSS" -> "48684f6dc2a54d290c69edbfdd4909528a2b27a7",
"STR" -> "035688c16bbd991d08a22137b6804c78c24f75ba",
"SUM" -> "2864dbc7ec2dbdc5762405d57683c1c97a31cd12",
"TINS" -> "ba5ec70cafa2d7a3704b537bc38b3156909c6ff2",
"WFOS" -> "330391bb97a21ff5c888594517019cb65f5c34fc"
)

case class SubsystemGitInfo(commitId: String, isEmpty: Boolean)
Expand Down

0 comments on commit b2e9713

Please sign in to comment.