Upgrade Notes

Contents

Guillotine 8 requires XP 8.0.0 or higher. It will not install on XP 7.x.

Renamed X-data types

Generated types for X-data configs have been renamed from XData_* to Mixin_*. Update any queries, fragments or creationCallbacks that reference the old names.

  • Old way:

{
  guillotine {
    get(key: "/path/to/content") {
      ... on media_Image {
        xAsJson
        x {
          base_gpsInfo {
            ... on XData_base_gpsInfo_DataConfig {
              geoPoint
            }
          }
        }
      }
    }
  }
}
  • New way:

{
  guillotine {
    get(key: "/path/to/content") {
      ... on media_Image {
        xAsJson
        x {
          base_gpsInfo {
            ... on Mixin_base_gpsInfo_DataConfig {
              geoPoint
            }
          }
        }
      }
    }
  }
}

The following types were renamed:

Old name New name

XData_base_ApplicationConfig

Mixin_base_ApplicationConfig

XData_base_gpsInfo_DataConfig

Mixin_base_gpsInfo_DataConfig

XData_media_ApplicationConfig

Mixin_media_ApplicationConfig

XData_media_cameraInfo_DataConfig

Mixin_media_cameraInfo_DataConfig

XData_media_imageInfo_DataConfig

Mixin_media_imageInfo_DataConfig

Removed hasChildren field

The hasChildren: Boolean field has been removed from all types implementing Content. Query the children (or childrenConnection) field instead and check whether the result is empty.

  • Old way:

{
  guillotine {
    get(key: "/path/to/content") {
      hasChildren
    }
  }
}
  • New way:

{
  guillotine {
    get(key: "/path/to/content") {
      children {
        _id
      }
    }
  }
}

Removed inheritsPermissions field

The inheritsPermissions field has been removed from the Permissions type. The inheritance flag is no longer exposed through the GraphQL API, so simply remove it from your queries.

{
  guillotine {
    get(key: "/path/to/content") {
      permissions {
        inheritsPermissions (1)
        permissions {
          principal
          allow
          deny
        }
      }
    }
  }
}
1 Remove this field — it no longer exists.

Removed contentDisplayNameScript field

The contentDisplayNameScript field has been removed from ContentType (it always returned null). Remove it from your queries.

Renamed displayName to title on ContentType

The displayName field on ContentType is superseded by the new title field, which carries the same value. displayName is kept for backward compatibility but is deprecated and will be removed in a future major release. New code should query title instead.

  • Old way:

{
  guillotine {
    getType(name: "com.enonic.app.myapp:person") {
      displayName
    }
  }
}
  • New way:

{
  guillotine {
    getType(name: "com.enonic.app.myapp:person") {
      title
    }
  }
}

Long input type

For an Input form item of type Long, the returned value type has changed from String to Long. Update any client-side code that parsed the value as a string.

  • Old way: value returned as String

// "42"
const count = parseInt(data.count, 10);
  • New way: value returned as Long

// 42
const count = data.count;

CORS configuration

The CORS implementation has been reworked. The cors.enabled property has been removed — CORS is now enabled by configuring cors.origin and disabled when cors.origin is omitted. Previously CORS was enabled by default and allowed all origins when none were configured.

  • Old way:

cors.enabled=true
cors.origin=https://example.com
cors.methods=POST, OPTIONS
cors.allowedHeaders=Content-Type
  • New way:

cors.origin=https://example.com, https://admin.example.com (1)
cors.methods=POST, OPTIONS (2)
cors.allowedHeaders=Content-Type (3)
1 Setting cors.origin enables CORS. It now accepts multiple comma-separated values and supports (allow all), literal origins, and ~-prefixed regex patterns (e.g. ~https://.\.example\.com). Omit this property to disable CORS entirely.
2 The default for cors.methods changed from POST, OPTIONS to GET, HEAD, POST. Set it explicitly if you relied on the old default.
3 When cors.allowedHeaders is not configured, the request’s Access-Control-Request-Headers value is now reflected instead of defaulting to Content-Type. Set it explicitly to keep the previous behavior.

Contents

Contents