@Override public void enable(SchemaVersionLifecycleContext context) throws SchemaLifecycleException, IncompatibleSchemaException, SchemaNotFoundException, SchemaBranchNotFoundException { transitionToEnableState(context); }
private static Pair<SchemaVersionLifecycleStateTransition, SchemaVersionLifecycleStateAction> createStartReviewTransitionActionPair(Byte sourceStateId) { return Pair.of(new SchemaVersionLifecycleStateTransition(sourceStateId, START_REVIEW.getId(), "StartReview", "Starts review state"), context -> { try { transitionToStartReview(context); } catch (SchemaNotFoundException e) { throw new SchemaLifecycleException(e); } }); }
private static Pair<SchemaVersionLifecycleStateTransition, SchemaVersionLifecycleStateAction> createArchiveTransitionAction(Byte sourceStateId) { return Pair.of(new SchemaVersionLifecycleStateTransition(sourceStateId, ARCHIVED.getId(), "Archive", "Archives the schema version"), context -> { try { transitionToArchiveState(context); } catch (SchemaNotFoundException e) { throw new SchemaLifecycleException(e); } }); }
private static Pair<SchemaVersionLifecycleStateTransition, SchemaVersionLifecycleStateAction> createDeleteTransitionActionPair( Byte sourceStateId) { return Pair.of(new SchemaVersionLifecycleStateTransition(sourceStateId, DELETED.getId(), "Delete", "Deletes the schema version"), context -> { try { transitionToDeleteState(context); } catch (SchemaNotFoundException e) { throw new SchemaLifecycleException(e); } }); }
private static Pair<SchemaVersionLifecycleStateTransition, SchemaVersionLifecycleStateAction> createDisableAction(Byte sourceStateId) { return Pair.of(new SchemaVersionLifecycleStateTransition(sourceStateId, DISABLED.getId(), "Disable", "Disables the schema version"), context -> { try { transitionToDisableState(context); } catch (SchemaNotFoundException e) { throw new SchemaLifecycleException(e); } }); }
int curVersion = curSchemaVersionInfo.getVersion(); if (curVersion < schemaVersion) { checkCompatibility(schemaVersionService, schemaMetadata, schemaText, curSchemaVersionInfo.getSchemaText()); } else { checkCompatibility(schemaVersionService, schemaMetadata, curSchemaVersionInfo.getSchemaText(), for (; i < size && sortedSchemaVersionInfos.get(i).getVersion() < schemaVersion; i++) { String fromSchemaText = sortedSchemaVersionInfos.get(i).getSchemaText(); checkCompatibility(schemaVersionService, schemaMetadata, schemaText, fromSchemaText); checkCompatibility(schemaVersionService, schemaMetadata, toSchemaText, schemaText);
private static Pair<SchemaVersionLifecycleStateTransition, SchemaVersionLifecycleStateAction> createStartReviewTransitionActionPair(Byte sourceStateId) { return Pair.of(new SchemaVersionLifecycleStateTransition(sourceStateId, START_REVIEW.getId(), "StartReview", "Starts review state"), context -> { try { transitionToStartReview(context); } catch (SchemaNotFoundException e) { throw new SchemaLifecycleException(e); } }); }
private static Pair<SchemaVersionLifecycleStateTransition, SchemaVersionLifecycleStateAction> createArchiveTransitionAction(Byte sourceStateId) { return Pair.of(new SchemaVersionLifecycleStateTransition(sourceStateId, ARCHIVED.getId(), "Archive", "Archives the schema version"), context -> { try { transitionToArchiveState(context); } catch (SchemaNotFoundException e) { throw new SchemaLifecycleException(e); } }); }
private static Pair<SchemaVersionLifecycleStateTransition, SchemaVersionLifecycleStateAction> createDeleteTransitionActionPair( Byte sourceStateId) { return Pair.of(new SchemaVersionLifecycleStateTransition(sourceStateId, DELETED.getId(), "Delete", "Deletes the schema version"), context -> { try { transitionToDeleteState(context); } catch (SchemaNotFoundException e) { throw new SchemaLifecycleException(e); } }); }
private static Pair<SchemaVersionLifecycleStateTransition, SchemaVersionLifecycleStateAction> createDisableAction(Byte sourceStateId) { return Pair.of(new SchemaVersionLifecycleStateTransition(sourceStateId, DISABLED.getId(), "Disable", "Disables the schema version"), context -> { try { transitionToDisableState(context); } catch (SchemaNotFoundException e) { throw new SchemaLifecycleException(e); } }); }
int curVersion = curSchemaVersionInfo.getVersion(); if (curVersion < schemaVersion) { checkCompatibility(schemaVersionService, schemaMetadata, schemaText, curSchemaVersionInfo.getSchemaText()); } else { checkCompatibility(schemaVersionService, schemaMetadata, curSchemaVersionInfo.getSchemaText(), for (; i < size && sortedSchemaVersionInfos.get(i).getVersion() < schemaVersion; i++) { String fromSchemaText = sortedSchemaVersionInfos.get(i).getSchemaText(); checkCompatibility(schemaVersionService, schemaMetadata, schemaText, fromSchemaText); checkCompatibility(schemaVersionService, schemaMetadata, toSchemaText, schemaText);
@Override public void enable(SchemaVersionLifecycleContext context) throws SchemaLifecycleException, IncompatibleSchemaException, SchemaNotFoundException, SchemaBranchNotFoundException { transitionToEnableState(context); }
@Override public void enable(SchemaVersionLifecycleContext context) throws SchemaLifecycleException, IncompatibleSchemaException, SchemaNotFoundException, SchemaBranchNotFoundException { transitionToEnableState(context); }
@Override public void enable(SchemaVersionLifecycleContext context) throws SchemaLifecycleException, IncompatibleSchemaException, SchemaNotFoundException, SchemaBranchNotFoundException { transitionToEnableState(context); }
@Override public void enable(SchemaVersionLifecycleContext context) throws SchemaLifecycleException, IncompatibleSchemaException, SchemaNotFoundException, SchemaBranchNotFoundException { transitionToEnableState(context); }
@Override public void enable(SchemaVersionLifecycleContext context) throws SchemaLifecycleException, IncompatibleSchemaException, SchemaNotFoundException, SchemaBranchNotFoundException { transitionToEnableState(context); }
private static Pair<SchemaVersionLifecycleStateTransition, SchemaVersionLifecycleStateAction> createEnableTransitionAction(Byte sourceStateId) { return Pair.of(new SchemaVersionLifecycleStateTransition(sourceStateId, ENABLED.getId(), "Enable", "Enables the schema version"), context -> { try { transitionToEnableState(context); } catch (SchemaNotFoundException | IncompatibleSchemaException | SchemaBranchNotFoundException e) { throw new SchemaLifecycleException(e); } }); }
private static Pair<SchemaVersionLifecycleStateTransition, SchemaVersionLifecycleStateAction> createEnableTransitionAction(Byte sourceStateId) { return Pair.of(new SchemaVersionLifecycleStateTransition(sourceStateId, ENABLED.getId(), "Enable", "Enables the schema version"), context -> { try { transitionToEnableState(context); } catch (SchemaNotFoundException | IncompatibleSchemaException | SchemaBranchNotFoundException e) { throw new SchemaLifecycleException(e); } }); }