Skip to content

Unused code is causing an exception in Quarkus at startup #1838

Closed
@DavideD

Description

@DavideD

See quarkusio/quarkus#38263

This is the code:

	// FIXME: We could add this method in ORM and override only this code
	protected MutationOperation createOperation(ValuesAnalysis valuesAnalysis, TableMutation<?> singleTableMutation) {
		MutationOperation operation = singleTableMutation.createMutationOperation( valuesAnalysis, factory() );
		if ( operation instanceof OptionalTableUpdateOperation ) {
			// We need to plug in our own reactive operation
			return new ReactiveOptionalTableUpdateOperation(
					operation.getMutationTarget(),
					(OptionalTableUpdate) singleTableMutation,
					factory()
			);
		}
		if ( operation instanceof DeleteOrUpsertOperation
				&& factory().getJdbcServices().getDialect() instanceof OracleDialect ) {
			OracleDialect dialect = ( (OracleDialect) factory().getJdbcServices().getDialect() );
			return dialect.createOptionalTableUpdateOperation(
					( (OptionalTableUpdate) operation ).getMutationTarget(),
					(OptionalTableUpdate) operation,
					factory()
			);
		}
		return operation;
	}

I suspect this is a leftover from some experiments.

A DeleteOrUpsertOperation cannot be cast to OptionalTableUpdate so I don't think this code is actually useful.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions