├── .gitattributes ├── .github ├── PULL_REQUEST_TEMPLATE.md ├── hibernate-github-bot.yml └── workflows │ └── build.yml ├── .gitignore ├── .mvn └── wrapper │ ├── maven-wrapper.jar │ └── maven-wrapper.properties ├── .travis.yml ├── CONTRIBUTING.md ├── README.md ├── bom └── pom.xml ├── changelog.txt ├── ci └── release │ └── Jenkinsfile ├── core ├── pom.xml └── src │ ├── main │ ├── java │ │ └── org │ │ │ └── hibernate │ │ │ ├── ogm │ │ │ ├── OgmSession.java │ │ │ ├── OgmSessionFactory.java │ │ │ ├── boot │ │ │ │ ├── OgmSessionFactoryBuilder.java │ │ │ │ ├── OgmSessionFactoryBuilderImplementor.java │ │ │ │ ├── impl │ │ │ │ │ ├── OgmConfigurationServiceImpl.java │ │ │ │ │ ├── OgmMetadataBuilderInitializer.java │ │ │ │ │ ├── OgmServiceRegistryInitializer.java │ │ │ │ │ ├── OgmSessionFactoryBuilderFactory.java │ │ │ │ │ ├── OgmSessionFactoryBuilderImpl.java │ │ │ │ │ └── OgmSessionFactoryOptions.java │ │ │ │ └── model │ │ │ │ │ └── naming │ │ │ │ │ └── impl │ │ │ │ │ └── OgmImplicitNamingStrategy.java │ │ │ ├── cfg │ │ │ │ ├── Configurable.java │ │ │ │ ├── OgmConfiguration.java │ │ │ │ ├── OgmProperties.java │ │ │ │ ├── OptionConfigurator.java │ │ │ │ ├── impl │ │ │ │ │ ├── ConfigurableImpl.java │ │ │ │ │ ├── HibernateSearchIntegration.java │ │ │ │ │ ├── HostParser.java │ │ │ │ │ ├── InternalProperties.java │ │ │ │ │ └── Version.java │ │ │ │ └── spi │ │ │ │ │ ├── DocumentStoreConfiguration.java │ │ │ │ │ └── Hosts.java │ │ │ ├── compensation │ │ │ │ ├── BaseErrorHandler.java │ │ │ │ ├── ErrorHandler.java │ │ │ │ ├── ErrorHandlingStrategy.java │ │ │ │ ├── impl │ │ │ │ │ ├── ErrorHandlerEnabledTransactionCoordinatorBuilder.java │ │ │ │ │ ├── ErrorHandlerEnabledTransactionCoordinatorDecorator.java │ │ │ │ │ ├── InvocationCollectingGridDialect.java │ │ │ │ │ └── OperationCollector.java │ │ │ │ └── operation │ │ │ │ │ ├── CreateAssociationWithKey.java │ │ │ │ │ ├── CreateTuple.java │ │ │ │ │ ├── CreateTupleWithKey.java │ │ │ │ │ ├── ExecuteBatch.java │ │ │ │ │ ├── FlushPendingOperations.java │ │ │ │ │ ├── GridDialectOperation.java │ │ │ │ │ ├── InsertOrUpdateAssociation.java │ │ │ │ │ ├── InsertOrUpdateTuple.java │ │ │ │ │ ├── InsertTuple.java │ │ │ │ │ ├── OperationType.java │ │ │ │ │ ├── RemoveAssociation.java │ │ │ │ │ ├── RemoveTuple.java │ │ │ │ │ ├── RemoveTupleWithOptimisticLock.java │ │ │ │ │ ├── UpdateTupleWithOptimisticLock.java │ │ │ │ │ └── impl │ │ │ │ │ ├── CreateAssociationWithKeyImpl.java │ │ │ │ │ ├── CreateTupleImpl.java │ │ │ │ │ ├── CreateTupleWithKeyImpl.java │ │ │ │ │ ├── ExecuteBatchImpl.java │ │ │ │ │ ├── FlushPendingOperationsImpl.java │ │ │ │ │ ├── InsertOrUpdateAssociationImpl.java │ │ │ │ │ ├── InsertOrUpdateTupleImpl.java │ │ │ │ │ ├── InsertTupleImpl.java │ │ │ │ │ ├── RemoveAssociationImpl.java │ │ │ │ │ ├── RemoveTupleImpl.java │ │ │ │ │ ├── RemoveTupleWithOptimisticLockImpl.java │ │ │ │ │ └── UpdateTupleWithOptimisticLockImpl.java │ │ │ ├── datastore │ │ │ │ ├── document │ │ │ │ │ ├── association │ │ │ │ │ │ ├── impl │ │ │ │ │ │ │ └── DocumentHelpers.java │ │ │ │ │ │ └── spi │ │ │ │ │ │ │ ├── AssociationRow.java │ │ │ │ │ │ │ ├── AssociationRowFactory.java │ │ │ │ │ │ │ ├── AssociationRows.java │ │ │ │ │ │ │ ├── StructureOptimizerAssociationRowFactory.java │ │ │ │ │ │ │ └── package-info.java │ │ │ │ │ ├── cfg │ │ │ │ │ │ └── DocumentStoreProperties.java │ │ │ │ │ ├── impl │ │ │ │ │ │ ├── DotPatternMapHelpers.java │ │ │ │ │ │ ├── EmbeddableStateFinder.java │ │ │ │ │ │ └── MapAssociationRowsHelpers.java │ │ │ │ │ └── options │ │ │ │ │ │ ├── AssociationStorage.java │ │ │ │ │ │ ├── AssociationStorageType.java │ │ │ │ │ │ ├── MapStorage.java │ │ │ │ │ │ ├── MapStorageType.java │ │ │ │ │ │ ├── impl │ │ │ │ │ │ ├── AssociationStorageConverter.java │ │ │ │ │ │ └── MapStorageConverter.java │ │ │ │ │ │ ├── navigation │ │ │ │ │ │ ├── DocumentStoreEntityContext.java │ │ │ │ │ │ ├── DocumentStoreGlobalContext.java │ │ │ │ │ │ ├── DocumentStorePropertyContext.java │ │ │ │ │ │ └── spi │ │ │ │ │ │ │ ├── BaseDocumentStoreEntityContext.java │ │ │ │ │ │ │ ├── BaseDocumentStoreGlobalContext.java │ │ │ │ │ │ │ └── BaseDocumentStorePropertyContext.java │ │ │ │ │ │ └── spi │ │ │ │ │ │ ├── AssociationStorageOption.java │ │ │ │ │ │ └── MapStorageOption.java │ │ │ │ ├── impl │ │ │ │ │ ├── DatastoreProviderInitiator.java │ │ │ │ │ ├── DatastoreProviderType.java │ │ │ │ │ ├── EmptyAssociationSnapshot.java │ │ │ │ │ ├── EmptyTupleSnapshot.java │ │ │ │ │ ├── SchemaDefinerInitiator.java │ │ │ │ │ └── SetFromCollection.java │ │ │ │ ├── keyvalue │ │ │ │ │ ├── cfg │ │ │ │ │ │ └── KeyValueStoreProperties.java │ │ │ │ │ └── options │ │ │ │ │ │ ├── CacheMappingType.java │ │ │ │ │ │ ├── navigation │ │ │ │ │ │ ├── KeyValueStoreEntityContext.java │ │ │ │ │ │ ├── KeyValueStoreGlobalContext.java │ │ │ │ │ │ ├── KeyValueStorePropertyContext.java │ │ │ │ │ │ └── spi │ │ │ │ │ │ │ ├── BaseKeyValueStoreEntityContext.java │ │ │ │ │ │ │ ├── BaseKeyValueStoreGlobalContext.java │ │ │ │ │ │ │ └── BaseKeyValueStorePropertyContext.java │ │ │ │ │ │ └── spi │ │ │ │ │ │ └── CacheMappingOption.java │ │ │ │ ├── map │ │ │ │ │ ├── MapDatastore.java │ │ │ │ │ └── impl │ │ │ │ │ │ ├── MapAssociationSnapshot.java │ │ │ │ │ │ ├── MapDatastoreProvider.java │ │ │ │ │ │ ├── MapDialect.java │ │ │ │ │ │ ├── MapHelpers.java │ │ │ │ │ │ ├── MapPessimisticReadLockingStrategy.java │ │ │ │ │ │ ├── MapPessimisticWriteLockingStrategy.java │ │ │ │ │ │ └── MapTupleSnapshot.java │ │ │ │ └── spi │ │ │ │ │ ├── BaseDatastoreProvider.java │ │ │ │ │ ├── BaseSchemaDefiner.java │ │ │ │ │ ├── DatastoreConfiguration.java │ │ │ │ │ ├── DatastoreProvider.java │ │ │ │ │ └── SchemaDefiner.java │ │ │ ├── dialect │ │ │ │ ├── batch │ │ │ │ │ └── spi │ │ │ │ │ │ ├── BatchableGridDialect.java │ │ │ │ │ │ ├── GroupableEntityOperation.java │ │ │ │ │ │ ├── GroupedChangesToEntityOperation.java │ │ │ │ │ │ ├── GroupingByEntityDialect.java │ │ │ │ │ │ ├── InsertOrUpdateAssociationOperation.java │ │ │ │ │ │ ├── InsertOrUpdateTupleOperation.java │ │ │ │ │ │ ├── Operation.java │ │ │ │ │ │ ├── OperationsQueue.java │ │ │ │ │ │ ├── RemoveAssociationOperation.java │ │ │ │ │ │ └── RemoveTupleOperation.java │ │ │ │ ├── eventstate │ │ │ │ │ └── impl │ │ │ │ │ │ ├── EventContextManager.java │ │ │ │ │ │ ├── EventContextManagerInitiator.java │ │ │ │ │ │ ├── EventContextManagingAutoFlushEventListener.java │ │ │ │ │ │ ├── EventContextManagingFlushEventListener.java │ │ │ │ │ │ ├── EventContextManagingPersistEventListener.java │ │ │ │ │ │ ├── EventStateLifecycle.java │ │ │ │ │ │ └── EventStateLifecycles.java │ │ │ │ ├── identity │ │ │ │ │ └── spi │ │ │ │ │ │ └── IdentityColumnAwareGridDialect.java │ │ │ │ ├── impl │ │ │ │ │ ├── AbstractGroupingByEntityDialect.java │ │ │ │ │ ├── AssociationContextImpl.java │ │ │ │ │ ├── AssociationTypeContextImpl.java │ │ │ │ │ ├── BatchOperationsDelegator.java │ │ │ │ │ ├── EmptyTransactionContext.java │ │ │ │ │ ├── ExceptionThrowingLockingStrategy.java │ │ │ │ │ ├── ForwardingGridDialect.java │ │ │ │ │ ├── GridDialectInitiator.java │ │ │ │ │ ├── GridDialectLogger.java │ │ │ │ │ ├── GridDialects.java │ │ │ │ │ ├── IdentifiableDriver.java │ │ │ │ │ ├── IdentityColumnAwareGridDialectInitiator.java │ │ │ │ │ ├── MultigetGridDialectInitiator.java │ │ │ │ │ ├── NoOpMultiTableBulkIdStrategy.java │ │ │ │ │ ├── OgmDialect.java │ │ │ │ │ ├── OgmDialectFactoryInitiator.java │ │ │ │ │ ├── OptimisticLockingAwareGridDialectInitiator.java │ │ │ │ │ ├── QueryableGridDialectInitiator.java │ │ │ │ │ ├── SessionFactoryLifecycleAwareDialectInitializer.java │ │ │ │ │ ├── StoredProcedureGridDialectInitiator.java │ │ │ │ │ ├── TransactionContextImpl.java │ │ │ │ │ ├── TupleContextImpl.java │ │ │ │ │ └── TupleTypeContextImpl.java │ │ │ │ ├── multiget │ │ │ │ │ └── spi │ │ │ │ │ │ └── MultigetGridDialect.java │ │ │ │ ├── optimisticlock │ │ │ │ │ └── spi │ │ │ │ │ │ └── OptimisticLockingAwareGridDialect.java │ │ │ │ ├── query │ │ │ │ │ └── spi │ │ │ │ │ │ ├── BackendQuery.java │ │ │ │ │ │ ├── ClosableIterator.java │ │ │ │ │ │ ├── NoOpParameterMetadataBuilder.java │ │ │ │ │ │ ├── ParameterMetadataBuilder.java │ │ │ │ │ │ ├── QueryParameters.java │ │ │ │ │ │ ├── QueryableGridDialect.java │ │ │ │ │ │ ├── RecognizerBasedParameterMetadataBuilder.java │ │ │ │ │ │ ├── RowSelection.java │ │ │ │ │ │ └── TypedGridValue.java │ │ │ │ ├── spi │ │ │ │ │ ├── AssociationContext.java │ │ │ │ │ ├── AssociationTypeContext.java │ │ │ │ │ ├── BaseGridDialect.java │ │ │ │ │ ├── DuplicateInsertPreventionStrategy.java │ │ │ │ │ ├── GridDialect.java │ │ │ │ │ ├── ModelConsumer.java │ │ │ │ │ ├── NextValueRequest.java │ │ │ │ │ ├── OperationContext.java │ │ │ │ │ ├── SessionFactoryLifecycleAwareDialect.java │ │ │ │ │ ├── TransactionContext.java │ │ │ │ │ ├── TupleAlreadyExistsException.java │ │ │ │ │ ├── TupleContext.java │ │ │ │ │ ├── TupleTypeContext.java │ │ │ │ │ └── TuplesSupplier.java │ │ │ │ └── storedprocedure │ │ │ │ │ └── spi │ │ │ │ │ └── StoredProcedureAwareGridDialect.java │ │ │ ├── engine │ │ │ │ └── spi │ │ │ │ │ ├── OgmSessionBuilderImplementor.java │ │ │ │ │ └── OgmSessionFactoryImplementor.java │ │ │ ├── entityentry │ │ │ │ └── impl │ │ │ │ │ ├── OgmEntityEntryState.java │ │ │ │ │ └── TuplePointer.java │ │ │ ├── exception │ │ │ │ ├── EntityAlreadyExistsException.java │ │ │ │ ├── NotSupportedException.java │ │ │ │ └── impl │ │ │ │ │ └── Exceptions.java │ │ │ ├── hibernatecore │ │ │ │ └── impl │ │ │ │ │ ├── BackendCustomLoader.java │ │ │ │ │ ├── OgmSessionBuilderDelegator.java │ │ │ │ │ ├── OgmSessionFactoryImpl.java │ │ │ │ │ ├── OgmSessionImpl.java │ │ │ │ │ └── OgmSharedSessionBuilderDelegator.java │ │ │ ├── id │ │ │ │ ├── impl │ │ │ │ │ ├── OgmGeneratorBase.java │ │ │ │ │ ├── OgmIdentityColumnSupport.java │ │ │ │ │ ├── OgmIdentityGenerator.java │ │ │ │ │ ├── OgmSequenceGenerator.java │ │ │ │ │ └── OgmTableGenerator.java │ │ │ │ └── spi │ │ │ │ │ └── PersistentNoSqlIdentifierGenerator.java │ │ │ ├── jdbc │ │ │ │ └── impl │ │ │ │ │ ├── NoopConnection.java │ │ │ │ │ ├── NoopConnectionProvider.java │ │ │ │ │ ├── NoopDatabaseMetaData.java │ │ │ │ │ ├── NoopStatement.java │ │ │ │ │ ├── OgmConnectionProviderInitiator.java │ │ │ │ │ └── TupleAsMapResultSet.java │ │ │ ├── jpa │ │ │ │ ├── HibernateOgmPersistence.java │ │ │ │ └── impl │ │ │ │ │ ├── DelegatorPersistenceUnitInfo.java │ │ │ │ │ ├── LetThroughExecuteUpdateQuery.java │ │ │ │ │ ├── OgmExceptionMapper.java │ │ │ │ │ ├── OgmMutableIdentifierGeneratorFactory.java │ │ │ │ │ ├── OgmMutableIdentifierGeneratorFactoryInitiator.java │ │ │ │ │ ├── OgmPersisterClassResolver.java │ │ │ │ │ └── OgmPersisterClassResolverInitiator.java │ │ │ ├── loader │ │ │ │ ├── entity │ │ │ │ │ └── impl │ │ │ │ │ │ ├── BatchableEntityLoader.java │ │ │ │ │ │ ├── BatchingEntityLoader.java │ │ │ │ │ │ ├── BatchingEntityLoaderBuilder.java │ │ │ │ │ │ ├── DynamicBatchingEntityLoaderBuilder.java │ │ │ │ │ │ └── OgmBatchableEntityLoaderBuilder.java │ │ │ │ ├── impl │ │ │ │ │ ├── OgmBasicCollectionLoader.java │ │ │ │ │ ├── OgmColumnCollectionAliases.java │ │ │ │ │ ├── OgmLoader.java │ │ │ │ │ ├── OgmLoadingContext.java │ │ │ │ │ └── TupleBasedEntityLoader.java │ │ │ │ └── nativeloader │ │ │ │ │ └── impl │ │ │ │ │ └── BackendCustomQuery.java │ │ │ ├── massindex │ │ │ │ └── impl │ │ │ │ │ ├── BatchCoordinator.java │ │ │ │ │ ├── BatchIndexingWorkspace.java │ │ │ │ │ ├── Executors.java │ │ │ │ │ ├── Helper.java │ │ │ │ │ ├── OgmMassIndexer.java │ │ │ │ │ ├── OgmMassIndexerFactory.java │ │ │ │ │ ├── OptionallyWrapInJTATransaction.java │ │ │ │ │ ├── SessionAwareRunnable.java │ │ │ │ │ └── TupleIndexer.java │ │ │ ├── model │ │ │ │ ├── impl │ │ │ │ │ ├── DefaultAssociatedEntityKeyMetadata.java │ │ │ │ │ ├── DefaultAssociationKeyMetadata.java │ │ │ │ │ ├── DefaultEntityKeyMetadata.java │ │ │ │ │ ├── DefaultIdSourceKeyMetadata.java │ │ │ │ │ ├── EntityKeyBuilder.java │ │ │ │ │ └── RowKeyBuilder.java │ │ │ │ ├── key │ │ │ │ │ └── spi │ │ │ │ │ │ ├── AssociatedEntityKeyMetadata.java │ │ │ │ │ │ ├── AssociationKey.java │ │ │ │ │ │ ├── AssociationKeyMetadata.java │ │ │ │ │ │ ├── AssociationKind.java │ │ │ │ │ │ ├── AssociationType.java │ │ │ │ │ │ ├── EntityKey.java │ │ │ │ │ │ ├── EntityKeyMetadata.java │ │ │ │ │ │ ├── IdSourceKey.java │ │ │ │ │ │ ├── IdSourceKeyMetadata.java │ │ │ │ │ │ └── RowKey.java │ │ │ │ └── spi │ │ │ │ │ ├── Association.java │ │ │ │ │ ├── AssociationOperation.java │ │ │ │ │ ├── AssociationOperationType.java │ │ │ │ │ ├── AssociationOrderBy.java │ │ │ │ │ ├── AssociationSnapshot.java │ │ │ │ │ ├── EntityMetadataInformation.java │ │ │ │ │ ├── Tuple.java │ │ │ │ │ ├── TupleOperation.java │ │ │ │ │ ├── TupleOperationType.java │ │ │ │ │ └── TupleSnapshot.java │ │ │ ├── options │ │ │ │ ├── container │ │ │ │ │ └── impl │ │ │ │ │ │ ├── EmptyOptionsContainer.java │ │ │ │ │ │ ├── OptionsContainer.java │ │ │ │ │ │ └── OptionsContainerBuilder.java │ │ │ │ ├── navigation │ │ │ │ │ ├── EntityContext.java │ │ │ │ │ ├── GlobalContext.java │ │ │ │ │ ├── PropertyContext.java │ │ │ │ │ ├── impl │ │ │ │ │ │ ├── AppendableConfigurationContext.java │ │ │ │ │ │ ├── ConfigurationContextImpl.java │ │ │ │ │ │ ├── OptionsContextImpl.java │ │ │ │ │ │ ├── OptionsServiceImpl.java │ │ │ │ │ │ ├── OptionsServiceInitiator.java │ │ │ │ │ │ └── PropertyKey.java │ │ │ │ │ ├── source │ │ │ │ │ │ └── impl │ │ │ │ │ │ │ ├── AnnotationOptionValueSource.java │ │ │ │ │ │ │ ├── ConfigurationOptionValueSource.java │ │ │ │ │ │ │ ├── OptionValueSource.java │ │ │ │ │ │ │ ├── OptionValueSources.java │ │ │ │ │ │ │ ├── ProgrammaticOptionValueSource.java │ │ │ │ │ │ │ └── package-info.java │ │ │ │ │ └── spi │ │ │ │ │ │ ├── BaseContext.java │ │ │ │ │ │ ├── BaseEntityContext.java │ │ │ │ │ │ ├── BaseGlobalContext.java │ │ │ │ │ │ ├── BasePropertyContext.java │ │ │ │ │ │ ├── ConfigurationContext.java │ │ │ │ │ │ └── GenericOptionModel.java │ │ │ │ ├── package-info.java │ │ │ │ ├── shared │ │ │ │ │ ├── IndexOption.java │ │ │ │ │ ├── IndexOptions.java │ │ │ │ │ ├── impl │ │ │ │ │ │ ├── IndexOptionsConverter.java │ │ │ │ │ │ └── IndexOptionsOption.java │ │ │ │ │ └── spi │ │ │ │ │ │ ├── IndexOption.java │ │ │ │ │ │ └── IndexOptions.java │ │ │ │ └── spi │ │ │ │ │ ├── AnnotationConverter.java │ │ │ │ │ ├── MappingOption.java │ │ │ │ │ ├── Option.java │ │ │ │ │ ├── OptionValuePair.java │ │ │ │ │ ├── OptionsContext.java │ │ │ │ │ ├── OptionsService.java │ │ │ │ │ └── UniqueOption.java │ │ │ ├── persister │ │ │ │ └── impl │ │ │ │ │ ├── BiDirectionalAssociationHelper.java │ │ │ │ │ ├── CollectionPhysicalModel.java │ │ │ │ │ ├── ColumnBasedDiscriminator.java │ │ │ │ │ ├── EntityAssociationUpdater.java │ │ │ │ │ ├── EntityDiscriminator.java │ │ │ │ │ ├── NotNeededDiscriminator.java │ │ │ │ │ ├── OgmCollectionPersister.java │ │ │ │ │ ├── OgmEntityPersister.java │ │ │ │ │ ├── SingleTableOgmEntityPersister.java │ │ │ │ │ ├── TablePerClassDiscriminator.java │ │ │ │ │ └── UnionSubclassOgmEntityPersister.java │ │ │ ├── query │ │ │ │ ├── impl │ │ │ │ │ ├── FullTextSearchQueryTranslator.java │ │ │ │ │ ├── LegacyParserBridgeQueryTranslator.java │ │ │ │ │ ├── NativeNoSqlQueryInterpreter.java │ │ │ │ │ ├── NativeNoSqlQueryPlan.java │ │ │ │ │ ├── NativeNoSqlQuerySpecification.java │ │ │ │ │ ├── OGMOrderByParser.java │ │ │ │ │ ├── OGMOrderByRendered.java │ │ │ │ │ ├── OgmQueryLoader.java │ │ │ │ │ ├── OgmQueryTranslator.java │ │ │ │ │ ├── OgmQueryTranslatorFactory.java │ │ │ │ │ └── OgmQueryTranslatorFactoryInitiator.java │ │ │ │ ├── parsing │ │ │ │ │ └── impl │ │ │ │ │ │ ├── HibernateOGMQueryResolverDelegate.java │ │ │ │ │ │ ├── KeepNamedParametersQueryRendererDelegate.java │ │ │ │ │ │ └── ParserPropertyHelper.java │ │ │ │ └── spi │ │ │ │ │ ├── BaseQueryParserService.java │ │ │ │ │ ├── QueryParserService.java │ │ │ │ │ └── QueryParsingResult.java │ │ │ ├── service │ │ │ │ └── impl │ │ │ │ │ ├── DefaultSchemaInitializationContext.java │ │ │ │ │ ├── NativeNoSqlQueryInterpreterInitiator.java │ │ │ │ │ ├── OgmConfigurationService.java │ │ │ │ │ ├── OgmIntegrator.java │ │ │ │ │ ├── OgmJdbcServicesInitiator.java │ │ │ │ │ ├── OgmSessionFactoryServiceContributor.java │ │ │ │ │ ├── OgmSessionFactoryServiceInitiators.java │ │ │ │ │ ├── OgmSessionFactoryServiceRegistryFactoryImpl.java │ │ │ │ │ ├── OgmSessionFactoryServiceRegistryFactoryInitiator.java │ │ │ │ │ ├── QueryParserServicesInitiator.java │ │ │ │ │ ├── SchemaDefiningObserver.java │ │ │ │ │ └── SessionFactoryEntityNamesResolver.java │ │ │ ├── storedprocedure │ │ │ │ ├── ProcedureQueryParameters.java │ │ │ │ └── impl │ │ │ │ │ ├── NoSQLProcedureCallMemento.java │ │ │ │ │ ├── NoSQLProcedureOutputsImpl.java │ │ │ │ │ └── NoSQLProcedureResultSetOutputImpl.java │ │ │ ├── transaction │ │ │ │ ├── emulated │ │ │ │ │ └── impl │ │ │ │ │ │ └── EmulatedLocalTransactionCoordinatorBuilder.java │ │ │ │ ├── impl │ │ │ │ │ ├── ForwardingTransactionCoordinator.java │ │ │ │ │ ├── ForwardingTransactionCoordinatorBuilder.java │ │ │ │ │ ├── ForwardingTransactionCoordinatorOwner.java │ │ │ │ │ ├── ForwardingTransactionDriver.java │ │ │ │ │ ├── OgmJtaPlatformInitiator.java │ │ │ │ │ ├── OgmTransactionCoordinatorBuilderInitiator.java │ │ │ │ │ └── package-info.java │ │ │ │ └── jta │ │ │ │ │ └── impl │ │ │ │ │ └── RollbackOnCommitFailureJtaTransactionCoordinatorBuilder.java │ │ │ ├── type │ │ │ │ ├── descriptor │ │ │ │ │ └── impl │ │ │ │ │ │ ├── AttributeConverterGridTypeDescriptorAdaptor.java │ │ │ │ │ │ ├── BasicGridBinder.java │ │ │ │ │ │ ├── BasicGridExtractor.java │ │ │ │ │ │ ├── ByteArrayMappedGridTypeDescriptor.java │ │ │ │ │ │ ├── ByteMappedGridTypeDescriptor.java │ │ │ │ │ │ ├── CalendarTimeZoneDateTimeTypeDescriptor.java │ │ │ │ │ │ ├── CharMappedGridTypeDescriptor.java │ │ │ │ │ │ ├── GridTypeDescriptor.java │ │ │ │ │ │ ├── GridValueBinder.java │ │ │ │ │ │ ├── GridValueExtractor.java │ │ │ │ │ │ ├── IntegerMappedGridTypeDescriptor.java │ │ │ │ │ │ ├── Iso8601CalendarTypeDescriptor.java │ │ │ │ │ │ ├── Iso8601DateTypeDescriptor.java │ │ │ │ │ │ ├── LongMappedGridTypeDescriptor.java │ │ │ │ │ │ ├── PassThroughGridTypeDescriptor.java │ │ │ │ │ │ ├── StringMappedGridExtractor.java │ │ │ │ │ │ ├── StringMappedGridTypeDescriptor.java │ │ │ │ │ │ ├── TimestampDateTypeDescriptor.java │ │ │ │ │ │ ├── TimestampMappedAsStringGridTypeDescriptor.java │ │ │ │ │ │ └── WrappedGridTypeDescriptor.java │ │ │ │ ├── impl │ │ │ │ │ ├── AbstractGenericBasicType.java │ │ │ │ │ ├── AttributeConverterGridTypeAdaptor.java │ │ │ │ │ ├── BigDecimalPassThroughType.java │ │ │ │ │ ├── BigDecimalType.java │ │ │ │ │ ├── BigIntegerType.java │ │ │ │ │ ├── BooleanType.java │ │ │ │ │ ├── ByteArrayStringType.java │ │ │ │ │ ├── ByteMappedType.java │ │ │ │ │ ├── ByteStringType.java │ │ │ │ │ ├── ByteType.java │ │ │ │ │ ├── CalendarDateType.java │ │ │ │ │ ├── CalendarType.java │ │ │ │ │ ├── CharacterStringType.java │ │ │ │ │ ├── CharacterType.java │ │ │ │ │ ├── ClassType.java │ │ │ │ │ ├── CollectionType.java │ │ │ │ │ ├── ComponentType.java │ │ │ │ │ ├── DateType.java │ │ │ │ │ ├── DoubleType.java │ │ │ │ │ ├── EntityType.java │ │ │ │ │ ├── EnumType.java │ │ │ │ │ ├── FloatType.java │ │ │ │ │ ├── GridTypeDelegatingToCoreType.java │ │ │ │ │ ├── IntegerMappedType.java │ │ │ │ │ ├── IntegerType.java │ │ │ │ │ ├── Iso8601StringCalendarType.java │ │ │ │ │ ├── Iso8601StringDateType.java │ │ │ │ │ ├── LocalDateAsStringType.java │ │ │ │ │ ├── LocalDateTimeAsStringType.java │ │ │ │ │ ├── LocalDateTimeType.java │ │ │ │ │ ├── LocalDateType.java │ │ │ │ │ ├── LocalTimeAsStringType.java │ │ │ │ │ ├── LocalTimeType.java │ │ │ │ │ ├── LongMappedType.java │ │ │ │ │ ├── LongType.java │ │ │ │ │ ├── ManyToOneType.java │ │ │ │ │ ├── NumericBooleanType.java │ │ │ │ │ ├── OneToOneType.java │ │ │ │ │ ├── PrimitiveByteArrayMappedType.java │ │ │ │ │ ├── PrimitiveByteArrayStringType.java │ │ │ │ │ ├── PrimitiveByteArrayType.java │ │ │ │ │ ├── SerializableAsByteArrayType.java │ │ │ │ │ ├── SerializableAsStringType.java │ │ │ │ │ ├── ShortType.java │ │ │ │ │ ├── StringCalendarDateType.java │ │ │ │ │ ├── StringDateTypeDescriptor.java │ │ │ │ │ ├── StringTimestampTypeDescriptor.java │ │ │ │ │ ├── StringType.java │ │ │ │ │ ├── TimeGridTypeDescriptor.java │ │ │ │ │ ├── TimeType.java │ │ │ │ │ ├── TimestampAsDateType.java │ │ │ │ │ ├── TimestampGridTypeDescriptor.java │ │ │ │ │ ├── TimestampType.java │ │ │ │ │ ├── TrueFalseType.java │ │ │ │ │ ├── TypeTranslatorImpl.java │ │ │ │ │ ├── TypeTranslatorInitiator.java │ │ │ │ │ ├── UUIDType.java │ │ │ │ │ ├── UrlType.java │ │ │ │ │ ├── WrapperBinaryType.java │ │ │ │ │ └── YesNoType.java │ │ │ │ └── spi │ │ │ │ │ ├── GridType.java │ │ │ │ │ └── TypeTranslator.java │ │ │ └── util │ │ │ │ ├── Experimental.java │ │ │ │ ├── configurationreader │ │ │ │ ├── impl │ │ │ │ │ ├── DefaultClassPropertyReaderContext.java │ │ │ │ │ ├── Instantiator.java │ │ │ │ │ ├── PropertyReaderContextBase.java │ │ │ │ │ ├── SimplePropertyReaderContext.java │ │ │ │ │ └── Validators.java │ │ │ │ └── spi │ │ │ │ │ ├── ClassPropertyReaderContext.java │ │ │ │ │ ├── ConfigurationPropertyReader.java │ │ │ │ │ ├── PropertyReaderContext.java │ │ │ │ │ ├── PropertyValidator.java │ │ │ │ │ └── ShortNameResolver.java │ │ │ │ ├── impl │ │ │ │ ├── ArrayHelper.java │ │ │ │ ├── AssociationPersister.java │ │ │ │ ├── ClassObjectFormatter.java │ │ │ │ ├── CollectionHelper.java │ │ │ │ ├── Contracts.java │ │ │ │ ├── CoreLogCategories.java │ │ │ │ ├── CustomLoaderHelper.java │ │ │ │ ├── EffectivelyFinal.java │ │ │ │ ├── EmbeddedHelper.java │ │ │ │ ├── Immutable.java │ │ │ │ ├── JndiHelper.java │ │ │ │ ├── Log.java │ │ │ │ ├── LoggerFactory.java │ │ │ │ ├── LogicalPhysicalConverterHelper.java │ │ │ │ ├── ReflectionHelper.java │ │ │ │ ├── ResourceHelper.java │ │ │ │ ├── StringHelper.java │ │ │ │ ├── TemporaryWorkaround.java │ │ │ │ ├── TransactionContextHelper.java │ │ │ │ ├── TupleContextHelper.java │ │ │ │ └── TupleExtractor.java │ │ │ │ └── parser │ │ │ │ └── impl │ │ │ │ └── LikeExpressionToRegExpConverter.java │ │ │ └── procedure │ │ │ └── internal │ │ │ └── NoSQLProcedureCallImpl.java │ └── resources │ │ └── META-INF │ │ └── services │ │ ├── javax.persistence.spi.PersistenceProvider │ │ ├── org.hibernate.boot.spi.MetadataBuilderInitializer │ │ ├── org.hibernate.boot.spi.SessionFactoryBuilderFactory │ │ ├── org.hibernate.integrator.spi.Integrator │ │ └── org.hibernate.service.spi.ServiceContributor │ └── test │ ├── java │ └── org │ │ └── hibernate │ │ └── ogm │ │ ├── backendtck │ │ ├── associations │ │ │ ├── collection │ │ │ │ ├── manytomany │ │ │ │ │ ├── AccountOwner.java │ │ │ │ │ ├── BankAccount.java │ │ │ │ │ ├── Car.java │ │ │ │ │ ├── ClassRoom.java │ │ │ │ │ ├── ManyToManyExtraTest.java │ │ │ │ │ ├── ManyToManyTest.java │ │ │ │ │ ├── Student.java │ │ │ │ │ └── Tire.java │ │ │ │ ├── types │ │ │ │ │ ├── Address.java │ │ │ │ │ ├── Child.java │ │ │ │ │ ├── Department.java │ │ │ │ │ ├── Enterprise.java │ │ │ │ │ ├── Father.java │ │ │ │ │ ├── GrandChild.java │ │ │ │ │ ├── GrandMother.java │ │ │ │ │ ├── ListTest.java │ │ │ │ │ ├── MapContentsStoredInSeparateDocumentTest.java │ │ │ │ │ ├── MapTest.java │ │ │ │ │ ├── PhoneNumber.java │ │ │ │ │ ├── Race.java │ │ │ │ │ ├── Runner.java │ │ │ │ │ └── User.java │ │ │ │ └── unidirectional │ │ │ │ │ ├── Cloud.java │ │ │ │ │ ├── CollectionUnidirectionalTest.java │ │ │ │ │ └── SnowFlake.java │ │ │ ├── compositeid │ │ │ │ ├── Director.java │ │ │ │ ├── ReferencedCompositeIdTest.java │ │ │ │ ├── Tournament.java │ │ │ │ └── TournamentId.java │ │ │ ├── manytoone │ │ │ │ ├── Basket.java │ │ │ │ ├── Beer.java │ │ │ │ ├── Brewery.java │ │ │ │ ├── CleanJoinColumnsAfterDeleteReferencedEntitiesTest.java │ │ │ │ ├── Court.java │ │ │ │ ├── Employee.java │ │ │ │ ├── Employer.java │ │ │ │ ├── Game.java │ │ │ │ ├── JUG.java │ │ │ │ ├── ManyToOneExtraTest.java │ │ │ │ ├── ManyToOneTest.java │ │ │ │ ├── Member.java │ │ │ │ ├── Product.java │ │ │ │ ├── SalesForce.java │ │ │ │ ├── SalesGuy.java │ │ │ │ └── SameRoleNameDifferentTablesTest.java │ │ │ ├── onetoone │ │ │ │ ├── Cavalier.java │ │ │ │ ├── Horse.java │ │ │ │ ├── Husband.java │ │ │ │ ├── MediaId.java │ │ │ │ ├── NetworkSwitch.java │ │ │ │ ├── OneToOneTest.java │ │ │ │ ├── PatchCable.java │ │ │ │ ├── Vehicle.java │ │ │ │ ├── Wheel.java │ │ │ │ └── Wife.java │ │ │ ├── order │ │ │ │ ├── Contributor.java │ │ │ │ ├── DuplicatesAndOrderOfAssociationItemsTest.java │ │ │ │ ├── Meeting.java │ │ │ │ ├── OpenSourceProject.java │ │ │ │ ├── OrderByQualifierTest.java │ │ │ │ └── Programmer.java │ │ │ ├── recursive │ │ │ │ ├── Coach.java │ │ │ │ ├── RecursiveAssociationsTest.java │ │ │ │ ├── TrainCoachesTest.java │ │ │ │ └── TreeNode.java │ │ │ └── storageconfiguration │ │ │ │ ├── AnnotatedCloud.java │ │ │ │ ├── AssociationStorageConfiguredProgrammaticallyTest.java │ │ │ │ ├── AssociationStorageConfiguredViaAnnotationsTest.java │ │ │ │ ├── AssociationStorageConfiguredViaPropertyTest.java │ │ │ │ ├── AssociationStorageTestBase.java │ │ │ │ ├── PolarCloud.java │ │ │ │ └── SnowFlakeProducer.java │ │ ├── batchfetching │ │ │ ├── BatchFetchingTest.java │ │ │ ├── Condominium.java │ │ │ ├── CondominiumBuilding.java │ │ │ ├── Floor.java │ │ │ ├── MultiGetEmbeddedIdTest.java │ │ │ ├── MultiGetMultiColumnsIdTest.java │ │ │ ├── MultiGetSingleColumnIdTest.java │ │ │ ├── Tower.java │ │ │ └── package-info.java │ │ ├── callbacks │ │ │ ├── Animal.java │ │ │ ├── Bus.java │ │ │ ├── PostLoadTest.java │ │ │ ├── PostPersistTest.java │ │ │ ├── PostPersistableBus.java │ │ │ ├── PostRemovableBus.java │ │ │ ├── PostRemoveTest.java │ │ │ ├── PostUpdatableBus.java │ │ │ ├── PostUpdateTest.java │ │ │ ├── PrePersistTest.java │ │ │ ├── PrePersistableBus.java │ │ │ ├── PreRemovableBus.java │ │ │ ├── PreRemoveTest.java │ │ │ ├── PreUpdatableBus.java │ │ │ ├── PreUpdateTest.java │ │ │ └── Zoo.java │ │ ├── cascade │ │ │ ├── CascadeEntityLoaderTest.java │ │ │ ├── Festival.java │ │ │ └── Party.java │ │ ├── compensation │ │ │ ├── CompensationSpiJpaTest.java │ │ │ ├── CompensationSpiTest.java │ │ │ ├── ContinuingErrorHandler.java │ │ │ ├── InvocationTrackingHandler.java │ │ │ └── Shipment.java │ │ ├── dialectinvocations │ │ │ ├── AbstractGridDialectOperationInvocationsTest.java │ │ │ ├── GridDialectOperationInvocationsForElementCollectionTest.java │ │ │ └── GridDialectOperationInvocationsForOneToOneTest.java │ │ ├── embeddable │ │ │ ├── Account.java │ │ │ ├── AccountWithPhone.java │ │ │ ├── Address.java │ │ │ ├── AddressType.java │ │ │ ├── ElementCollectionFromJPQLQueryTest.java │ │ │ ├── ElementCollectionFromJPQLQueryWithJPATest.java │ │ │ ├── ElementCollectionWithMapAndEmbeddedTest.java │ │ │ ├── EmbeddableExtraTest.java │ │ │ ├── EmbeddableTest.java │ │ │ ├── FoodsCosmeticsMedicines.java │ │ │ ├── ForumUser.java │ │ │ ├── JiraIssue.java │ │ │ ├── MultiAddressAccount.java │ │ │ ├── Order.java │ │ │ ├── PhoneNumber.java │ │ │ ├── QtyContents.java │ │ │ └── ShippingAddress.java │ │ ├── hibernatecore │ │ │ ├── Contact.java │ │ │ ├── HibernateCoreAPIWrappingTest.java │ │ │ └── JNDIReferenceTest.java │ │ ├── hsearch │ │ │ ├── HibernateSearchAtopOgmTest.java │ │ │ ├── Insurance.java │ │ │ └── SearchOnStandaloneOGMTest.java │ │ ├── id │ │ │ ├── Actor.java │ │ │ ├── Animal.java │ │ │ ├── AutoIdGeneratorTest.java │ │ │ ├── AutoIdGeneratorWithSessionTest.java │ │ │ ├── Composer.java │ │ │ ├── CompositeIdTest.java │ │ │ ├── DistributedRevisionControl.java │ │ │ ├── DuplicateIdDetectionTest.java │ │ │ ├── GuitarPlayer.java │ │ │ ├── IdentityIdGeneratorTest.java │ │ │ ├── Label.java │ │ │ ├── MakeUpArtistId.java │ │ │ ├── MakeupArtist.java │ │ │ ├── MakeupArtistWithCompositeKey.java │ │ │ ├── Music.java │ │ │ ├── News.java │ │ │ ├── NewsID.java │ │ │ ├── PianoPlayer.java │ │ │ ├── SequenceIdGeneratorTest.java │ │ │ ├── SequenceNextValueGenerationTest.java │ │ │ ├── Song.java │ │ │ ├── TableIdGeneratorInheritanceTest.java │ │ │ ├── TableIdGeneratorTest.java │ │ │ ├── TableNextValueGenerationTest.java │ │ │ ├── TableNextValueTableNameTest.java │ │ │ ├── TestNextValueGeneration.java │ │ │ ├── Video.java │ │ │ ├── embeddable │ │ │ │ ├── EmbeddableIdTest.java │ │ │ │ ├── SingleBoardComputer.java │ │ │ │ └── SingleBoardComputerPk.java │ │ │ ├── gen │ │ │ │ ├── CustomIdGenerator.java │ │ │ │ ├── CustomIdGeneratorEntity.java │ │ │ │ └── CustomIdGeneratorTest.java │ │ │ └── sharedpk │ │ │ │ ├── CoffeeMug.java │ │ │ │ ├── Lid.java │ │ │ │ └── SharedPrimaryKeyTest.java │ │ ├── inheritance │ │ │ ├── CommunityMember.java │ │ │ ├── Employee.java │ │ │ ├── HeroClub.java │ │ │ ├── JPAPolymorphicCollectionTest.java │ │ │ ├── JPAPolymorphicFindTest.java │ │ │ ├── JPATablePerClassFindTest.java │ │ │ ├── singletable │ │ │ │ ├── depositor │ │ │ │ │ ├── Account.java │ │ │ │ │ ├── AccountEntry.java │ │ │ │ │ ├── Address.java │ │ │ │ │ ├── ContactDetail.java │ │ │ │ │ ├── ContactType.java │ │ │ │ │ ├── CreditCondition.java │ │ │ │ │ ├── Depositor.java │ │ │ │ │ ├── GiroAccount.java │ │ │ │ │ ├── InstantAccessAccount.java │ │ │ │ │ └── PolymorphicAssociationTest.java │ │ │ │ └── family │ │ │ │ │ ├── Child.java │ │ │ │ │ ├── Family.java │ │ │ │ │ ├── Man.java │ │ │ │ │ ├── Person.java │ │ │ │ │ ├── SingleTableInheritancePersistTest.java │ │ │ │ │ └── Woman.java │ │ │ └── tableperclass │ │ │ │ ├── depositor │ │ │ │ ├── Account.java │ │ │ │ ├── AccountEntry.java │ │ │ │ ├── Address.java │ │ │ │ ├── ContactDetail.java │ │ │ │ ├── ContactType.java │ │ │ │ ├── CreditCondition.java │ │ │ │ ├── Depositor.java │ │ │ │ ├── GiroAccount.java │ │ │ │ ├── InstantAccessAccount.java │ │ │ │ └── PolymorphicAssociationTest.java │ │ │ │ └── family │ │ │ │ ├── Child.java │ │ │ │ ├── Family.java │ │ │ │ ├── Man.java │ │ │ │ ├── Person.java │ │ │ │ ├── TablePerClassInheritancePersistTest.java │ │ │ │ └── Woman.java │ │ ├── innertypes │ │ │ ├── CommunityMember.java │ │ │ └── InnerClassFindTest.java │ │ ├── jpa │ │ │ ├── InsertTest.java │ │ │ ├── JPAAPIWrappingTest.java │ │ │ ├── JPAConfigWithoutProviderTest.java │ │ │ ├── JPAJTATest.java │ │ │ ├── JPAResourceLocalTest.java │ │ │ ├── JPAStandaloneORMAndOGMTest.java │ │ │ └── Poem.java │ │ ├── loader │ │ │ ├── Feeling.java │ │ │ └── LoaderFromTupleTest.java │ │ ├── massindex │ │ │ ├── AssociationMassIndexerTest.java │ │ │ ├── SimpleEntityMassIndexingTest.java │ │ │ └── model │ │ │ │ ├── IndexedLabel.java │ │ │ │ ├── IndexedNews.java │ │ │ │ └── NewsIdFieldBridge.java │ │ ├── optimisticlocking │ │ │ ├── Galaxy.java │ │ │ ├── Nameable.java │ │ │ ├── OptimisticLockingExtraTest.java │ │ │ ├── OptimisticLockingTest.java │ │ │ ├── Planet.java │ │ │ ├── Pulsar.java │ │ │ └── Star.java │ │ ├── package-info.java │ │ ├── perf │ │ │ ├── Author.java │ │ │ ├── Blog.java │ │ │ ├── BlogEntry.java │ │ │ └── PerfTest.java │ │ ├── queries │ │ │ ├── Address.java │ │ │ ├── AggregateOperationQueryTest.java │ │ │ ├── Author.java │ │ │ ├── CompositeIdQueriesTest.java │ │ │ ├── CompositeIdWithColumnNameTest.java │ │ │ ├── Ending.java │ │ │ ├── Helicopter.java │ │ │ ├── Hypothesis.java │ │ │ ├── JpaQueriesTest.java │ │ │ ├── OptionalStoryBranch.java │ │ │ ├── QueriesWithAssociationsTest.java │ │ │ ├── QueriesWithEmbeddedCollectionTest.java │ │ │ ├── QueriesWithEmbeddedTest.java │ │ │ ├── QueriesWithToOnePropertyTest.java │ │ │ ├── QueryUpdateTest.java │ │ │ ├── SimpleQueriesTest.java │ │ │ ├── SimpleQueriesWithSingleTableInheritanceTest.java │ │ │ ├── SimpleQueriesWithTablePerClassInheritanceTest.java │ │ │ ├── SimpleQueriesWithTablePerClassNotSupportedTest.java │ │ │ ├── StoryBranch.java │ │ │ ├── StoryGame.java │ │ │ ├── pagination │ │ │ │ ├── PaginationUseCases.java │ │ │ │ ├── PaginationWithJPQLTest.java │ │ │ │ └── Poem.java │ │ │ ├── parameters │ │ │ │ ├── Genre.java │ │ │ │ ├── Movie.java │ │ │ │ └── QueryWithParametersTest.java │ │ │ └── projection │ │ │ │ ├── JPQLProjectionTest.java │ │ │ │ ├── Movie.java │ │ │ │ ├── NativeQueryProjectionBaseTest.java │ │ │ │ └── SingleMovieBaseTest.java │ │ ├── simpleentity │ │ │ ├── CRUDTest.java │ │ │ ├── Helicopter.java │ │ │ ├── Hero.java │ │ │ ├── Hypothesis.java │ │ │ ├── InheritanceTest.java │ │ │ ├── NullableFieldValueTest.java │ │ │ └── SuperHero.java │ │ ├── storedprocedures │ │ │ ├── Car.java │ │ │ ├── Motorbike.java │ │ │ ├── NamedParametersStoredProcedureCallTest.java │ │ │ └── PositionalParametersStoredProcedureCallTest.java │ │ └── type │ │ │ ├── Bookmark.java │ │ │ ├── BuiltInTypeTest.java │ │ │ ├── converter │ │ │ ├── JpaAttributeConverterTest.java │ │ │ ├── MyString.java │ │ │ ├── MyStringToUpperCaseStringConverter.java │ │ │ ├── OtherPrinter.java │ │ │ ├── Printer.java │ │ │ ├── StringToByteArrayConverter.java │ │ │ ├── StringToMyStringConverter.java │ │ │ └── StringToUpperCaseConverter.java │ │ │ ├── datetime │ │ │ ├── LocalDateEntity.java │ │ │ ├── LocalDateTest.java │ │ │ ├── LocalTimeEntity.java │ │ │ └── LocalTimeTest.java │ │ │ └── descriptor │ │ │ └── CalendarTimeZoneDateTimeTypeDescriptorTest.java │ │ ├── sessionfactory │ │ └── SessionFactoryBuilder.java │ │ ├── test │ │ ├── associations │ │ │ └── AssociationKeyMetadataEqualityTest.java │ │ ├── batch │ │ │ ├── BatchExecutionTest.java │ │ │ └── OperationsQueueTest.java │ │ ├── boot │ │ │ ├── GridDialectInitiatorTest.java │ │ │ ├── InvalidGridDialect.java │ │ │ ├── StandAloneNoOgmTest.java │ │ │ └── StandAloneOgmTest.java │ │ ├── cfg │ │ │ ├── DocumentStoreConfigurationTest.java │ │ │ ├── HostParserTest.java │ │ │ ├── LawnMower.java │ │ │ └── OgmConfigurationTest.java │ │ ├── criteria │ │ │ └── UnsupportedCriteriaForSessionTest.java │ │ ├── datastore │ │ │ ├── DatastoreProviderGeneratingSchema.java │ │ │ ├── DatastoreWithSchemaDefiner.java │ │ │ ├── Noise.java │ │ │ └── document │ │ │ │ └── EmbeddableStateFinderTest.java │ │ ├── descriptor │ │ │ ├── Iso8601CalendarTypeDescriptorTest.java │ │ │ ├── Iso8601DateTypeDescriptorTest.java │ │ │ ├── StringDateTypeDescriptorTest.java │ │ │ └── TimestampDateTypeDescriptorTest.java │ │ ├── dialectinvocations │ │ │ ├── GridDialectOperationInvocationsTest.java │ │ │ └── StockItem.java │ │ ├── inheritance │ │ │ └── OgmPersisterClassResolverTest.java │ │ ├── jpa │ │ │ ├── JPAStandaloneNoOGMTest.java │ │ │ └── Poem.java │ │ ├── model │ │ │ └── AssociationTest.java │ │ ├── options │ │ │ ├── OptionTest.java │ │ │ ├── OptionsContextImplTest.java │ │ │ ├── UniqueOptionTest.java │ │ │ ├── examples │ │ │ │ ├── EmbedExampleOption.java │ │ │ │ ├── ForceExampleOption.java │ │ │ │ ├── NameExampleOption.java │ │ │ │ ├── NamedQueryOption.java │ │ │ │ ├── PermissionOption.java │ │ │ │ └── annotations │ │ │ │ │ ├── EmbedExample.java │ │ │ │ │ └── NameExample.java │ │ │ └── mapping │ │ │ │ ├── AnnotationOptionValueSourceTest.java │ │ │ │ ├── JPAOptionIntegrationTest.java │ │ │ │ ├── OptionIntegrationTest.java │ │ │ │ ├── ProgrammaticOptionValueSourceTest.java │ │ │ │ └── model │ │ │ │ ├── Microwave.java │ │ │ │ ├── Refrigerator.java │ │ │ │ ├── SampleDatastoreProvider.java │ │ │ │ ├── SampleNoSqlDatastore.java │ │ │ │ ├── SampleOptionConfigurator.java │ │ │ │ └── SampleOptionModel.java │ │ ├── package-info.java │ │ ├── persister │ │ │ ├── AssociationKeyMetadataTest.java │ │ │ ├── BiDirectionalAssociationHelperTest.java │ │ │ ├── Eater.java │ │ │ ├── Muffin.java │ │ │ └── Pancake.java │ │ ├── storedprocedures │ │ │ ├── MockStoredProcedureDialect.java │ │ │ ├── NamedParametersStoredProcedureCallTest.java │ │ │ ├── PositionalParametersStoredProcedureCallTest.java │ │ │ ├── UnsupportedProceduresGridDialect.java │ │ │ └── UnsupportedStoredProcedureCallTest.java │ │ ├── testsupport │ │ │ ├── OgmTestCaseConfigureTest.java │ │ │ └── Poem.java │ │ ├── type │ │ │ ├── CustomDateType.java │ │ │ ├── ExplodingType.java │ │ │ ├── OverridingTypeDialect.java │ │ │ ├── Poem.java │ │ │ ├── StringMappedTypeSerialisationTest.java │ │ │ ├── TypeOverridingInDialectTest.java │ │ │ └── converter │ │ │ │ ├── JpaAttributeConverterGridTypeApplicationTest.java │ │ │ │ └── TriplingByteArrayGridType.java │ │ └── util │ │ │ ├── configurationreader │ │ │ └── impl │ │ │ │ └── ConfigurationPropertyReaderTest.java │ │ │ ├── impl │ │ │ ├── ContractsTest.java │ │ │ ├── ReflectionHelperTest.java │ │ │ └── TupleContextHelperTest.java │ │ │ └── parser │ │ │ └── impl │ │ │ └── LikeExpressionToRegExpConverterTest.java │ │ ├── util │ │ └── impl │ │ │ ├── ArrayHelperTest.java │ │ │ └── TupleExtractorTest.java │ │ └── utils │ │ ├── BaseGridDialectTestHelper.java │ │ ├── BytemanHelper.java │ │ ├── BytemanHelperStateCleanup.java │ │ ├── EmptyOptionsContext.java │ │ ├── FileHelper.java │ │ ├── GridDialectOperationContexts.java │ │ ├── GridDialectTestHelper.java │ │ ├── GridDialectTestHelperType.java │ │ ├── GridDialectType.java │ │ ├── HashMapTestHelper.java │ │ ├── IndexDirectoryManager.java │ │ ├── InvokedOperationsLoggingDialect.java │ │ ├── OgmAssertions.java │ │ ├── OgmSessionFactoryRule.java │ │ ├── OgmTestCase.java │ │ ├── OgmTestRunner.java │ │ ├── OrderedListAssert.java │ │ ├── PackagingRule.java │ │ ├── RequiresTransactionalCapabilitiesRule.java │ │ ├── SessionHelper.java │ │ ├── SkipByDatastoreProvider.java │ │ ├── SkipByGridDialect.java │ │ ├── SkippableTestRunner.java │ │ ├── TestEntities.java │ │ ├── TestEntityManagerFactory.java │ │ ├── TestEntityManagerFactoryConfiguration.java │ │ ├── TestForIssue.java │ │ ├── TestHelper.java │ │ ├── TestSessionFactory.java │ │ ├── TestSessionFactoryConfiguration.java │ │ ├── Throwables.java │ │ ├── jpa │ │ ├── GetterPersistenceUnitInfo.java │ │ ├── NoopDatasource.java │ │ ├── OgmJpaTestCase.java │ │ ├── OgmJpaTestRunner.java │ │ └── SingleJpaTestCase.java │ │ ├── package-info.java │ │ ├── parser │ │ └── MapBasedEntityNamesResolver.java │ │ └── test │ │ ├── EnvironmentTest.java │ │ ├── OrderedListAssertionsTest.java │ │ ├── SkipByDatastoreProviderClassLevelSelfTest.java │ │ ├── SkipByDatastoreProviderSelfJpaTest.java │ │ ├── SkipByDatastoreProviderSelfTest.java │ │ ├── SkipByGridDialectClassLevelSelfTest.java │ │ ├── SkipByGridDialectSelfJpaTest.java │ │ ├── SkipByGridDialectSelfTest.java │ │ └── package-info.java │ └── resources │ ├── configuration-test.properties │ ├── hibernate.properties │ ├── jbossts-properties.xml │ ├── log4j.properties │ └── persistencexml │ ├── customdialect.xml │ ├── datastoreobserver.xml │ ├── no-ogm.xml │ ├── ogm-noprovider.xml │ ├── ogm.xml │ ├── options.xml │ ├── orm-and-ogm.xml │ ├── transaction-type-jta.xml │ └── transaction-type-resource-local.xml ├── dco.txt ├── distribution ├── pom.xml └── src │ └── main │ └── assembly │ └── dist.xml ├── documentation ├── examples │ ├── gettingstarted │ │ ├── pom.xml │ │ └── src │ │ │ ├── main │ │ │ ├── java │ │ │ │ └── org │ │ │ │ │ └── hibernate │ │ │ │ │ └── ogm │ │ │ │ │ └── examples │ │ │ │ │ └── gettingstarted │ │ │ │ │ ├── DogBreedRunner.java │ │ │ │ │ └── domain │ │ │ │ │ ├── Breed.java │ │ │ │ │ └── Dog.java │ │ │ └── resources │ │ │ │ ├── META-INF │ │ │ │ └── persistence.xml │ │ │ │ ├── infinispan-dist.xml │ │ │ │ ├── infinispan-local.xml │ │ │ │ ├── jbossts-properties.xml │ │ │ │ ├── log4j.properties │ │ │ │ └── testing-flush-loopback.xml │ │ │ └── test │ │ │ └── java │ │ │ └── org │ │ │ └── hibernate │ │ │ └── ogm │ │ │ └── gettingstarted │ │ │ └── GettingstartedGuideBootsTest.java │ ├── pom.xml │ └── wildfly-quickstart │ │ ├── pom.xml │ │ └── wildfly-server-provisioning.xml ├── javadoc │ └── pom.xml ├── manual │ ├── .gitignore │ ├── pom.xml │ ├── readme.md │ └── src │ │ └── main │ │ ├── asciidoc │ │ ├── index.asciidoc │ │ └── modules │ │ │ ├── api.asciidoc │ │ │ ├── architecture.asciidoc │ │ │ ├── configuration.asciidoc │ │ │ ├── datastore-providers.asciidoc │ │ │ ├── getting-started.asciidoc │ │ │ ├── how-to-contribute.asciidoc │ │ │ ├── infinispan.asciidoc │ │ │ ├── mapping.asciidoc │ │ │ ├── migrating.asciidoc │ │ │ ├── mongodb.asciidoc │ │ │ ├── neo4j.asciidoc │ │ │ ├── preface.asciidoc │ │ │ ├── query.asciidoc │ │ │ └── submodules │ │ │ └── infinispan-storage-principles.asciidoc │ │ ├── omnigraffle │ │ ├── data-association.graffle │ │ ├── data-entity.graffle │ │ ├── ogm-architecture-with-hsearch.graffle │ │ └── ogm-architecture.graffle │ │ └── resources │ │ └── images │ │ ├── data-association-document.png │ │ ├── data-association.png │ │ ├── data-entity.png │ │ ├── hibernate_ogm_600px.png │ │ ├── neo4j-@Column-@Table-example.png │ │ ├── neo4j-@ElementCollection-@OrderColumn-example.png │ │ ├── neo4j-@ElementCollection-example.png │ │ ├── neo4j-@ElementCollection-map-example.png │ │ ├── neo4j-@Embedded-example.png │ │ ├── neo4j-@EmbeddedId-example.png │ │ ├── neo4j-bi-many-to-many-example.png │ │ ├── neo4j-bi-many-to-one-example.png │ │ ├── neo4j-bi-one-to-one-example.png │ │ ├── neo4j-bi-one-to-one-many-to-many-same-entity-example.png │ │ ├── neo4j-sequence-example.png │ │ ├── neo4j-single-node-example.png │ │ ├── neo4j-table-based-sequence-example.png │ │ ├── neo4j-uni-many-to-many-example.png │ │ ├── neo4j-uni-many-to-one-example.png │ │ ├── neo4j-uni-one-to-many-example.png │ │ ├── neo4j-uni-one-to-many-with-@MapKeyColumn-example.png │ │ ├── neo4j-uni-one-to-many-with-map-example.png │ │ ├── neo4j-uni-one-to-one-example.png │ │ ├── neo4j-unii-many-to-one-example.png │ │ ├── nosql.png │ │ ├── ogm-architecture-with-hsearch.png │ │ └── ogm-architecture.png └── pom.xml ├── featurepack ├── core │ ├── assembly.xml │ ├── pom.xml │ └── src │ │ └── main │ │ ├── alias │ │ └── ogm │ │ │ └── core │ │ │ └── module.xml │ │ ├── feature-pack-def │ │ └── feature-pack-template.xml │ │ └── modules │ │ ├── hql │ │ └── module.xml │ │ ├── ogm │ │ ├── core │ │ │ └── module.xml │ │ └── jipijapa │ │ │ └── module.xml │ │ └── org │ │ └── parboiled │ │ └── module.xml ├── infinispan-embedded │ ├── assembly.xml │ ├── pom.xml │ └── src │ │ └── main │ │ ├── alias │ │ └── ogm │ │ │ └── infinispan-embedded │ │ │ └── module.xml │ │ ├── feature-pack-def │ │ └── feature-pack-template.xml │ │ └── modules │ │ └── ogm │ │ └── infinispan-embedded │ │ └── module.xml ├── infinispan-remote │ ├── assembly.xml │ ├── pom.xml │ └── src │ │ └── main │ │ ├── alias │ │ └── ogm │ │ │ └── infinispan-remote │ │ │ └── module.xml │ │ ├── feature-pack-def │ │ └── feature-pack-template.xml │ │ └── modules │ │ └── ogm │ │ └── infinispan-remote │ │ └── module.xml ├── mongodb │ ├── assembly.xml │ ├── pom.xml │ └── src │ │ └── main │ │ ├── alias │ │ └── ogm │ │ │ └── mongodb │ │ │ └── module.xml │ │ ├── feature-pack-def │ │ └── feature-pack-template.xml │ │ └── modules │ │ └── ogm │ │ └── mongodb │ │ └── module.xml ├── neo4j │ ├── assembly.xml │ ├── pom.xml │ └── src │ │ └── main │ │ ├── alias │ │ └── ogm │ │ │ └── neo4j │ │ │ └── module.xml │ │ ├── feature-pack-def │ │ └── feature-pack-template.xml │ │ └── modules │ │ └── ogm │ │ ├── neo4j-internal │ │ └── module.xml │ │ └── neo4j │ │ └── module.xml └── pom.xml ├── how-to-release.md ├── infinispan-embedded ├── pom.xml └── src │ ├── main │ ├── java │ │ └── org │ │ │ └── hibernate │ │ │ └── ogm │ │ │ └── datastore │ │ │ └── infinispan │ │ │ ├── Infinispan.java │ │ │ ├── InfinispanDialect.java │ │ │ ├── InfinispanEmbedded.java │ │ │ ├── InfinispanProperties.java │ │ │ ├── configuration │ │ │ └── impl │ │ │ │ └── InfinispanConfiguration.java │ │ │ ├── dialect │ │ │ └── impl │ │ │ │ ├── InfinispanPessimisticWriteLockingStrategy.java │ │ │ │ └── InfinispanTupleSnapshot.java │ │ │ ├── impl │ │ │ ├── CacheInitializer.java │ │ │ ├── InfinispanEmbeddedDatastoreProvider.java │ │ │ ├── InfinispanEmbeddedStoredProceduresManager.java │ │ │ ├── InfinispanExtension.java │ │ │ └── TransactionManagerLookupDelegator.java │ │ │ ├── logging │ │ │ └── impl │ │ │ │ ├── Log.java │ │ │ │ └── LoggerFactory.java │ │ │ ├── options │ │ │ └── navigation │ │ │ │ ├── InfinispanEntityContext.java │ │ │ │ ├── InfinispanGlobalContext.java │ │ │ │ ├── InfinispanPropertyContext.java │ │ │ │ └── impl │ │ │ │ ├── InfinispanEntityContextImpl.java │ │ │ │ ├── InfinispanGlobalContextImpl.java │ │ │ │ └── InfinispanPropertyContextImpl.java │ │ │ └── persistencestrategy │ │ │ ├── common │ │ │ └── externalizer │ │ │ │ └── impl │ │ │ │ ├── ExternalizerIds.java │ │ │ │ ├── RowKeyExternalizer.java │ │ │ │ └── VersionChecker.java │ │ │ ├── counter │ │ │ ├── ClusteredCounterHandler.java │ │ │ ├── SequenceClusteredCounterHandler.java │ │ │ └── TableClusteredCounterHandler.java │ │ │ ├── impl │ │ │ ├── ExternalizersIntegration.java │ │ │ ├── InfinispanConfigurationParser.java │ │ │ ├── KeyProvider.java │ │ │ ├── LocalCacheManager.java │ │ │ └── PersistenceStrategy.java │ │ │ ├── kind │ │ │ ├── externalizer │ │ │ │ └── impl │ │ │ │ │ ├── AssociationKeyExternalizer.java │ │ │ │ │ ├── EntityKeyExternalizer.java │ │ │ │ │ ├── EntityKeyMetadataExternalizer.java │ │ │ │ │ └── IdSourceKeyExternalizer.java │ │ │ └── impl │ │ │ │ ├── CacheNames.java │ │ │ │ ├── OnePerKindCacheManager.java │ │ │ │ └── OnePerKindKeyProvider.java │ │ │ └── table │ │ │ ├── externalizer │ │ │ └── impl │ │ │ │ ├── PersistentAssociationKey.java │ │ │ │ ├── PersistentAssociationKeyExternalizer.java │ │ │ │ ├── PersistentEntityKey.java │ │ │ │ ├── PersistentEntityKeyExternalizer.java │ │ │ │ ├── PersistentIdSourceKey.java │ │ │ │ └── PersistentIdSourceKeyExternalizer.java │ │ │ └── impl │ │ │ ├── PerTableCacheManager.java │ │ │ └── PerTableKeyProvider.java │ └── resources │ │ ├── META-INF │ │ └── services │ │ │ └── org.infinispan.lifecycle.ModuleLifecycle │ │ └── org │ │ └── hibernate │ │ └── ogm │ │ └── datastore │ │ └── infinispan │ │ └── default-config.xml │ └── test │ ├── java │ └── org │ │ └── hibernate │ │ └── ogm │ │ └── datastore │ │ └── infinispan │ │ ├── test │ │ ├── cachemapping │ │ │ ├── CacheMappingTestBase.java │ │ │ ├── CachePerKindCacheMappingTest.java │ │ │ ├── CachePerKindConfiguredViaOptionCacheMappingTest.java │ │ │ ├── CachePerTableCacheMappingTest.java │ │ │ ├── Family.java │ │ │ ├── LocalDateTimeMappingTest.java │ │ │ └── Plant.java │ │ ├── dialect │ │ │ └── impl │ │ │ │ ├── AssociationKeyExternalizerTest.java │ │ │ │ ├── EntityKeyExternalizerTest.java │ │ │ │ ├── EntityKeyMetadataExternalizerTest.java │ │ │ │ ├── ExternalizerTestHelper.java │ │ │ │ ├── IdSourceKeyExternalizerTest.java │ │ │ │ ├── InfinispanDialectWithClusteredConfigurationTest.java │ │ │ │ ├── RowKeyExternalizerTest.java │ │ │ │ └── counter │ │ │ │ ├── GlobalConfigNotEnabledSequenceGenerationTest.java │ │ │ │ ├── GlobalConfigNotEnabledTableGenerationTest.java │ │ │ │ ├── StartAndCloseInfinispanEmbeddedFactoryBaseTest.java │ │ │ │ ├── TransportNotDefinedSequenceGenerationTest.java │ │ │ │ └── TransportNotDefinedTableGenerationTest.java │ │ ├── initialize │ │ │ ├── NonTransactionalCachesTest.java │ │ │ └── WrongConfigurationBootTest.java │ │ └── storedprocedures │ │ │ ├── ExceptionalProcedure.java │ │ │ ├── InfinispanNamedParametersStoredProcedureCallTest.java │ │ │ ├── InvalidStoredProcedure.java │ │ │ ├── ResultSetProcedure.java │ │ │ └── SimpleValueProcedure.java │ │ └── utils │ │ ├── InfinispanBackendTckHelper.java │ │ ├── InfinispanNode.java │ │ └── InfinispanTestHelper.java │ └── resources │ ├── hibernate.properties │ ├── infinispan-dist-alt-counter.xml │ ├── infinispan-dist-noglobal.xml │ ├── infinispan-dist.xml │ ├── infinispan-local.xml │ ├── log4j.properties │ └── testing-flush-loopback.xml ├── infinispan-remote ├── infinispan-server-provisioning.xml ├── infinispan-server-testconfig │ └── wildfly-trimmed-config.xml ├── pom.xml └── src │ ├── main │ └── java │ │ └── org │ │ └── hibernate │ │ └── ogm │ │ └── datastore │ │ └── infinispanremote │ │ ├── InfinispanRemoteDataStoreConfiguration.java │ │ ├── InfinispanRemoteDialect.java │ │ ├── InfinispanRemoteProperties.java │ │ ├── configuration │ │ └── impl │ │ │ ├── InfinispanRemoteConfiguration.java │ │ │ └── InfinispanRemoteValidators.java │ │ ├── impl │ │ ├── AssociationCacheOperation.java │ │ ├── CacheOperation.java │ │ ├── HotRodClientBuilder.java │ │ ├── InfinispanRemoteDatastoreProvider.java │ │ ├── InfinispanRemoteStoredProceduresManager.java │ │ ├── ProtoStreamMappingAdapter.java │ │ ├── ProtobufSchemaInitializer.java │ │ ├── ProtostreamAssociationMappingAdapter.java │ │ ├── VersionedAssociation.java │ │ ├── VersionedTuple.java │ │ ├── cachehandler │ │ │ ├── HotRodCacheCreationHandler.java │ │ │ ├── HotRodCacheHandler.java │ │ │ └── HotRodCacheValidationHandler.java │ │ ├── counter │ │ │ ├── CounterHandler.java │ │ │ └── HotRodSequenceCounterHandler.java │ │ ├── protobuf │ │ │ ├── BaseProtofieldAccessor.java │ │ │ ├── BigDecimalProtofieldAccessor.java │ │ │ ├── BigIntegerProtofieldAccessor.java │ │ │ ├── BooleanProtofieldAccessor.java │ │ │ ├── ByteProtofieldAccessor.java │ │ │ ├── CalendarDateProtofieldAccessor.java │ │ │ ├── CharacterProtofieldAccessor.java │ │ │ ├── CompositeProtobufCoDec.java │ │ │ ├── DateProtofieldAccessor.java │ │ │ ├── DoubleProtofieldAccessor.java │ │ │ ├── EnumProtofieldAccessor.java │ │ │ ├── FloatProtofieldAccessor.java │ │ │ ├── IntegerProtofieldAccessor.java │ │ │ ├── LocalDateProtofieldAccessor.java │ │ │ ├── LocalDateTimeProtofieldAccessor.java │ │ │ ├── LongProtofieldAccessor.java │ │ │ ├── NullableProtofieldEncoder.java │ │ │ ├── PrimitiveBytearrayProtofieldAccessor.java │ │ │ ├── ProtofieldAccessor.java │ │ │ ├── ProtofieldAccessorSet.java │ │ │ ├── ProtofieldDecoder.java │ │ │ ├── ProtofieldEncoder.java │ │ │ ├── ShortProtofieldAccessor.java │ │ │ ├── StringProtofieldAccessor.java │ │ │ ├── TimeProtofieldAccessor.java │ │ │ ├── TimestampProtofieldAccessor.java │ │ │ ├── TypeDeclarationsCollector.java │ │ │ ├── TypeDefinition.java │ │ │ ├── UUIDProtofieldAccessor.java │ │ │ ├── UnsafeProtofield.java │ │ │ ├── UrlProtofieldAccessor.java │ │ │ └── schema │ │ │ │ ├── SchemaDefinitions.java │ │ │ │ └── SchemaValidator.java │ │ ├── protostream │ │ │ ├── IdMessageMarshaller.java │ │ │ ├── MainOgmCoDec.java │ │ │ ├── OgmProtoStreamMarshaller.java │ │ │ ├── PayloadMessageMarshaller.java │ │ │ ├── ProtoDataMapper.java │ │ │ ├── ProtostreamAssociationPayload.java │ │ │ ├── ProtostreamId.java │ │ │ ├── ProtostreamMappedField.java │ │ │ ├── ProtostreamPayload.java │ │ │ ├── ProtostreamReadWriteable.java │ │ │ ├── ProtostreamSerializerSetup.java │ │ │ └── multimessage │ │ │ │ ├── MultiMessage.java │ │ │ │ └── MultiMessageExtension.java │ │ ├── schema │ │ │ ├── ProtobufEntryExporter.java │ │ │ ├── ProtobufFieldConsumer.java │ │ │ ├── ProtobufFieldExporter.java │ │ │ ├── ProtobufTypeConsumer.java │ │ │ ├── ProtobufTypeExporter.java │ │ │ ├── SanitationUtils.java │ │ │ ├── SequenceTableDefinition.java │ │ │ └── TableDefinition.java │ │ └── sequences │ │ │ ├── HotRodSequenceHandler.java │ │ │ ├── HotRodSequencer.java │ │ │ ├── SequenceId.java │ │ │ ├── SequenceIdMarshaller.java │ │ │ ├── SequencesCacheOperation.java │ │ │ └── SequencesPerCache.java │ │ ├── logging │ │ └── impl │ │ │ ├── Log.java │ │ │ ├── LoggerFactory.java │ │ │ └── StringSetFormatter.java │ │ ├── options │ │ ├── cache │ │ │ ├── CacheConfiguration.java │ │ │ └── impl │ │ │ │ ├── CacheConfigurationConverter.java │ │ │ │ └── CacheConfigurationOption.java │ │ └── navigation │ │ │ ├── InfinispanRemoteEntityContext.java │ │ │ ├── InfinispanRemoteGlobalContext.java │ │ │ ├── InfinispanRemotePropertyContext.java │ │ │ └── impl │ │ │ ├── InfinispanRemoteEntityContextImpl.java │ │ │ ├── InfinispanRemoteGlobalContextImpl.java │ │ │ └── InfinispanRemotePropertyContextImpl.java │ │ ├── query │ │ ├── impl │ │ │ ├── InfinispanRemoteQueryDescriptor.java │ │ │ ├── InfinispanRemoteQueryHandler.java │ │ │ ├── ProtostreamPayloadClosableIterator.java │ │ │ └── RawTypeClosableIterator.java │ │ └── parsing │ │ │ └── impl │ │ │ ├── InfinispanRemoteBasedQueryParserService.java │ │ │ ├── InfinispanRemoteNativeQueryParser.java │ │ │ ├── InfinispanRemotePredicateFactory.java │ │ │ ├── InfinispanRemoteProcessingChain.java │ │ │ ├── InfinispanRemotePropertyHelper.java │ │ │ ├── InfinispanRemoteQueryBuilder.java │ │ │ ├── InfinispanRemoteQueryParameter.java │ │ │ ├── InfinispanRemoteQueryParsingResult.java │ │ │ ├── InfinispanRemoteQueryRendererDelegate.java │ │ │ └── predicate │ │ │ └── impl │ │ │ ├── InfinispanRemoteComparisonPredicate.java │ │ │ ├── InfinispanRemoteConjunctionPredicate.java │ │ │ ├── InfinispanRemoteDisjunctionPredicate.java │ │ │ ├── InfinispanRemoteInPredicate.java │ │ │ ├── InfinispanRemoteIsNullPredicate.java │ │ │ ├── InfinispanRemoteLikePredicate.java │ │ │ ├── InfinispanRemoteNegationPredicate.java │ │ │ ├── InfinispanRemoteRangePredicate.java │ │ │ └── InfinispanRemoteRootPredicate.java │ │ └── schema │ │ └── spi │ │ ├── MapSchemaCapture.java │ │ ├── ProvidedSchemaOverride.java │ │ ├── SchemaCapture.java │ │ └── SchemaOverride.java │ └── test │ ├── java │ └── org │ │ └── hibernate │ │ └── ogm │ │ └── datastore │ │ └── infinispanremote │ │ ├── test │ │ ├── configuration │ │ │ ├── CacheConfigurationValidationTest.java │ │ │ ├── ExistCacheConfigurationEntity.java │ │ │ ├── NoAnnotationEntity.java │ │ │ └── NotExistCacheConfigurationEntity.java │ │ ├── initialize │ │ │ ├── CacheNotDefinedTest.java │ │ │ ├── DisneyCharacter.java │ │ │ ├── DisneyGrandChild.java │ │ │ ├── DisneyGrandMother.java │ │ │ ├── InfinispanRemoteConfigurationTest.java │ │ │ ├── InfinispanRemotePerformanceTest.java │ │ │ ├── MinimalHotRodConfigTest.java │ │ │ └── WrongConfigurationBootTest.java │ │ ├── mapping │ │ │ ├── ByteEntity.java │ │ │ ├── ByteMappingTest.java │ │ │ └── LocalDateTimeMappingTest.java │ │ ├── protobuf │ │ │ ├── EntityWithSequenceGenerator.java │ │ │ ├── EntityWithTableGenerator.java │ │ │ ├── ProtoBufSchemaTest.java │ │ │ ├── ProtoSchemaOverrideResourceTest.java │ │ │ └── SimpleEntity.java │ │ ├── query │ │ │ ├── nativequery │ │ │ │ ├── Employee.java │ │ │ │ ├── InfinispanRemoteEntityManagerNativeQueryTest.java │ │ │ │ ├── InfinispanRemoteNativeQueryParserTest.java │ │ │ │ ├── InfinispanRemotePaginationTest.java │ │ │ │ ├── InfinispanRemoteProjectionTest.java │ │ │ │ ├── InfinispanRemoteSessionNativeQueryTest.java │ │ │ │ ├── Project.java │ │ │ │ └── ProjectKey.java │ │ │ └── parsing │ │ │ │ ├── CommunityMemberST.java │ │ │ │ ├── EmployeeST.java │ │ │ │ ├── IndexedEntity.java │ │ │ │ ├── InfinispanRemoteJPQLParsingTest.java │ │ │ │ └── PersonST.java │ │ ├── storedprocedures │ │ │ ├── ExceptionalProcedure.java │ │ │ ├── InfinispanNamedParametersStoredProcedureCallTest.java │ │ │ ├── ResultSetProcedure.java │ │ │ ├── ServerTaskInfinispanNamedParametersStoredProcedureCallTest.java │ │ │ └── SimpleValueProcedure.java │ │ └── transaction │ │ │ └── InfinispanRemoteLockingTest.java │ │ └── utils │ │ ├── HotrodServerLifecycle.java │ │ ├── InfinispanRemoteBackendTckHelper.java │ │ ├── InfinispanRemoteJpaServerRunner.java │ │ ├── InfinispanRemoteServerRunner.java │ │ ├── InfinispanRemoteTestHelper.java │ │ ├── RemoteHotRodServerRule.java │ │ ├── StoredProceduresDeployer.java │ │ └── TransactionalRemoteCacheCounter.java │ └── resources │ ├── findInterrupt.btm │ ├── hibernate.properties │ ├── hotrodclient-alternative.properties │ ├── hotrodclient-minimal.properties │ ├── hotrodclient.properties │ ├── log4j.properties │ ├── protoschema-expectations │ ├── Cloud_SnowFlake.protobuf │ ├── Hero_SuperHero.protobuf │ ├── Hypothesis_Helicopter.protobuf │ ├── IllegalFormat.protobuf │ ├── allTypesGenerationTest.protobuf │ ├── sequenceTableGenerationTest.protobuf │ └── tableGenerationTest.protobuf │ ├── protoschema-userdefined │ ├── entities-id-generators-schema.proto │ ├── entity-schema.proto │ ├── entity-wrong-schema.proto │ ├── sequence-gen-schema.proto │ └── table-gen-schema.proto │ └── storedprocedures │ ├── exceptionalProcedure.js │ ├── resultSetProcedure.js │ └── simpleValueProcedure.js ├── infinispan ├── moved.txt └── pom.xml ├── integrationtest ├── infinispan-server-provisioning.xml ├── infinispan-server-testconfig │ └── wildfly-trimmed-config.xml ├── pom.xml ├── server-provisioning.xml ├── src │ └── test │ │ ├── java │ │ └── org │ │ │ └── hibernate │ │ │ └── ogm │ │ │ └── test │ │ │ └── integration │ │ │ ├── infinispanembedded │ │ │ ├── InfinispanModuleMemberRegistrationIT.java │ │ │ └── SearchIntegrationIT.java │ │ │ ├── infinispanremote │ │ │ ├── HotRodSearchIntegrationIT.java │ │ │ └── HotRodServerLifecycleManager.java │ │ │ ├── mongodb │ │ │ ├── MongoDBModuleMemberRegistrationIT.java │ │ │ ├── MongoDBModuleMemberRegistrationScenario.java │ │ │ ├── errorhandler │ │ │ │ └── TestErrorHandler.java │ │ │ ├── model │ │ │ │ ├── EmailAddress.java │ │ │ │ └── PhoneNumber.java │ │ │ ├── service │ │ │ │ ├── ContactManagementService.java │ │ │ │ └── PhoneNumberService.java │ │ │ └── wildflynosql │ │ │ │ └── MongoDBWildFlyNoSQLMemberRegistrationIT.java │ │ │ ├── neo4j │ │ │ ├── Neo4jModuleMemberRegistrationScenario.java │ │ │ ├── embedded │ │ │ │ ├── EmbeddedNeo4jJtaModuleMemberRegistrationIT.java │ │ │ │ └── EmbeddedNeo4jResourceLocalModuleMemberRegistrationIT.java │ │ │ └── remote │ │ │ │ ├── RemoteNeo4jEnvironmentVariables.java │ │ │ │ ├── bolt │ │ │ │ ├── BoltNeo4jJtaModuleMemberRegistrationIT.java │ │ │ │ └── BoltNeo4jResourceLocalModuleMemberRegistrationIT.java │ │ │ │ ├── controller │ │ │ │ ├── RemoteNeo4jJtaCleaner.java │ │ │ │ └── RemoteNeo4jResourceLocalCleaner.java │ │ │ │ └── http │ │ │ │ ├── HttpNeo4jJtaModuleMemberRegistrationIT.java │ │ │ │ └── HttpNeo4jResourceLocalModuleMemberRegistrationIT.java │ │ │ └── testcase │ │ │ ├── MagiccardsDatabaseScenario.java │ │ │ ├── ModuleMemberRegistrationScenario.java │ │ │ ├── controller │ │ │ ├── MagicCardsCollectionBean.java │ │ │ ├── MemberRegistration.java │ │ │ ├── MemberRegistrationWithJta.java │ │ │ ├── MemberRegistrationWithResourceLocal.java │ │ │ └── RegistrationExecutor.java │ │ │ ├── model │ │ │ ├── Address.java │ │ │ ├── MagicCard.java │ │ │ └── Member.java │ │ │ └── util │ │ │ ├── CassandraConfigurationHelper.java │ │ │ ├── JtaResources.java │ │ │ ├── ModuleMemberRegistrationDeployment.java │ │ │ └── ModulesHelper.java │ │ └── resources │ │ ├── META-INF │ │ └── services │ │ │ └── org.jboss.arquillian.core.spi.LoadableExtension │ │ ├── arquillian.xml │ │ ├── hotrod-client-testingconfiguration-offset100.properties │ │ ├── module-versions.properties │ │ └── neo4j-test.properties └── wildfly-server-testconfig │ └── standalone-nosql.xml ├── jipijapa ├── pom.xml └── src │ └── main │ ├── java │ └── org │ │ └── wildfly │ │ └── jpa │ │ └── hibernateogm5 │ │ └── HibernateOGMPersistenceProviderAdaptor.java │ └── resources │ └── META-INF │ └── services │ └── org.jipijapa.plugin.spi.PersistenceProviderAdaptor ├── license.txt ├── mongodb ├── pom.xml └── src │ ├── main │ ├── java │ │ └── org │ │ │ └── hibernate │ │ │ └── ogm │ │ │ └── datastore │ │ │ └── mongodb │ │ │ ├── MongoDB.java │ │ │ ├── MongoDBDialect.java │ │ │ ├── MongoDBProperties.java │ │ │ ├── binarystorage │ │ │ ├── GridFSFields.java │ │ │ └── GridFSStorageManager.java │ │ │ ├── configuration │ │ │ └── impl │ │ │ │ └── MongoDBConfiguration.java │ │ │ ├── dialect │ │ │ └── impl │ │ │ │ ├── AssociationStorageStrategy.java │ │ │ │ ├── MongoDBAssociationRowFactory.java │ │ │ │ ├── MongoDBAssociationSnapshot.java │ │ │ │ ├── MongoDBTupleSnapshot.java │ │ │ │ └── MongoHelpers.java │ │ │ ├── impl │ │ │ ├── MongoDBDatastoreProvider.java │ │ │ └── MongoDBSchemaDefiner.java │ │ │ ├── index │ │ │ └── impl │ │ │ │ ├── MongoDBIndexSpec.java │ │ │ │ └── MongoDBIndexType.java │ │ │ ├── logging │ │ │ └── impl │ │ │ │ ├── Log.java │ │ │ │ └── LoggerFactory.java │ │ │ ├── options │ │ │ ├── AssociationDocumentStorage.java │ │ │ ├── AssociationDocumentStorageType.java │ │ │ ├── AuthenticationMechanismType.java │ │ │ ├── GridFSBucket.java │ │ │ ├── ReadConcern.java │ │ │ ├── ReadConcernType.java │ │ │ ├── ReadPreference.java │ │ │ ├── ReadPreferenceType.java │ │ │ ├── WriteConcern.java │ │ │ ├── WriteConcernType.java │ │ │ ├── impl │ │ │ │ ├── AssociationDocumentStorageConverter.java │ │ │ │ ├── AssociationDocumentStorageOption.java │ │ │ │ ├── GridFSBucketConverter.java │ │ │ │ ├── GridFSBucketOption.java │ │ │ │ ├── ReadConcernConverter.java │ │ │ │ ├── ReadConcernOption.java │ │ │ │ ├── ReadPreferenceConverter.java │ │ │ │ ├── ReadPreferenceOption.java │ │ │ │ ├── WriteConcernConverter.java │ │ │ │ └── WriteConcernOption.java │ │ │ └── navigation │ │ │ │ ├── MongoDBEntityContext.java │ │ │ │ ├── MongoDBGlobalContext.java │ │ │ │ ├── MongoDBPropertyContext.java │ │ │ │ └── impl │ │ │ │ ├── MongoDBEntityContextImpl.java │ │ │ │ ├── MongoDBGlobalContextImpl.java │ │ │ │ └── MongoDBPropertyContextImpl.java │ │ │ ├── query │ │ │ ├── impl │ │ │ │ └── MongoDBQueryDescriptor.java │ │ │ └── parsing │ │ │ │ ├── impl │ │ │ │ ├── AggregationRenderer.java │ │ │ │ ├── MongoDBBasedQueryParserService.java │ │ │ │ ├── MongoDBHavingQueryBuilder.java │ │ │ │ ├── MongoDBPredicateFactory.java │ │ │ │ ├── MongoDBProcessingChain.java │ │ │ │ ├── MongoDBPropertyHelper.java │ │ │ │ ├── MongoDBQueryParsingResult.java │ │ │ │ └── MongoDBQueryRendererDelegate.java │ │ │ │ ├── nativequery │ │ │ │ └── impl │ │ │ │ │ ├── MongoDBQueryDescriptorBuilder.java │ │ │ │ │ ├── NativeQueryParseException.java │ │ │ │ │ └── NativeQueryParser.java │ │ │ │ └── predicate │ │ │ │ └── impl │ │ │ │ ├── MongoDBComparisonPredicate.java │ │ │ │ ├── MongoDBConjunctionPredicate.java │ │ │ │ ├── MongoDBDisjunctionPredicate.java │ │ │ │ ├── MongoDBInPredicate.java │ │ │ │ ├── MongoDBIsNullPredicate.java │ │ │ │ ├── MongoDBLikePredicate.java │ │ │ │ ├── MongoDBNegationPredicate.java │ │ │ │ ├── MongoDBRangePredicate.java │ │ │ │ └── MongoDBRootPredicate.java │ │ │ ├── type │ │ │ ├── AbstractGeoJsonObject.java │ │ │ ├── GeoCollection.java │ │ │ ├── GeoLineString.java │ │ │ ├── GeoMultiLineString.java │ │ │ ├── GeoMultiPoint.java │ │ │ ├── GeoMultiPolygon.java │ │ │ ├── GeoPoint.java │ │ │ ├── GeoPolygon.java │ │ │ ├── GridFS.java │ │ │ └── impl │ │ │ │ ├── AbstractGeoJsonObjectGridTypeDescriptor.java │ │ │ │ ├── AbstractGeoJsonObjectTypeDescriptor.java │ │ │ │ ├── BinaryAsBsonBinaryGridType.java │ │ │ │ ├── BinaryMappedGridTypeDescriptor.java │ │ │ │ ├── GeoCollectionGridType.java │ │ │ │ ├── GeoCollectionGridTypeDescriptor.java │ │ │ │ ├── GeoCollectionTypeDescriptor.java │ │ │ │ ├── GeoLineStringGridType.java │ │ │ │ ├── GeoLineStringGridTypeDescriptor.java │ │ │ │ ├── GeoLineStringTypeDescriptor.java │ │ │ │ ├── GeoMultiLineStringGridType.java │ │ │ │ ├── GeoMultiLineStringGridTypeDescriptor.java │ │ │ │ ├── GeoMultiLineStringTypeDescriptor.java │ │ │ │ ├── GeoMultiPointGridType.java │ │ │ │ ├── GeoMultiPointGridTypeDescriptor.java │ │ │ │ ├── GeoMultiPointTypeDescriptor.java │ │ │ │ ├── GeoMultiPolygonGridType.java │ │ │ │ ├── GeoMultiPolygonGridTypeDescriptor.java │ │ │ │ ├── GeoMultiPolygonTypeDescriptor.java │ │ │ │ ├── GeoPointGridType.java │ │ │ │ ├── GeoPointGridTypeDescriptor.java │ │ │ │ ├── GeoPointTypeDescriptor.java │ │ │ │ ├── GeoPolygonGridType.java │ │ │ │ ├── GeoPolygonGridTypeDescriptor.java │ │ │ │ ├── GeoPolygonTypeDescriptor.java │ │ │ │ ├── GridFSGridType.java │ │ │ │ ├── GridFSJavaTypeDescriptor.java │ │ │ │ ├── GridFSType.java │ │ │ │ ├── MongoDBTypeContributor.java │ │ │ │ ├── ObjectIdGridType.java │ │ │ │ ├── ObjectIdTypeDescriptor.java │ │ │ │ ├── SerializableAsBinaryGridType.java │ │ │ │ ├── StringAsObjectIdGridType.java │ │ │ │ ├── StringAsObjectIdType.java │ │ │ │ └── StringAsObjectIdTypeDescriptor.java │ │ │ └── utils │ │ │ └── DocumentUtil.java │ └── resources │ │ └── META-INF │ │ └── services │ │ └── org.hibernate.boot.model.TypeContributor │ └── test │ ├── java │ └── org │ │ └── hibernate │ │ └── ogm │ │ └── datastore │ │ └── mongodb │ │ ├── configuration │ │ └── impl │ │ │ └── MongoDBConfigurationTest.java │ │ ├── test │ │ ├── BatchInsertTest.java │ │ ├── associations │ │ │ ├── AssociationCompositeKeyMongoDBFormatTest.java │ │ │ ├── CollectionUnidirectionalCollectionTest.java │ │ │ ├── CollectionUnidirectionalGlobalTest.java │ │ │ ├── CollectionUnidirectionalInEntityTest.java │ │ │ ├── CompositeIdInEmbeddedTest.java │ │ │ ├── ListCollectionTest.java │ │ │ ├── ListGlobalTest.java │ │ │ ├── ManyToManyCollectionTest.java │ │ │ ├── ManyToManyCompositeKeyMongoDBFormatTest.java │ │ │ ├── ManyToManyGlobalTest.java │ │ │ ├── ManyToManyInEntityTest.java │ │ │ ├── ManyToOneCollectionTest.java │ │ │ ├── ManyToOneGlobalTest.java │ │ │ ├── ManyToOneInEntityTest.java │ │ │ ├── MapMappingTest.java │ │ │ ├── OneToOneCollectionMappingTest.java │ │ │ ├── OneToOneCollectionTest.java │ │ │ ├── OneToOneGlobalTest.java │ │ │ ├── OneToOneInEntityMappingTest.java │ │ │ ├── OneToOneInEntityTest.java │ │ │ ├── ordercolumn │ │ │ │ ├── Episode.java │ │ │ │ ├── OrderColumnMappingTest.java │ │ │ │ ├── TvShow.java │ │ │ │ └── Writer.java │ │ │ └── storageconfiguration │ │ │ │ ├── AnnotatedCloud.java │ │ │ │ ├── AssociationDocumentStorageConfiguredProgrammaticallyTest.java │ │ │ │ ├── AssociationDocumentStorageConfiguredViaAnnotationsTest.java │ │ │ │ ├── Cloud.java │ │ │ │ └── SnowFlake.java │ │ ├── datastore │ │ │ ├── CollectionNamingValidationTest.java │ │ │ ├── DatastoreInitializationTest.java │ │ │ ├── ReadPreferenceTest.java │ │ │ ├── WriteConcernTest.java │ │ │ └── lookup │ │ │ │ └── MongoDatabaseLookupTest.java │ │ ├── dialectinvocations │ │ │ ├── GridDialectOperationInvocationsTest.java │ │ │ ├── Product.java │ │ │ ├── StockItem.java │ │ │ └── Vendor.java │ │ ├── embeddable │ │ │ ├── ElementCollectionOrderWithJpaTest.java │ │ │ ├── ElementCollectionOrderWithSessionTest.java │ │ │ └── EmbeddableMappingTest.java │ │ ├── gridfs │ │ │ ├── GridFSTest.java │ │ │ └── Photo.java │ │ ├── id │ │ │ ├── TableGeneratorTest.java │ │ │ └── objectid │ │ │ │ ├── Bar.java │ │ │ │ ├── BarKeeper.java │ │ │ │ ├── Comedian.java │ │ │ │ ├── DoorMan.java │ │ │ │ ├── Drink.java │ │ │ │ ├── EntityWithObjectIdAndEmbeddable.java │ │ │ │ ├── Ingredient.java │ │ │ │ ├── MusicGenre.java │ │ │ │ ├── ObjectIdJpaTest.java │ │ │ │ ├── ObjectIdTest.java │ │ │ │ ├── ObjectIdWithEmbeddableTest.java │ │ │ │ ├── Singer.java │ │ │ │ └── Snack.java │ │ ├── index │ │ │ ├── MongoDBIndexOptionsConflictsTest.java │ │ │ ├── MongoDBIndexTest.java │ │ │ ├── OscarWildePoem.java │ │ │ ├── Poem.java │ │ │ ├── Restaurant.java │ │ │ ├── UniqueConstraintCanBeSkippedTest.java │ │ │ └── UniqueConstraintTest.java │ │ ├── inheritance │ │ │ ├── singletable │ │ │ │ ├── Node.java │ │ │ │ ├── NodeLink.java │ │ │ │ ├── SimpleNode.java │ │ │ │ ├── SingleTableInheritanceTest.java │ │ │ │ └── TextNode.java │ │ │ └── tableperclass │ │ │ │ ├── Node.java │ │ │ │ ├── NodeLink.java │ │ │ │ ├── SimpleNode.java │ │ │ │ ├── TablePerClassInheritanceTest.java │ │ │ │ └── TextNode.java │ │ ├── lifecycle │ │ │ ├── BarKeeper.java │ │ │ └── PersistOperationCollectorTest.java │ │ ├── loading │ │ │ ├── LoadSelectedColumnsCollectionTest.java │ │ │ ├── LoadSelectedColumnsGlobalTest.java │ │ │ ├── LoadSelectedColumnsInEntityTest.java │ │ │ ├── Module.java │ │ │ └── Project.java │ │ ├── mapping │ │ │ ├── BuiltinTypeMappingTest.java │ │ │ ├── ElementCollectionListWithIndexTest.java │ │ │ ├── ElementCollectionOfEmbeddableWithNamedColumnMappingTest.java │ │ │ ├── ElementCollectionWithMapAndEmbeddedTest.java │ │ │ ├── EmbeddableIdMappingTest.java │ │ │ ├── LocalDateTimeMappingTest.java │ │ │ └── associations │ │ │ │ ├── MultipleInverseAssociationOnTheSameEntityTest.java │ │ │ │ ├── Node.java │ │ │ │ ├── NodeLink.java │ │ │ │ └── SameRoleNameDifferentTablesMappingTest.java │ │ ├── options │ │ │ ├── associationstorage │ │ │ │ ├── AssociationStorageAnnotationTest.java │ │ │ │ └── AssociationStorageOptionTest.java │ │ │ ├── readconcern │ │ │ │ ├── GolfCourse.java │ │ │ │ ├── GolfPlayer.java │ │ │ │ ├── ReadConcernAnnotationTest.java │ │ │ │ ├── ReadConcernConfiguredProgrammaticallyTest.java │ │ │ │ └── ReadConcernPropagationTest.java │ │ │ ├── readpreference │ │ │ │ ├── GolfCourse.java │ │ │ │ ├── GolfPlayer.java │ │ │ │ ├── ReadPreferenceAnnotationTest.java │ │ │ │ ├── ReadPreferenceConfiguredProgrammaticallyTest.java │ │ │ │ └── ReadPreferencePropagationTest.java │ │ │ └── writeconcern │ │ │ │ ├── GolfCourse.java │ │ │ │ ├── GolfPlayer.java │ │ │ │ ├── WriteConcernAnnotationTest.java │ │ │ │ ├── WriteConcernOptionTest.java │ │ │ │ └── WriteConcernPropagationTest.java │ │ ├── performance │ │ │ └── MongoDBPerformanceTest.java │ │ ├── query │ │ │ ├── Hypothesis.java │ │ │ ├── MongoDBLikeQueryTest.java │ │ │ ├── MongoDBQueryDescriptorSerializationTest.java │ │ │ ├── nativequery │ │ │ │ ├── Critic.java │ │ │ │ ├── CriticId.java │ │ │ │ ├── LiteratureSociety.java │ │ │ │ ├── MarkTwainPoem.java │ │ │ │ ├── MongoDBEntityManagerNativeQueryTest.java │ │ │ │ ├── MongoDBPaginationWithAggregateTest.java │ │ │ │ ├── MongoDBPaginationWithFindTest.java │ │ │ │ ├── MongoDBProjectionTest.java │ │ │ │ ├── MongoDBSessionCLIDropDBQueryTest.java │ │ │ │ ├── MongoDBSessionCLIQueryTest.java │ │ │ │ ├── MongoDBSessionNativeQueryTest.java │ │ │ │ ├── OscarWildePoem.java │ │ │ │ └── Poet.java │ │ │ ├── parsing │ │ │ │ ├── MongoDBQueryParsingTest.java │ │ │ │ ├── model │ │ │ │ │ ├── IndexedEntity.java │ │ │ │ │ └── inheritance │ │ │ │ │ │ └── singletable │ │ │ │ │ │ ├── CommunityMemberST.java │ │ │ │ │ │ ├── EmployeeST.java │ │ │ │ │ │ └── PersonST.java │ │ │ │ └── nativequery │ │ │ │ │ └── NativeQueryParserTest.java │ │ │ └── storedprocedures │ │ │ │ └── MongoDBStoredProcedureCallExceptionsTest.java │ │ └── spatial │ │ │ ├── GeoObject.java │ │ │ ├── MongoDBGeoObjectTest.java │ │ │ ├── MongoDBSpatialQueryTest.java │ │ │ └── Restaurant.java │ │ └── utils │ │ ├── MapBasedEntityNamesResolver.java │ │ ├── MockMongoClientBuilder.java │ │ ├── MongoDBBackendTckHelper.java │ │ └── MongoDBTestHelper.java │ └── resources │ ├── hibernate.properties │ └── log4j.properties ├── mvnw ├── mvnw.cmd ├── neo4j ├── pom.xml └── src │ ├── main │ └── java │ │ └── org │ │ └── hibernate │ │ └── ogm │ │ └── datastore │ │ └── neo4j │ │ ├── BaseNeo4jDialect.java │ │ ├── BoltNeo4jDialect.java │ │ ├── EmbeddedNeo4jDialect.java │ │ ├── HttpNeo4jDialect.java │ │ ├── Neo4j.java │ │ ├── Neo4jDialect.java │ │ ├── Neo4jProperties.java │ │ ├── RemoteNeo4jDialect.java │ │ ├── dialect │ │ └── impl │ │ │ ├── BaseNeo4jAssociationQueries.java │ │ │ ├── BaseNeo4jEntityQueries.java │ │ │ ├── BaseNeo4jQueries.java │ │ │ ├── BaseNeo4jSequenceGenerator.java │ │ │ ├── BaseNeo4jTypeConverter.java │ │ │ ├── DiscriminatorAwareKeyMetadata.java │ │ │ ├── NodeLabel.java │ │ │ └── RemoteNeo4jSequenceGenerator.java │ │ ├── embedded │ │ ├── dialect │ │ │ └── impl │ │ │ │ ├── EmbeddedNeo4jAssociationQueries.java │ │ │ │ ├── EmbeddedNeo4jAssociationSnapshot.java │ │ │ │ ├── EmbeddedNeo4jBackendQueryResultIterator.java │ │ │ │ ├── EmbeddedNeo4jEntityQueries.java │ │ │ │ ├── EmbeddedNeo4jNodesTupleIterator.java │ │ │ │ ├── EmbeddedNeo4jSequenceGenerator.java │ │ │ │ ├── EmbeddedNeo4jTupleAssociationSnapshot.java │ │ │ │ ├── EmbeddedNeo4jTupleIterator.java │ │ │ │ ├── EmbeddedNeo4jTupleSnapshot.java │ │ │ │ └── EmbeddedNeo4jTypeConverter.java │ │ ├── impl │ │ │ ├── EmbeddedNeo4jDatastoreProvider.java │ │ │ ├── EmbeddedNeo4jGraphDatabaseFactory.java │ │ │ ├── EmbeddedNeo4jGraphDatabaseServiceFactoryProvider.java │ │ │ ├── EmbeddedNeo4jInternalProperties.java │ │ │ └── EmbeddedNeo4jSchemaDefiner.java │ │ └── transaction │ │ │ └── impl │ │ │ ├── EmbeddedNeo4jJtaTransactionCoordinator.java │ │ │ ├── EmbeddedNeo4jResourceLocalTransactionCoordinator.java │ │ │ └── EmbeddedNeo4jTransactionCoordinatorBuilder.java │ │ ├── impl │ │ └── BaseNeo4jSchemaDefiner.java │ │ ├── index │ │ └── impl │ │ │ └── Neo4jIndexSpec.java │ │ ├── logging │ │ └── impl │ │ │ ├── GraphLogger.java │ │ │ ├── Log.java │ │ │ └── LoggerFactory.java │ │ ├── query │ │ ├── impl │ │ │ ├── Neo4jParameterMetadataBuilder.java │ │ │ └── QueryParser.java │ │ └── parsing │ │ │ ├── cypherdsl │ │ │ └── impl │ │ │ │ └── CypherDSL.java │ │ │ └── impl │ │ │ ├── EmbeddedAliasTree.java │ │ │ ├── Neo4jAliasResolver.java │ │ │ ├── Neo4jBasedQueryParserService.java │ │ │ ├── Neo4jProcessingChain.java │ │ │ ├── Neo4jPropertyHelper.java │ │ │ ├── Neo4jQueryParameter.java │ │ │ ├── Neo4jQueryParsingResult.java │ │ │ ├── Neo4jQueryRendererDelegate.java │ │ │ ├── Neo4jQueryResolverDelegate.java │ │ │ ├── OrderByClause.java │ │ │ ├── PropertyIdentifier.java │ │ │ ├── RelationshipAliasTree.java │ │ │ └── predicate │ │ │ └── impl │ │ │ ├── Neo4jComparisonPredicate.java │ │ │ ├── Neo4jConjunctionPredicate.java │ │ │ ├── Neo4jDisjunctionPredicate.java │ │ │ ├── Neo4jInPredicate.java │ │ │ ├── Neo4jIsNullPredicate.java │ │ │ ├── Neo4jLikePredicate.java │ │ │ ├── Neo4jNegationPredicate.java │ │ │ ├── Neo4jPredicateFactory.java │ │ │ ├── Neo4jRangePredicate.java │ │ │ └── Neo4jRootPredicate.java │ │ ├── remote │ │ ├── bolt │ │ │ ├── dialect │ │ │ │ └── impl │ │ │ │ │ ├── BoltNeo4jAssociatedNodesHelper.java │ │ │ │ │ ├── BoltNeo4jAssociationQueries.java │ │ │ │ │ ├── BoltNeo4jEntityQueries.java │ │ │ │ │ ├── BoltNeo4jMapsTupleIterator.java │ │ │ │ │ ├── BoltNeo4jNodesTupleIterator.java │ │ │ │ │ ├── BoltNeo4jSequenceGenerator.java │ │ │ │ │ ├── BoltNeo4jTupleSnapshot.java │ │ │ │ │ ├── BoltNeo4jTypeConverter.java │ │ │ │ │ └── NodeWithEmbeddedNodes.java │ │ │ ├── impl │ │ │ │ ├── BoltNeo4jClient.java │ │ │ │ ├── BoltNeo4jDatastoreProvider.java │ │ │ │ └── BoltNeo4jSchemaDefiner.java │ │ │ └── transaction │ │ │ │ └── impl │ │ │ │ ├── BoltNeo4jJtaTransactionCoordinator.java │ │ │ │ ├── BoltNeo4jResourceLocalTransactionCoordinator.java │ │ │ │ └── BoltNeo4jTransactionCoordinatorBuilder.java │ │ ├── common │ │ │ ├── dialect │ │ │ │ └── impl │ │ │ │ │ ├── RemoteNeo4jAssociationPropertiesRow.java │ │ │ │ │ ├── RemoteNeo4jAssociationSnapshot.java │ │ │ │ │ ├── RemoteNeo4jMapsTupleIterator.java │ │ │ │ │ └── RemoteNeo4jTupleAssociationSnapshot.java │ │ │ ├── impl │ │ │ │ ├── RemoteNeo4jConfiguration.java │ │ │ │ ├── RemoteNeo4jDatabaseIdentifier.java │ │ │ │ └── RemoteNeo4jDatastoreProvider.java │ │ │ ├── request │ │ │ │ └── impl │ │ │ │ │ ├── RemoteStatement.java │ │ │ │ │ └── RemoteStatements.java │ │ │ └── util │ │ │ │ └── impl │ │ │ │ └── RemoteNeo4jHelper.java │ │ └── http │ │ │ ├── dialect │ │ │ └── impl │ │ │ │ ├── HttpNeo4jAssociatedNodesHelper.java │ │ │ │ ├── HttpNeo4jAssociationQueries.java │ │ │ │ ├── HttpNeo4jEntityQueries.java │ │ │ │ ├── HttpNeo4jMapsTupleIterator.java │ │ │ │ ├── HttpNeo4jNodesTupleIterator.java │ │ │ │ ├── HttpNeo4jSequenceGenerator.java │ │ │ │ ├── HttpNeo4jTupleSnapshot.java │ │ │ │ ├── HttpNeo4jTypeConverter.java │ │ │ │ └── NodeWithEmbeddedNodes.java │ │ │ ├── impl │ │ │ ├── HttpNeo4jClient.java │ │ │ ├── HttpNeo4jDatastoreProvider.java │ │ │ └── HttpNeo4jSchemaDefiner.java │ │ │ ├── json │ │ │ └── impl │ │ │ │ ├── ErrorResponse.java │ │ │ │ ├── Graph.java │ │ │ │ ├── Row.java │ │ │ │ ├── Statement.java │ │ │ │ ├── StatementResult.java │ │ │ │ ├── Statements.java │ │ │ │ └── StatementsResponse.java │ │ │ ├── request │ │ │ └── impl │ │ │ │ ├── HttpNeo4jAuthenticationFacade.java │ │ │ │ ├── HttpNeo4jTransactionFacade.java │ │ │ │ └── XStreamRequestHeaderFilter.java │ │ │ └── transaction │ │ │ └── impl │ │ │ ├── HttpNeo4jJtaTransactionCoordinator.java │ │ │ ├── HttpNeo4jResourceLocalTransactionCoordinator.java │ │ │ ├── HttpNeo4jTransaction.java │ │ │ └── HttpNeo4jTransactionCoordinatorBuilder.java │ │ ├── spi │ │ └── GraphDatabaseServiceFactory.java │ │ └── transaction │ │ └── impl │ │ ├── BaseNeo4jJtaTransactionCoordinator.java │ │ ├── Neo4jSynchronization.java │ │ └── RemoteTransactionDriver.java │ └── test │ ├── java │ └── org │ │ └── hibernate │ │ └── ogm │ │ └── datastore │ │ └── neo4j │ │ ├── test │ │ ├── EmbeddedGraphDatabaseFactoryTest.java │ │ ├── Neo4jGraphDatabaseServiceLoaderTest.java │ │ ├── dsl │ │ │ ├── GraphAssertions.java │ │ │ ├── NodeForGraphAssertions.java │ │ │ └── RelationshipsChainForGraphAssertions.java │ │ ├── embedded │ │ │ └── dialect │ │ │ │ └── EmbeddedNeo4jBackendQueryResultIteratorTest.java │ │ ├── index │ │ │ ├── CypherQueriesCreationForIndexesTest.java │ │ │ └── Neo4jIndexTest.java │ │ ├── mapping │ │ │ ├── BidirectionalManyToManyTest.java │ │ │ ├── BidirectionalManyToOneTest.java │ │ │ ├── BidirectionalOneToOneTest.java │ │ │ ├── CollectionOfEmbeddableTest.java │ │ │ ├── CompositeEmbeddedIdTest.java │ │ │ ├── ElementCollectionListWithIndexTest.java │ │ │ ├── ElementCollectionMappingTest.java │ │ │ ├── EmbeddableTest.java │ │ │ ├── EmbeddableWithCollectionMappingTest.java │ │ │ ├── LocalDateTimeMappingTest.java │ │ │ ├── MapTest.java │ │ │ ├── MapWithEmbeddedTest.java │ │ │ ├── MappedLink.java │ │ │ ├── MappedNode.java │ │ │ ├── MultipleInverseAssociationOnTheSameEntityTest.java │ │ │ ├── Neo4jJpaTestCase.java │ │ │ ├── ReferencedCompositeIdTest.java │ │ │ ├── SingleEntityTest.java │ │ │ ├── SingleEntityWithSequenceTest.java │ │ │ ├── SingleTableInheritancePersistTest.java │ │ │ ├── TablePerClassInheritancePersistTest.java │ │ │ ├── UnidirectionalManyToManyTest.java │ │ │ ├── UnidirectionalManyToOneTest.java │ │ │ ├── UnidirectionalManyToOneWithIndexTest.java │ │ │ ├── UniqueConstraintCanBeSkippedTest.java │ │ │ └── UniqueConstraintTest.java │ │ ├── procedures │ │ │ └── CarStoredProcedures.java │ │ ├── query │ │ │ ├── Neo4jEntityQueriesTest.java │ │ │ ├── nativequery │ │ │ │ ├── Critic.java │ │ │ │ ├── CriticId.java │ │ │ │ ├── Neo4jEntityManagerNativeQueryTest.java │ │ │ │ ├── Neo4jPaginationWithCypherTest.java │ │ │ │ ├── Neo4jParameterMetadataBuilderTest.java │ │ │ │ ├── Neo4jProjectionTest.java │ │ │ │ ├── Neo4jSessionNativeQueryTest.java │ │ │ │ └── OscarWildePoem.java │ │ │ └── parsing │ │ │ │ ├── CypherQueryParsingTest.java │ │ │ │ ├── Neo4jAliasResolverTest.java │ │ │ │ └── model │ │ │ │ ├── IndexedEntity.java │ │ │ │ └── inheritance │ │ │ │ ├── CommunityMemberST.java │ │ │ │ ├── EmployeeST.java │ │ │ │ └── PersonST.java │ │ ├── remote │ │ │ └── RemoteAuthenticationFailureTest.java │ │ ├── transaction │ │ │ ├── Game.java │ │ │ ├── JtaRollbackTest.java │ │ │ └── ResourceLocalRollbackTest.java │ │ └── util │ │ │ └── ExceptionHelper.java │ │ └── utils │ │ ├── BoltNeo4jTestHelperDelegate.java │ │ ├── EmbeddedNeo4jTestHelperDelegate.java │ │ ├── HttpNeo4jTestHelperDelegate.java │ │ ├── Neo4JBackendTckHelper.java │ │ ├── Neo4jTestHelper.java │ │ ├── Neo4jTestHelperDelegate.java │ │ ├── NotUniqueException.java │ │ └── PropertiesReader.java │ └── resources │ ├── hibernate.properties │ ├── log4j.properties │ ├── neo4j-embedded-test.properties │ └── neo4j.conf ├── performance ├── pom.xml └── src │ └── main │ ├── java │ └── org │ │ └── hibernate │ │ └── ogm │ │ └── perftest │ │ ├── Launcher.java │ │ ├── model │ │ ├── Author.java │ │ ├── AuthorWithSequence.java │ │ ├── FieldOfScience.java │ │ ├── ResearchPaper.java │ │ ├── Scientist.java │ │ └── ScientistWithSequence.java │ │ └── mongodb │ │ ├── nativeapi │ │ ├── NativeApiAssociationFindBenchmark.java │ │ ├── NativeApiAssociationInsertBenchmark.java │ │ ├── NativeApiBenchmarkBase.java │ │ ├── NativeApiFindBenchmark.java │ │ └── NativeApiInsertBenchmark.java │ │ └── ogm │ │ ├── EntityManagerFactoryHolder.java │ │ ├── HibernateOgmAssociationFindBenchmark.java │ │ ├── HibernateOgmAssociationInsertBenchmark.java │ │ ├── HibernateOgmCombinedBenchmark.java │ │ ├── HibernateOgmFindBenchmark.java │ │ └── HibernateOgmInsertBenchmark.java │ └── resources │ ├── META-INF │ └── persistence.xml │ └── native-settings.properties ├── pom.xml ├── settings-example.xml └── src ├── build-scripts └── dbmanager.sh └── main ├── build-config └── checkstyle.xml └── release-scripts ├── Gemfile ├── Gemfile.lock ├── create-tag.sh ├── deploy.sh ├── pre-release.rb ├── prepare-release.sh ├── push-upstream.sh ├── update-version.sh ├── upload-distribution.sh ├── upload-documentation.sh └── validate-release.sh /.gitattributes: -------------------------------------------------------------------------------- 1 | # Repository specific GIT options 2 | 3 | # Set default handling of line terminators for all non explicitly listed file types: 4 | * text=auto 5 | 6 | # Force LF as internal repository format for all following files; 7 | # this overrides user settings to enforce the *right format* : 8 | *.java text 9 | *.xml text 10 | *.txt text 11 | *.md text 12 | 13 | # Specify we want Java-friendly readable chunk headers for diff: 14 | 15 | *.java diff=java 16 | 17 | -------------------------------------------------------------------------------- /.github/PULL_REQUEST_TEMPLATE.md: -------------------------------------------------------------------------------- 1 | Please delete this text, and add a link to the Jira issue solved by this PR; 2 | see https://hibernate.atlassian.net/browse/OGM. 3 | 4 | Remember to prepend the title of this PR, as well as all commit messages, 5 | with the key of the Jira issue (`OGM-`). 6 | -------------------------------------------------------------------------------- /.github/hibernate-github-bot.yml: -------------------------------------------------------------------------------- 1 | --- 2 | jira: 3 | projectKey: "OGM" 4 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Our build scripts - necessary for our release jobs 2 | hibernate-noorm-release-scripts 3 | 4 | #OS 5 | .DS_Store 6 | 7 | #IDEs 8 | 9 | # IntelliJ specific files/directories 10 | .idea 11 | *.ipr 12 | *.iws 13 | *.iml 14 | atlassian-ide-plugin.xml 15 | 16 | #XMLEditor 17 | *.*xml~ 18 | 19 | # Eclipse specific files/directories 20 | .classpath 21 | .project 22 | .factorypath 23 | .settings 24 | .externalToolBuilders 25 | bin/ 26 | 27 | # NetBeans specific files/directories 28 | .nbattrs 29 | 30 | #build 31 | target/ 32 | work/ 33 | 34 | #test output 35 | test-output/ 36 | transaction.log 37 | infinispan.log 38 | 39 | # Infinispan embedded clustered counter generated file 40 | counters.xml 41 | -------------------------------------------------------------------------------- /.mvn/wrapper/maven-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/.mvn/wrapper/maven-wrapper.jar -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/OgmSession.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm; 8 | 9 | import org.hibernate.Session; 10 | 11 | /** 12 | * Session-level functionality specific to Hibernate OGM. 13 | * 14 | * @author Gunnar Morling 15 | */ 16 | public interface OgmSession extends Session { 17 | 18 | @Override 19 | OgmSessionFactory getSessionFactory(); 20 | } 21 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/boot/impl/OgmConfigurationServiceImpl.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.boot.impl; 8 | 9 | import org.hibernate.ogm.service.impl.OgmConfigurationService; 10 | 11 | public class OgmConfigurationServiceImpl implements OgmConfigurationService { 12 | 13 | private final boolean isEnabled; 14 | 15 | public OgmConfigurationServiceImpl(boolean isEnabled) { 16 | this.isEnabled = isEnabled; 17 | } 18 | 19 | @Override 20 | public boolean isOgmEnabled() { 21 | return isEnabled; 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/boot/impl/OgmSessionFactoryOptions.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.boot.impl; 8 | 9 | import org.hibernate.boot.spi.AbstractDelegatingSessionFactoryOptions; 10 | import org.hibernate.boot.spi.SessionFactoryOptions; 11 | 12 | public class OgmSessionFactoryOptions extends AbstractDelegatingSessionFactoryOptions { 13 | 14 | public OgmSessionFactoryOptions(SessionFactoryOptions delegate) { 15 | super( delegate ); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/cfg/OptionConfigurator.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.cfg; 8 | 9 | /** 10 | * A callback invoked at bootstrap time to apply configuration options. Can be passed via the option 11 | * {@link OgmProperties#OPTION_CONFIGURATOR}. 12 | * 13 | * @author Gunnar Morling 14 | */ 15 | public abstract class OptionConfigurator { 16 | 17 | /** 18 | * Callback for applying configuration options. 19 | * 20 | * @param configurable allows to apply store-specific configuration options 21 | */ 22 | public abstract void configure(Configurable configurable); 23 | } 24 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/compensation/BaseErrorHandler.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.compensation; 8 | 9 | /** 10 | * Default (no-op) implementation of {@link ErrorHandler}. 11 | * 12 | * @author Gunnar Morling 13 | */ 14 | public class BaseErrorHandler implements ErrorHandler { 15 | 16 | @Override 17 | public ErrorHandlingStrategy onFailedGridDialectOperation(FailedGridDialectOperationContext context) { 18 | // no-op 19 | 20 | return ErrorHandlingStrategy.ABORT; 21 | } 22 | 23 | @Override 24 | public void onRollback(RollbackContext context) { 25 | // no-op 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/compensation/operation/CreateAssociationWithKey.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.compensation.operation; 8 | 9 | import org.hibernate.ogm.dialect.spi.GridDialect; 10 | import org.hibernate.ogm.model.key.spi.AssociationKey; 11 | 12 | /** 13 | * Represents one execution of 14 | * {@link GridDialect#createAssociation(org.hibernate.ogm.model.key.spi.AssociationKey, org.hibernate.ogm.dialect.spi.AssociationContext)} 15 | * . 16 | * 17 | * @author Gunnar Morling 18 | */ 19 | public interface CreateAssociationWithKey extends GridDialectOperation { 20 | 21 | AssociationKey getAssociationKey(); 22 | } 23 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/compensation/operation/CreateTuple.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.compensation.operation; 8 | 9 | import org.hibernate.ogm.dialect.identity.spi.IdentityColumnAwareGridDialect; 10 | import org.hibernate.ogm.model.key.spi.EntityKeyMetadata; 11 | 12 | /** 13 | * Represents one execution of 14 | * {@link IdentityColumnAwareGridDialect#createTuple(EntityKeyMetadata, org.hibernate.ogm.dialect.spi.OperationContext)}. 15 | * 16 | * @author Gunnar Morling 17 | */ 18 | public interface CreateTuple extends GridDialectOperation { 19 | 20 | EntityKeyMetadata getEntityKeyMetadata(); 21 | } 22 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/compensation/operation/CreateTupleWithKey.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.compensation.operation; 8 | 9 | import org.hibernate.ogm.dialect.spi.GridDialect; 10 | import org.hibernate.ogm.model.key.spi.EntityKey; 11 | 12 | /** 13 | * Represents one execution of 14 | * {@link GridDialect#createTuple(EntityKey, org.hibernate.ogm.dialect.spi.OperationContext)}. 15 | * 16 | * @author Gunnar Morling 17 | */ 18 | public interface CreateTupleWithKey extends GridDialectOperation { 19 | 20 | EntityKey getEntityKey(); 21 | } 22 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/compensation/operation/ExecuteBatch.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.compensation.operation; 8 | 9 | import java.util.List; 10 | 11 | import org.hibernate.ogm.dialect.batch.spi.BatchableGridDialect; 12 | 13 | /** 14 | * Represents one execution of 15 | * {@link BatchableGridDialect#executeBatch(org.hibernate.ogm.dialect.batch.spi.OperationsQueue)}. 16 | * 17 | * @author Gunnar Morling 18 | * 19 | */ 20 | public interface ExecuteBatch extends GridDialectOperation { 21 | 22 | /** 23 | * Returns the list of batched operations. 24 | */ 25 | List getOperations(); 26 | } 27 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/compensation/operation/FlushPendingOperations.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.compensation.operation; 8 | 9 | import java.util.List; 10 | 11 | import org.hibernate.ogm.dialect.batch.spi.GroupingByEntityDialect; 12 | 13 | /** 14 | * Represents one execution of 15 | * {@link GroupingByEntityDialect#flushPendingOperations(org.hibernate.ogm.model.key.spi.EntityKey, org.hibernate.ogm.dialect.spi.TupleContext)}. 16 | * 17 | * @author Guillaume Smet 18 | * 19 | */ 20 | public interface FlushPendingOperations extends GridDialectOperation { 21 | 22 | /** 23 | * Returns the list of batched operations. 24 | */ 25 | List getOperations(); 26 | } 27 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/compensation/operation/InsertOrUpdateAssociation.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.compensation.operation; 8 | 9 | import org.hibernate.ogm.dialect.spi.GridDialect; 10 | import org.hibernate.ogm.model.key.spi.AssociationKey; 11 | import org.hibernate.ogm.model.spi.Association; 12 | 13 | /** 14 | * Represents one execution of 15 | * {@link GridDialect#insertOrUpdateAssociation(AssociationKey, Association, org.hibernate.ogm.dialect.spi.AssociationContext)}. 16 | * 17 | * @author Gunnar Morling 18 | */ 19 | public interface InsertOrUpdateAssociation extends GridDialectOperation { 20 | 21 | AssociationKey getAssociationKey(); 22 | 23 | Association getAssociation(); 24 | } 25 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/compensation/operation/InsertOrUpdateTuple.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.compensation.operation; 8 | 9 | import org.hibernate.ogm.dialect.spi.GridDialect; 10 | import org.hibernate.ogm.model.key.spi.EntityKey; 11 | import org.hibernate.ogm.model.spi.Tuple; 12 | 13 | /** 14 | * Represents one execution of 15 | * {@link GridDialect#insertOrUpdateTuple(EntityKey, TuplePointer, org.hibernate.ogm.dialect.spi.TupleContext)}. 16 | * 17 | * @author Gunnar Morling 18 | */ 19 | public interface InsertOrUpdateTuple extends GridDialectOperation { 20 | 21 | EntityKey getEntityKey(); 22 | 23 | Tuple getTuple(); 24 | } 25 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/compensation/operation/InsertTuple.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.compensation.operation; 8 | 9 | import org.hibernate.ogm.dialect.identity.spi.IdentityColumnAwareGridDialect; 10 | import org.hibernate.ogm.model.key.spi.EntityKeyMetadata; 11 | import org.hibernate.ogm.model.spi.Tuple; 12 | 13 | /** 14 | * Represents one execution of 15 | * {@link IdentityColumnAwareGridDialect#insertTuple(EntityKeyMetadata, Tuple, org.hibernate.ogm.dialect.spi.TupleContext)}. 16 | * 17 | * @author Gunnar Morling 18 | */ 19 | public interface InsertTuple extends GridDialectOperation { 20 | 21 | EntityKeyMetadata getEntityKeyMetadata(); 22 | 23 | Tuple getTuple(); 24 | } 25 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/compensation/operation/OperationType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.compensation.operation; 8 | 9 | /** 10 | * The type of a {@link GridDialectOperation}. 11 | * 12 | * @author Gunnar Morling 13 | */ 14 | public enum OperationType { 15 | 16 | // GridDialect 17 | CREATE_TUPLE_WITH_KEY, 18 | INSERT_OR_UPDATE_TUPLE, 19 | REMOVE_TUPLE, 20 | CREATE_ASSOCIATION_WITH_KEY, 21 | INSERT_OR_UPDATE_ASSOCIATION, 22 | REMOVE_ASSOCIATION, 23 | EXECUTE_BATCH, 24 | FLUSH_PENDING_OPERATIONS, 25 | 26 | // IdentityColumnAwareGridDialect 27 | 28 | CREATE_TUPLE, 29 | INSERT_TUPLE, 30 | 31 | // OptimisticLockingAwareGridDialect 32 | UPDATE_TUPLE_WITH_OPTIMISTIC_LOCK, 33 | REMOVE_TUPLE_WITH_OPTIMISTIC_LOCK; 34 | } 35 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/compensation/operation/RemoveAssociation.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.compensation.operation; 8 | 9 | import org.hibernate.ogm.dialect.spi.GridDialect; 10 | import org.hibernate.ogm.model.key.spi.AssociationKey; 11 | 12 | /** 13 | * Represents one execution of 14 | * {@link GridDialect#removeAssociation(AssociationKey, org.hibernate.ogm.dialect.spi.AssociationContext)}. 15 | * 16 | * @author Gunnar Morling 17 | */ 18 | // TODO OGM-777 Expose previous state? 19 | public interface RemoveAssociation extends GridDialectOperation { 20 | 21 | AssociationKey getAssociationKey(); 22 | } 23 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/compensation/operation/RemoveTuple.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.compensation.operation; 8 | 9 | import org.hibernate.ogm.dialect.spi.GridDialect; 10 | import org.hibernate.ogm.model.key.spi.EntityKey; 11 | 12 | /** 13 | * Represents one execution of 14 | * {@link GridDialect#removeTuple(EntityKey, org.hibernate.ogm.dialect.spi.TupleContext)}. 15 | * 16 | * @author Gunnar Morling 17 | */ 18 | // TODO OGM-777 Expose previous state? 19 | public interface RemoveTuple extends GridDialectOperation { 20 | 21 | EntityKey getEntityKey(); 22 | } 23 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/compensation/operation/RemoveTupleWithOptimisticLock.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.compensation.operation; 8 | 9 | import org.hibernate.ogm.dialect.optimisticlock.spi.OptimisticLockingAwareGridDialect; 10 | import org.hibernate.ogm.model.key.spi.EntityKey; 11 | import org.hibernate.ogm.model.spi.Tuple; 12 | 13 | /** 14 | * Represents one execution of 15 | * {@link OptimisticLockingAwareGridDialect#removeTupleWithOptimisticLock(EntityKey, Tuple, org.hibernate.ogm.dialect.spi.TupleContext)} 16 | * 17 | * @author Gunnar Morling 18 | */ 19 | public interface RemoveTupleWithOptimisticLock extends GridDialectOperation { 20 | 21 | EntityKey getEntityKey(); 22 | 23 | Tuple getOldLockState(); 24 | } 25 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/datastore/document/association/spi/package-info.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | /** 8 | * Helper contracts used to store and extract associations rows and offer an optimized representation 9 | * for collection of single types and associations pointing to non composite pk 10 | * and not involving indexed or keyed collections. 11 | *

12 | * These helper classes are particularly useful for JSON or JSON-like structures. 13 | * 14 | * @author Emmanuel Bernard <emmanuel@hibernate.org> 15 | */ 16 | package org.hibernate.ogm.datastore.document.association.spi; 17 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/datastore/document/options/AssociationStorageType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.document.options; 8 | 9 | /** 10 | * A strategy for storing association information in a document datastore. 11 | * 12 | * @author Gunnar Morling 13 | */ 14 | public enum AssociationStorageType { 15 | 16 | /** 17 | * Stores association information in a dedicated document per association. 18 | */ 19 | ASSOCIATION_DOCUMENT, 20 | 21 | /** 22 | * Store association information within the entity. 23 | */ 24 | IN_ENTITY 25 | } 26 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/datastore/keyvalue/options/CacheMappingType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.keyvalue.options; 8 | 9 | /** 10 | * A strategy for persisting data into key/value stores. 11 | * 12 | * @author Gunnar Morling 13 | */ 14 | public enum CacheMappingType { 15 | 16 | /** 17 | * Three caches will be used: one cache for all entities, one cache for all associations and one cache for all id 18 | * sources. 19 | */ 20 | CACHE_PER_KIND, 21 | 22 | /** 23 | * A dedicated cache will be used for each entity type, association type and id source table. 24 | */ 25 | CACHE_PER_TABLE; 26 | } 27 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/datastore/keyvalue/options/navigation/KeyValueStoreEntityContext.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.keyvalue.options.navigation; 8 | 9 | import org.hibernate.ogm.options.navigation.EntityContext; 10 | 11 | /** 12 | * Allows to configure key/value store options applying on a per-entity level. These options can be overridden for 13 | * single properties. 14 | * 15 | * @author Gunnar Morling 16 | */ 17 | public interface KeyValueStoreEntityContext, P extends KeyValueStorePropertyContext> extends 18 | EntityContext { 19 | } 20 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/datastore/keyvalue/options/navigation/KeyValueStorePropertyContext.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.keyvalue.options.navigation; 8 | 9 | import org.hibernate.ogm.options.navigation.PropertyContext; 10 | 11 | /** 12 | * Allows to configure key/value store options applying on a per-association level. 13 | * 14 | * @author Gunnar Morling 15 | */ 16 | public interface KeyValueStorePropertyContext, P extends KeyValueStorePropertyContext> extends 17 | PropertyContext { 18 | } 19 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/datastore/spi/BaseSchemaDefiner.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.spi; 8 | 9 | 10 | /** 11 | * Default implementation of {@link SchemaDefiner}. Specific implementations can override those hooks they're 12 | * interested in. Also provides utility methods useful for implementors. 13 | * 14 | * @author Gunnar Morling 15 | */ 16 | public class BaseSchemaDefiner implements SchemaDefiner { 17 | 18 | @Override 19 | public void validateMapping(SchemaDefinitionContext context) { 20 | // No-op 21 | } 22 | 23 | @Override 24 | public void initializeSchema(SchemaDefinitionContext context) { 25 | // No-op 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/dialect/batch/spi/GroupableEntityOperation.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.dialect.batch.spi; 8 | 9 | import org.hibernate.ogm.model.key.spi.EntityKey; 10 | 11 | /** 12 | * Represents an {@link Operation} we can group by entity 13 | * 14 | * @author Guillaume Smet 15 | */ 16 | public interface GroupableEntityOperation extends Operation { 17 | 18 | EntityKey getEntityKey(); 19 | 20 | } 21 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/dialect/batch/spi/Operation.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.dialect.batch.spi; 8 | 9 | /** 10 | * Represents a CRUD operation on the datastore 11 | * 12 | * @author Guillaume Scheibel <guillaume.scheibel@gmail.com> 13 | */ 14 | public interface Operation { 15 | } 16 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/dialect/impl/IdentifiableDriver.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.dialect.impl; 8 | 9 | import org.hibernate.resource.transaction.spi.TransactionCoordinator.TransactionDriver; 10 | 11 | /** 12 | * A {@link TransactionDriver} that can return an identifier for the underlying transaction. 13 | * 14 | * @author Davide D'Alto 15 | */ 16 | public interface IdentifiableDriver extends TransactionDriver { 17 | 18 | Object getTransactionId(); 19 | } 20 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/dialect/impl/TransactionContextImpl.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.dialect.impl; 8 | 9 | import org.hibernate.ogm.dialect.spi.TransactionContext; 10 | 11 | /** 12 | * Default implementation of the {@link TransactionContext}. 13 | * 14 | * @author Davide D'Alto 15 | */ 16 | public class TransactionContextImpl implements TransactionContext { 17 | 18 | private final Object transactionId; 19 | 20 | public TransactionContextImpl(IdentifiableDriver driver) { 21 | this.transactionId = driver.getTransactionId(); 22 | } 23 | 24 | @Override 25 | public Object getTransactionId() { 26 | return transactionId; 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/dialect/query/spi/ClosableIterator.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.dialect.query.spi; 8 | 9 | import java.io.Closeable; 10 | import java.util.Iterator; 11 | 12 | /** 13 | * An iterator that has to be closed. 14 | * 15 | * @author Davide D'Alto <davide@hibernate.org> 16 | */ 17 | public interface ClosableIterator extends Iterator, Closeable { 18 | 19 | @Override 20 | void close(); 21 | 22 | } 23 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/dialect/spi/ModelConsumer.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.dialect.spi; 8 | 9 | import org.hibernate.ogm.model.spi.Tuple; 10 | 11 | /** 12 | * Represents an object that can consume a model element (only {@link Tuple}s atm.). 13 | * 14 | * @author Davide D'Alto <davide@hibernate.org> 15 | */ 16 | public interface ModelConsumer { 17 | 18 | /** 19 | * Consume a model element on all the tuples provided by a {@link TuplesSupplier}. 20 | * 21 | * @param supplier provides the tuples the model will consume 22 | */ 23 | void consume(TuplesSupplier supplier); 24 | } 25 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/dialect/spi/TransactionContext.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.dialect.spi; 8 | 9 | /** 10 | * Contains information about the running transaction. 11 | * 12 | * @author Davide D'Alto 13 | */ 14 | public interface TransactionContext { 15 | 16 | /** 17 | * A value that can be used to identify the running transaction. 18 | * 19 | * @return the transaction identifier 20 | */ 21 | Object getTransactionId(); 22 | } 23 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/dialect/spi/TupleContext.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.dialect.spi; 8 | 9 | /** 10 | * Represents all information used to load an entity with some specific characteristics like a projection 11 | * 12 | * @author Guillaume Scheibel <guillaume.scheibel@gmail.com> 13 | * @author Gunnar Morling 14 | */ 15 | public interface TupleContext extends OperationContext { 16 | 17 | } 18 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/dialect/spi/TuplesSupplier.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.dialect.spi; 8 | 9 | import org.hibernate.ogm.dialect.query.spi.ClosableIterator; 10 | import org.hibernate.ogm.model.spi.Tuple; 11 | 12 | /** 13 | * Supplies {@link Tuple}s. 14 | * 15 | * @author Davide D'Alto 16 | */ 17 | public interface TuplesSupplier { 18 | 19 | /** 20 | * @param transactionContext the current {@link TransactionContext}, can be {@code null} 21 | * @return a closable iterator to scan the tuples 22 | */ 23 | ClosableIterator get( TransactionContext transactionContext ); 24 | } 25 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/engine/spi/OgmSessionBuilderImplementor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.engine.spi; 8 | 9 | import org.hibernate.engine.spi.SessionBuilderImplementor; 10 | import org.hibernate.ogm.OgmSessionFactory.OgmSessionBuilder; 11 | 12 | /** 13 | * OGM-specific extensions to {@link SessionBuilderImplementor}. 14 | * 15 | * @author Gunnar Morling 16 | */ 17 | public interface OgmSessionBuilderImplementor extends OgmSessionBuilder, SessionBuilderImplementor { 18 | } 19 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/engine/spi/OgmSessionFactoryImplementor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.engine.spi; 8 | 9 | import org.hibernate.HibernateException; 10 | import org.hibernate.engine.spi.SessionFactoryImplementor; 11 | import org.hibernate.ogm.OgmSession; 12 | import org.hibernate.ogm.OgmSessionFactory; 13 | 14 | /** 15 | * OGM-specific extensions to {@link SessionFactoryImplementor}. 16 | * 17 | * @author Gunnar Morling 18 | */ 19 | public interface OgmSessionFactoryImplementor extends OgmSessionFactory, SessionFactoryImplementor { 20 | 21 | @Override 22 | OgmSessionBuilderImplementor withOptions(); 23 | 24 | @Override 25 | OgmSession openTemporarySession() throws HibernateException; 26 | } 27 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/exception/EntityAlreadyExistsException.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.exception; 8 | 9 | import org.hibernate.HibernateException; 10 | 11 | /** 12 | * Indicates that the insertion of an entity failed as another entity with the same id already exists in the datastore. 13 | * 14 | * @author Gunnar Morling 15 | */ 16 | public class EntityAlreadyExistsException extends HibernateException { 17 | 18 | public EntityAlreadyExistsException(String message) { 19 | super( message ); 20 | } 21 | 22 | public EntityAlreadyExistsException(Throwable cause) { 23 | super( cause ); 24 | } 25 | 26 | public EntityAlreadyExistsException(String message, Throwable cause) { 27 | super( message, cause ); 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/exception/NotSupportedException.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.exception; 8 | 9 | /** 10 | * Thrown when an operation is not supported by OGM 11 | * @author Emmanuel Bernard 12 | */ 13 | public class NotSupportedException extends RuntimeException { 14 | public NotSupportedException(String jira, String message) { 15 | super( jira + " - " + message ); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/exception/impl/Exceptions.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.exception.impl; 8 | 9 | /** 10 | * Utility functions for dealing with exceptions. 11 | * 12 | * @author Gunnar Morling 13 | */ 14 | public class Exceptions { 15 | 16 | private Exceptions() { 17 | } 18 | 19 | /** 20 | * Throws the given exception. Allows to re-throw checked exceptions also if they are not declared, exploiting type 21 | * erasure by the compiler. 22 | */ 23 | @SuppressWarnings("unchecked") 24 | public static void sneakyThrow(Exception e) throws E { 25 | throw (E) e; 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/massindex/impl/SessionAwareRunnable.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.massindex.impl; 8 | 9 | import org.hibernate.Session; 10 | import org.hibernate.ogm.model.spi.Tuple; 11 | 12 | /** 13 | * @author Davide D'Alto <davide@hibernate.org> 14 | */ 15 | interface SessionAwareRunnable { 16 | 17 | void run(Session upperSession, Tuple tuple); 18 | 19 | } 20 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/model/key/spi/AssociationKind.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.model.key.spi; 8 | 9 | import javax.persistence.ElementCollection; 10 | 11 | /** 12 | * The kind of an association. 13 | * 14 | * @author Emmanuel Bernard <emmanuel@hibernate.org> 15 | */ 16 | public enum AssociationKind { 17 | 18 | /** 19 | * An association to another entity. 20 | */ 21 | ASSOCIATION, 22 | 23 | /** 24 | * An embedded element collection. 25 | * 26 | * @see ElementCollection 27 | */ 28 | EMBEDDED_COLLECTION 29 | } 30 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/model/key/spi/AssociationType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.model.key.spi; 8 | 9 | import java.util.Collection; 10 | import java.util.List; 11 | 12 | /** 13 | * The type of an association. 14 | * 15 | * @author Gunnar Morling 16 | */ 17 | public enum AssociationType { 18 | 19 | /** 20 | * A {@link Collection} or {@link List} without an order column. 21 | */ 22 | BAG, 23 | 24 | LIST, 25 | 26 | SET, 27 | 28 | MAP, 29 | 30 | ONE_TO_ONE; 31 | } 32 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/model/spi/AssociationOperationType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.model.spi; 8 | 9 | /** 10 | * Type of operations on the tuple 11 | * 12 | * @author Emmanuel Bernard <emmanuel@hibernate.org> 13 | */ 14 | public enum AssociationOperationType { 15 | /** 16 | * The PUT operation is never for a null value. 17 | * Use REMOVE instead. 18 | */ 19 | PUT, 20 | REMOVE, 21 | CLEAR 22 | } 23 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/model/spi/TupleOperationType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.model.spi; 8 | 9 | /** 10 | * Type of operations on the tuple 11 | * 12 | * @author Emmanuel Bernard <emmanuel@hibernate.org> 13 | */ 14 | public enum TupleOperationType { 15 | PUT, 16 | REMOVE, 17 | PUT_NULL 18 | } 19 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/options/navigation/spi/BaseEntityContext.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.options.navigation.spi; 8 | 9 | import org.hibernate.ogm.options.navigation.EntityContext; 10 | import org.hibernate.ogm.options.navigation.PropertyContext; 11 | 12 | /** 13 | * Base implementation for {@link EntityContext}s. 14 | * 15 | * @author Davide D'Alto <davide@hibernate.org> 16 | * @author Gunnar Morling 17 | */ 18 | public abstract class BaseEntityContext, P extends PropertyContext> extends BaseContext implements EntityContext { 19 | 20 | public BaseEntityContext(ConfigurationContext context) { 21 | super( context ); 22 | } 23 | 24 | } 25 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/options/navigation/spi/BaseGlobalContext.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.options.navigation.spi; 8 | 9 | import org.hibernate.ogm.options.navigation.EntityContext; 10 | import org.hibernate.ogm.options.navigation.GlobalContext; 11 | 12 | /** 13 | * Base implementation {@link GlobalContext}s. 14 | * 15 | * @author Davide D'Alto <davide@hibernate.org> 16 | * @author Gunnar Morling 17 | */ 18 | public abstract class BaseGlobalContext, E extends EntityContext> extends BaseContext implements GlobalContext { 19 | 20 | public BaseGlobalContext(ConfigurationContext context) { 21 | super( context ); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/options/navigation/spi/BasePropertyContext.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.options.navigation.spi; 8 | 9 | import org.hibernate.ogm.options.navigation.EntityContext; 10 | import org.hibernate.ogm.options.navigation.PropertyContext; 11 | 12 | /** 13 | * Base implementation for {@link PropertyContext}s. 14 | * 15 | * @author Davide D'Alto <davide@hibernate.org> 16 | * @author Gunnar Morling 17 | */ 18 | public abstract class BasePropertyContext, P extends PropertyContext> extends BaseContext implements PropertyContext { 19 | 20 | public BasePropertyContext(ConfigurationContext context) { 21 | super( context ); 22 | } 23 | 24 | } 25 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/options/shared/impl/IndexOptionsOption.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.options.shared.impl; 8 | 9 | import org.hibernate.ogm.options.shared.spi.IndexOptions; 10 | import org.hibernate.ogm.options.spi.UniqueOption; 11 | 12 | /** 13 | * Option for specifying options specific to a datastore for an index. 14 | * 15 | * @author Guillaume Smet 16 | */ 17 | public class IndexOptionsOption extends UniqueOption { 18 | 19 | 20 | } 21 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/options/spi/AnnotationConverter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.options.spi; 8 | 9 | import java.lang.annotation.Annotation; 10 | 11 | /** 12 | * Convert option {@link Annotation}s into equivalent {@link OptionValuePair}s. 13 | * 14 | * @author Davide D'Alto <davide@hibernate.org> 15 | */ 16 | public interface AnnotationConverter { 17 | 18 | /** 19 | * Converts the given option annotation into an equivalent option value object. 20 | * 21 | * @param annotation the annotation to convert 22 | * @return a option value representing the given option annotation 23 | */ 24 | OptionValuePair convert(T annotation); 25 | 26 | } 27 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/query/impl/NativeNoSqlQuerySpecification.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.query.impl; 8 | 9 | import java.util.Collection; 10 | 11 | import org.hibernate.engine.query.spi.sql.NativeSQLQueryReturn; 12 | import org.hibernate.engine.query.spi.sql.NativeSQLQuerySpecification; 13 | 14 | /** 15 | * Defines a native NoSQL query which may be String-based or object-based. 16 | * 17 | * @author Gunnar Morling 18 | */ 19 | public class NativeNoSqlQuerySpecification extends NativeSQLQuerySpecification { 20 | 21 | public NativeNoSqlQuerySpecification(String queryString, NativeSQLQueryReturn[] queryReturns, Collection querySpaces) { 22 | super( queryString, queryReturns, querySpaces ); 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/service/impl/OgmConfigurationService.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.service.impl; 8 | 9 | import org.hibernate.service.Service; 10 | 11 | /** 12 | * Service providing the information whether Hibernate OGM is enabled or not. All components interested in this 13 | * information should query this service instead of examining properties themselves. 14 | * 15 | * @author Gunnar Morling 16 | */ 17 | public interface OgmConfigurationService extends Service { 18 | 19 | boolean isOgmEnabled(); 20 | } 21 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/transaction/impl/package-info.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | 8 | /** 9 | * This package contains all required OGM customizations around transaction creation and management. 10 | */ 11 | package org.hibernate.ogm.transaction.impl; 12 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/type/descriptor/impl/GridTypeDescriptor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.type.descriptor.impl; 8 | 9 | import java.io.Serializable; 10 | 11 | import org.hibernate.type.descriptor.java.JavaTypeDescriptor; 12 | 13 | /** 14 | * Descriptor for the grid side of a value mapping. 15 | * 16 | * @author Emmanuel Bernard 17 | */ 18 | public interface GridTypeDescriptor extends Serializable { 19 | GridValueBinder getBinder(JavaTypeDescriptor javaTypeDescriptor); 20 | 21 | GridValueExtractor getExtractor(JavaTypeDescriptor javaTypeDescriptor); 22 | } 23 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/type/descriptor/impl/GridValueBinder.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.type.descriptor.impl; 8 | 9 | import org.hibernate.ogm.model.spi.Tuple; 10 | 11 | /** 12 | * Contract to bind a value to the resultset 13 | * 14 | * @author Emmanuel Bernard 15 | */ 16 | public interface GridValueBinder { 17 | //WrappedOptions for streams? 18 | void bind(Tuple resultset, X value, String[] names); 19 | } 20 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/type/descriptor/impl/GridValueExtractor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.type.descriptor.impl; 8 | 9 | import org.hibernate.ogm.model.spi.Tuple; 10 | 11 | /** 12 | * Extract value from the result set 13 | * 14 | * @author Emmanuel Bernard 15 | */ 16 | public interface GridValueExtractor { 17 | //WrappedOptions for streams? 18 | X extract(Tuple resultset, String name); 19 | } 20 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/util/configurationreader/impl/Instantiator.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.util.configurationreader.impl; 8 | 9 | /** 10 | * Implementations instantiate given classes. By default an implementation invoking the no-args constructor of the 11 | * given type is used. 12 | * 13 | * @author Gunnar Morling 14 | */ 15 | public interface Instantiator { 16 | 17 | T newInstance(Class clazz); 18 | } 19 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/util/configurationreader/spi/PropertyValidator.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.util.configurationreader.spi; 8 | 9 | import org.hibernate.HibernateException; 10 | 11 | /** 12 | * Implementations validate given property values. 13 | * 14 | * @author Gunnar Morling 15 | */ 16 | public interface PropertyValidator { 17 | 18 | /** 19 | * Validates the given property value. 20 | * 21 | * @param value the value to validate 22 | * @throws HibernateException in case the given property value is not valid 23 | */ 24 | void validate(T value) throws HibernateException; 25 | } 26 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/util/configurationreader/spi/ShortNameResolver.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.util.configurationreader.spi; 8 | 9 | /** 10 | * Implementations map short names into fully-qualified class names. 11 | * 12 | * @author Gunnar Morling 13 | */ 14 | public interface ShortNameResolver { 15 | 16 | /** 17 | * Does not accept null values for the {@code name} parameter. 18 | */ 19 | boolean isShortName(String name); 20 | 21 | /** 22 | * Does not accept null values for the {@code name} parameter. 23 | */ 24 | String resolve(String shortName); 25 | } 26 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/util/impl/ClassObjectFormatter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.util.impl; 8 | 9 | /** 10 | * Used with JBoss Logging to display class names in log messages. 11 | * 12 | * @author Gunnar Morling 13 | */ 14 | public class ClassObjectFormatter { 15 | 16 | private final String stringRepresentation; 17 | 18 | public ClassObjectFormatter(Class clazz) { 19 | this.stringRepresentation = clazz.getName(); 20 | } 21 | 22 | @Override 23 | public String toString() { 24 | return stringRepresentation; 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/util/impl/CoreLogCategories.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.util.impl; 8 | 9 | /** 10 | * List of log categories used by Hibernate OGM core module. 11 | * under impl package as it's still a work in progress. 12 | * 13 | * @author Emmanuel Bernard <emmanuel@hibernate.org> 14 | */ 15 | public enum CoreLogCategories { 16 | DATASTORE_ACCESS("org.hibernate.ogm.datastore.access"); 17 | 18 | private String category; 19 | 20 | CoreLogCategories(String name) { 21 | this.category = name; 22 | } 23 | 24 | @Override 25 | public String toString() { 26 | return category; 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/util/impl/EffectivelyFinal.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.util.impl; 8 | 9 | import java.lang.annotation.ElementType; 10 | import java.lang.annotation.Retention; 11 | import java.lang.annotation.RetentionPolicy; 12 | import java.lang.annotation.Target; 13 | 14 | /** 15 | * Documents that a non-final field is only ever modified during the bootstrapping phase, making it effectively final 16 | * for the remainder of its lifecycle. The annotated field thus may be considered as safely published to other threads. 17 | * 18 | * @author Gunnar Morling 19 | */ 20 | @Retention(RetentionPolicy.SOURCE) 21 | @Target(ElementType.FIELD) 22 | public @interface EffectivelyFinal { 23 | 24 | } 25 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/util/impl/EmbeddedHelper.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.util.impl; 8 | 9 | import java.util.regex.Pattern; 10 | 11 | /** 12 | * @author Davide D'Alto 13 | */ 14 | public class EmbeddedHelper { 15 | 16 | private static final Pattern EMBEDDED_FIELDNAME_SEPARATOR = Pattern.compile( "\\." ); 17 | 18 | public static String[] split(String columnName) { 19 | return EMBEDDED_FIELDNAME_SEPARATOR.split( columnName ); 20 | } 21 | 22 | public static boolean isPartOfEmbedded(String columnName) { 23 | return columnName.contains( "." ); 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/util/impl/Immutable.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.util.impl; 8 | 9 | import java.lang.annotation.ElementType; 10 | import java.lang.annotation.Retention; 11 | import java.lang.annotation.RetentionPolicy; 12 | import java.lang.annotation.Target; 13 | 14 | /** 15 | * Documents that the value assigned to the annotated field is immutable and thus safe for concurrent access. 16 | * 17 | * @author Gunnar Morling 18 | */ 19 | @Retention(RetentionPolicy.SOURCE) 20 | @Target(ElementType.FIELD) 21 | public @interface Immutable { 22 | 23 | } 24 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/util/impl/ResourceHelper.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.util.impl; 8 | 9 | import java.io.IOException; 10 | import java.io.InputStream; 11 | import java.net.URL; 12 | import java.util.Scanner; 13 | 14 | public class ResourceHelper { 15 | 16 | private static final String FILE_DELIMITER = "\\A"; 17 | 18 | public static String readResource(URL resource) throws IOException { 19 | try ( InputStream is = resource.openStream() ) { 20 | Scanner s = new Scanner( is ).useDelimiter( FILE_DELIMITER ); 21 | return s.hasNext() ? s.next() : ""; 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /core/src/main/java/org/hibernate/ogm/util/impl/TemporaryWorkaround.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.util.impl; 8 | 9 | import java.lang.annotation.Retention; 10 | import java.lang.annotation.RetentionPolicy; 11 | 12 | /** 13 | * Marker for elements which are added as a temporary work-around only and will be removed e.g. as soon as an upstream 14 | * issue has been resolved. 15 | * 16 | * @author Gunnar Morling 17 | */ 18 | @Retention(RetentionPolicy.SOURCE) 19 | public @interface TemporaryWorkaround { 20 | String value(); 21 | } 22 | -------------------------------------------------------------------------------- /core/src/main/resources/META-INF/services/javax.persistence.spi.PersistenceProvider: -------------------------------------------------------------------------------- 1 | org.hibernate.ogm.jpa.HibernateOgmPersistence 2 | -------------------------------------------------------------------------------- /core/src/main/resources/META-INF/services/org.hibernate.boot.spi.MetadataBuilderInitializer: -------------------------------------------------------------------------------- 1 | org.hibernate.ogm.boot.impl.OgmMetadataBuilderInitializer 2 | -------------------------------------------------------------------------------- /core/src/main/resources/META-INF/services/org.hibernate.boot.spi.SessionFactoryBuilderFactory: -------------------------------------------------------------------------------- 1 | org.hibernate.ogm.boot.impl.OgmSessionFactoryBuilderFactory 2 | -------------------------------------------------------------------------------- /core/src/main/resources/META-INF/services/org.hibernate.integrator.spi.Integrator: -------------------------------------------------------------------------------- 1 | org.hibernate.ogm.service.impl.OgmIntegrator 2 | -------------------------------------------------------------------------------- /core/src/main/resources/META-INF/services/org.hibernate.service.spi.ServiceContributor: -------------------------------------------------------------------------------- 1 | org.hibernate.ogm.boot.impl.OgmServiceRegistryInitializer 2 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/associations/collection/types/GrandChild.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.backendtck.associations.collection.types; 8 | 9 | import javax.persistence.Embeddable; 10 | 11 | /** 12 | * @author Emmanuel Bernard <emmanuel@hibernate.org> 13 | */ 14 | @Embeddable 15 | public class GrandChild { 16 | 17 | private String name; 18 | 19 | public GrandChild() { 20 | } 21 | 22 | public GrandChild(String name) { 23 | this.name = name; 24 | } 25 | 26 | public String getName() { 27 | return name; 28 | } 29 | 30 | public void setName(String name) { 31 | this.name = name; 32 | } 33 | 34 | } 35 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/associations/storageconfiguration/PolarCloud.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.backendtck.associations.storageconfiguration; 8 | 9 | import javax.persistence.Entity; 10 | 11 | /** 12 | * @author Gunnar Morling 13 | */ 14 | @Entity 15 | public class PolarCloud extends SnowFlakeProducer { 16 | } 17 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/batchfetching/package-info.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | 8 | /** 9 | * Package containing tests related to batchfetching entity loading. 10 | * 11 | * @author Emmanuel Bernard emmanuel@hibernate.org 12 | */ 13 | package org.hibernate.ogm.backendtck.batchfetching; 14 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/callbacks/Animal.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.backendtck.callbacks; 8 | 9 | import javax.persistence.Embeddable; 10 | 11 | /** 12 | * @author David Williams 13 | */ 14 | @Embeddable 15 | public class Animal { 16 | 17 | private String name; 18 | 19 | public String getName() { 20 | return name; 21 | } 22 | 23 | public void setName(String name) { 24 | this.name = name; 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/callbacks/Bus.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.backendtck.callbacks; 8 | 9 | import javax.persistence.Id; 10 | import javax.persistence.MappedSuperclass; 11 | 12 | @MappedSuperclass 13 | public class Bus { 14 | 15 | @Id 16 | private Integer id; 17 | 18 | public Bus() { 19 | } 20 | 21 | public Bus(Integer id) { 22 | this.id = id; 23 | } 24 | 25 | public Integer getId() { 26 | return id; 27 | } 28 | 29 | public void setId(Integer id) { 30 | this.id = id; 31 | } 32 | 33 | } 34 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/inheritance/CommunityMember.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.backendtck.inheritance; 8 | 9 | import javax.persistence.Entity; 10 | import javax.persistence.Id; 11 | import javax.persistence.Inheritance; 12 | import javax.persistence.InheritanceType; 13 | 14 | @Entity 15 | @Inheritance(strategy = InheritanceType.TABLE_PER_CLASS) 16 | class CommunityMember { 17 | 18 | @Id 19 | public String name; 20 | 21 | public CommunityMember() { 22 | } 23 | 24 | public CommunityMember(String name) { 25 | this.name = name; 26 | } 27 | 28 | } 29 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/inheritance/Employee.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.backendtck.inheritance; 8 | 9 | import javax.persistence.Entity; 10 | 11 | @Entity 12 | class Employee extends CommunityMember { 13 | public String employer; 14 | 15 | public Employee() { 16 | super(); 17 | } 18 | 19 | public Employee(String name, String employer) { 20 | super( name ); 21 | this.employer = employer; 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/inheritance/singletable/depositor/ContactType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.backendtck.inheritance.singletable.depositor; 8 | 9 | public enum ContactType { 10 | TELEPHONE, MOBILE, FAX, EMAIL 11 | } 12 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/inheritance/singletable/depositor/InstantAccessAccount.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.backendtck.inheritance.singletable.depositor; 8 | 9 | import javax.persistence.DiscriminatorValue; 10 | import javax.persistence.Entity; 11 | 12 | @Entity 13 | @DiscriminatorValue(value = "INSTANT_ACCESS_ACCOUNT") 14 | public class InstantAccessAccount extends Account { 15 | 16 | protected InstantAccessAccount() { 17 | } 18 | 19 | public InstantAccessAccount(final Depositor depositor) { 20 | super( depositor ); 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/inheritance/tableperclass/depositor/ContactType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.backendtck.inheritance.tableperclass.depositor; 8 | 9 | public enum ContactType { 10 | TELEPHONE, MOBILE, FAX, EMAIL 11 | } 12 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/inheritance/tableperclass/depositor/InstantAccessAccount.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.backendtck.inheritance.tableperclass.depositor; 8 | 9 | import javax.persistence.DiscriminatorValue; 10 | import javax.persistence.Entity; 11 | 12 | @Entity 13 | @DiscriminatorValue(value = "INSTANT_ACCESS_ACCOUNT") 14 | public class InstantAccessAccount extends Account { 15 | 16 | protected InstantAccessAccount() { 17 | } 18 | 19 | public InstantAccessAccount(final Depositor depositor) { 20 | super( depositor ); 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/optimisticlocking/Nameable.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.backendtck.optimisticlocking; 8 | 9 | /** 10 | * @author Gunnar Morling 11 | */ 12 | public interface Nameable { 13 | 14 | void setName(String name); 15 | 16 | String getName(); 17 | } 18 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/optimisticlocking/Star.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.backendtck.optimisticlocking; 8 | 9 | import javax.persistence.Embeddable; 10 | 11 | /** 12 | * @author Gunnar Morling 13 | * 14 | */ 15 | @Embeddable 16 | public class Star { 17 | 18 | private String name; 19 | 20 | Star() { 21 | } 22 | 23 | public Star(String name) { 24 | this.name = name; 25 | } 26 | 27 | public String getName() { 28 | return name; 29 | } 30 | 31 | public void setName(String name) { 32 | this.name = name; 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/package-info.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | /** 8 | * This package contains end-to-end tests which should be executed for every datastore module. If required, single 9 | * tests can be skipped on specific dialects by annotating them with 10 | * {@link org.hibernate.ogm.utils.SkipByGridDialect}. 11 | * 12 | * @author Gunnar Morling 13 | */ 14 | package org.hibernate.ogm.backendtck; 15 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/queries/parameters/Genre.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.backendtck.queries.parameters; 8 | 9 | /** 10 | * A movie genre. 11 | * 12 | * @author Gunnar Morling 13 | */ 14 | public enum Genre { 15 | THRILLER, COMEDY, DRAMA 16 | } 17 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/simpleentity/Hero.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.backendtck.simpleentity; 8 | 9 | import javax.persistence.Entity; 10 | import javax.persistence.Id; 11 | 12 | /** 13 | * @author Emmanuel Bernard 14 | */ 15 | @Entity 16 | public class Hero { 17 | private String name; 18 | 19 | @Id 20 | public String getName() { 21 | return name; 22 | } 23 | 24 | public void setName(String name) { 25 | this.name = name; 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/simpleentity/SuperHero.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.backendtck.simpleentity; 8 | 9 | import javax.persistence.Entity; 10 | 11 | /** 12 | * @author Emmanuel Bernard 13 | */ 14 | @Entity 15 | public class SuperHero extends Hero { 16 | private String specialPower; 17 | 18 | public String getSpecialPower() { 19 | return specialPower; 20 | } 21 | 22 | public void setSpecialPower(String specialPower) { 23 | this.specialPower = specialPower; 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/type/converter/MyStringToUpperCaseStringConverter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.backendtck.type.converter; 8 | 9 | import javax.persistence.AttributeConverter; 10 | 11 | /** 12 | * @author Gunnar Morling 13 | */ 14 | public class MyStringToUpperCaseStringConverter implements AttributeConverter { 15 | 16 | @Override 17 | public String convertToDatabaseColumn(MyString attribute) { 18 | return attribute != null ? attribute.toString().toUpperCase() : null; 19 | } 20 | 21 | @Override 22 | public MyString convertToEntityAttribute(String dbData) { 23 | return dbData != null ? new MyString( dbData.toLowerCase() ) : null; 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/type/converter/StringToMyStringConverter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.backendtck.type.converter; 8 | 9 | import javax.persistence.AttributeConverter; 10 | 11 | /** 12 | * @author Gunnar Morling 13 | */ 14 | public class StringToMyStringConverter implements AttributeConverter { 15 | 16 | @Override 17 | public MyString convertToDatabaseColumn(String attribute) { 18 | return attribute != null ? new MyString( attribute.toUpperCase() ) : null; 19 | } 20 | 21 | @Override 22 | public String convertToEntityAttribute(MyString dbData) { 23 | return dbData != null ? dbData.toString().toLowerCase() : null; 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/backendtck/type/converter/StringToUpperCaseConverter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.backendtck.type.converter; 8 | 9 | import javax.persistence.AttributeConverter; 10 | 11 | /** 12 | * @author Gunnar Morling 13 | */ 14 | public class StringToUpperCaseConverter implements AttributeConverter { 15 | 16 | @Override 17 | public String convertToDatabaseColumn(String attribute) { 18 | return attribute != null ? attribute.toUpperCase() : null; 19 | } 20 | 21 | @Override 22 | public String convertToEntityAttribute(String dbData) { 23 | return dbData != null ? dbData.toLowerCase() : null; 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/test/boot/InvalidGridDialect.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.test.boot; 8 | 9 | import org.hibernate.ogm.datastore.map.impl.MapDialect; 10 | 11 | 12 | /** 13 | * Invalid GridDialect: no constructor accepts a DatastoreProvider parameter. 14 | * 15 | * @author Guillaume Smet 16 | */ 17 | public class InvalidGridDialect extends MapDialect { 18 | 19 | public InvalidGridDialect() { 20 | super( null ); 21 | } 22 | 23 | } 24 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/test/options/examples/EmbedExampleOption.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.test.options.examples; 8 | 9 | import org.hibernate.ogm.options.spi.UniqueOption; 10 | 11 | /** 12 | * Offer the ability to embed an object in the configuration. 13 | *

14 | * This is a {@link UniqueOption} that can be used for testing. 15 | * 16 | * @author Davide D'Alto <davide@hibernate.org> 17 | */ 18 | public class EmbedExampleOption extends UniqueOption { 19 | } 20 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/test/options/examples/ForceExampleOption.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.test.options.examples; 8 | 9 | import org.hibernate.ogm.options.spi.UniqueOption; 10 | 11 | /** 12 | * Can be used to map an options that force some kind of policy. 13 | *

14 | * This is a {@link UniqueOption} that can be used for testing. 15 | * 16 | * @author Davide D'Alto <davide@hibernate.org> 17 | */ 18 | public class ForceExampleOption extends UniqueOption { 19 | } 20 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/test/options/examples/NamedQueryOption.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.test.options.examples; 8 | 9 | import org.hibernate.ogm.options.spi.Option; 10 | 11 | /** 12 | * An {@link Option} representing a named query. 13 | * The value represents the HQL query 14 | * 15 | * @author Davide D'Alto <davide@hibernate.org> 16 | */ 17 | public class NamedQueryOption extends Option { 18 | 19 | private final String name; 20 | 21 | public NamedQueryOption(String name) { 22 | this.name = name; 23 | } 24 | 25 | @Override 26 | public String getOptionIdentifier() { 27 | return name; 28 | } 29 | 30 | public String getName() { 31 | return name; 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/test/options/examples/PermissionOption.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.test.options.examples; 8 | 9 | import org.hibernate.ogm.options.spi.Option; 10 | 11 | /** 12 | * An example non-unique option for testing purposes. 13 | * 14 | * @author Gunnar Morling 15 | * 16 | */ 17 | public class PermissionOption extends Option { 18 | 19 | private final String role; 20 | 21 | public PermissionOption(String role) { 22 | this.role = role; 23 | } 24 | 25 | @Override 26 | public String getOptionIdentifier() { 27 | return role; 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/test/options/mapping/model/Microwave.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.test.options.mapping.model; 8 | 9 | /** 10 | * @author Gunnar Morling 11 | */ 12 | public class Microwave { 13 | 14 | public int power; 15 | } 16 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/test/options/mapping/model/Refrigerator.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.test.options.mapping.model; 8 | 9 | /** 10 | * @author Gunnar Morling 11 | */ 12 | public class Refrigerator { 13 | 14 | public int temperature; 15 | } 16 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/test/options/mapping/model/SampleNoSqlDatastore.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.test.options.mapping.model; 8 | 9 | import org.hibernate.ogm.datastore.spi.DatastoreConfiguration; 10 | import org.hibernate.ogm.options.navigation.spi.ConfigurationContext; 11 | import org.hibernate.ogm.test.options.mapping.model.SampleOptionModel.SampleGlobalContext; 12 | 13 | /** 14 | * @author Gunnar Morling 15 | */ 16 | public class SampleNoSqlDatastore implements DatastoreConfiguration { 17 | 18 | @Override 19 | public SampleGlobalContext getConfigurationBuilder(ConfigurationContext context) { 20 | return SampleOptionModel.createGlobalContext( context ); 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/test/package-info.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | /** 8 | * This package contains unit tests for specific core components and should only be executed once when building the 9 | * "core" module. 10 | * 11 | * @author Gunnar Morling 12 | */ 13 | package org.hibernate.ogm.test; 14 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/test/testsupport/Poem.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.test.testsupport; 8 | 9 | import javax.persistence.Entity; 10 | import javax.persistence.GeneratedValue; 11 | import javax.persistence.Id; 12 | 13 | import org.hibernate.annotations.GenericGenerator; 14 | 15 | /** 16 | * @author Guillaume Smet 17 | */ 18 | @Entity 19 | public class Poem { 20 | 21 | private String id; 22 | 23 | @Id 24 | @GeneratedValue(generator = "uuid") 25 | @GenericGenerator(name = "uuid", strategy = "uuid2") 26 | public String getId() { 27 | return id; 28 | } 29 | 30 | public void setId(String id) { 31 | this.id = id; 32 | } 33 | 34 | } 35 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/utils/BytemanHelperStateCleanup.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.utils; 8 | 9 | import org.junit.rules.ExternalResource; 10 | 11 | /** 12 | * A JUnit rule to make sure all tests using the Byteman Helper 13 | * org.hibernate.search.testsupport.BytemanHelper 14 | * do properly cleanup the static shared state. 15 | */ 16 | public class BytemanHelperStateCleanup extends ExternalResource { 17 | 18 | @Override 19 | protected void after() { 20 | BytemanHelper.resetEventStack(); 21 | BytemanHelper.resetCounters(); 22 | } 23 | 24 | } 25 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/utils/OgmAssertions.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.utils; 8 | 9 | import java.util.List; 10 | 11 | import org.fest.assertions.Assertions; 12 | 13 | /** 14 | * Provide additional assert to {@link Assertions} 15 | * 16 | * @author Davide D'Alto 17 | */ 18 | public class OgmAssertions extends Assertions { 19 | 20 | public static OrderedListAssert assertThat(List actual) { 21 | return new OrderedListAssert( actual ); 22 | } 23 | 24 | } 25 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/utils/TestForIssue.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.utils; 8 | 9 | import java.lang.annotation.ElementType; 10 | import java.lang.annotation.Retention; 11 | import java.lang.annotation.RetentionPolicy; 12 | import java.lang.annotation.Target; 13 | 14 | /** 15 | * A documentation annotation for specifying what JIRA issue is being tested. 16 | * 17 | * @author Steve Ebersole 18 | */ 19 | @Retention(RetentionPolicy.SOURCE) 20 | @Target({ ElementType.METHOD, ElementType.TYPE }) 21 | public @interface TestForIssue { 22 | 23 | /** 24 | * The key of the JIRA issues tested. 25 | * 26 | * @return The JIRA issues keys 27 | */ 28 | String[] jiraKey(); 29 | } 30 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/utils/TestSessionFactoryConfiguration.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.utils; 8 | 9 | import java.lang.annotation.ElementType; 10 | import java.lang.annotation.Retention; 11 | import java.lang.annotation.RetentionPolicy; 12 | import java.lang.annotation.Target; 13 | 14 | /** 15 | * Marks a method of a test executed with {@link OgmTestRunner} which should inspect or modify the test's 16 | * configuration. 17 | *

18 | * The method must have a single parameter of type {@code Map}. 19 | * 20 | * @author Gunnar Morling 21 | */ 22 | @Retention(RetentionPolicy.RUNTIME) 23 | @Target(ElementType.METHOD) 24 | public @interface TestSessionFactoryConfiguration { 25 | } 26 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/utils/Throwables.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.utils; 8 | 9 | /** 10 | * Functionality for dealing with {@link Throwable}s. 11 | * 12 | * @author Gunnar Morling 13 | */ 14 | public class Throwables { 15 | 16 | public static Throwable getRootCause(Throwable throwable) { 17 | while ( true ) { 18 | Throwable cause = throwable.getCause(); 19 | if ( cause == null ) { 20 | return throwable; 21 | } 22 | throwable = cause; 23 | } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/utils/package-info.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | /** 8 | * This package contains test utilities and infrastructure such as OGM-specific test runners. 9 | * 10 | * @author Gunnar Morling 11 | */ 12 | package org.hibernate.ogm.utils; 13 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/utils/parser/MapBasedEntityNamesResolver.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.utils.parser; 8 | 9 | import java.util.Map; 10 | 11 | import org.hibernate.hql.ast.spi.EntityNamesResolver; 12 | 13 | /** 14 | * @author Sanne Grinovero <sanne@hibernate.org> (C) 2012 Red Hat Inc. 15 | */ 16 | public class MapBasedEntityNamesResolver implements EntityNamesResolver { 17 | 18 | private final Map> entityNames; 19 | 20 | public MapBasedEntityNamesResolver(Map> entityNames) { 21 | this.entityNames = entityNames; 22 | } 23 | 24 | @Override 25 | public Class getClassFromName(String entityName) { 26 | return entityNames.get( entityName ); 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /core/src/test/java/org/hibernate/ogm/utils/test/package-info.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | /** 8 | * This package contains tests for the test infrastructure in {@link org.hibernate.ogm.utils}. 9 | * 10 | * @author Gunnar Morling 11 | */ 12 | package org.hibernate.ogm.utils.test; 13 | -------------------------------------------------------------------------------- /core/src/test/resources/configuration-test.properties: -------------------------------------------------------------------------------- 1 | # 2 | # Hibernate OGM, Domain model persistence for NoSQL datastores 3 | # 4 | # License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | # See the lgpl.txt file in the root directory or . 6 | # 7 | 8 | hibernate.ogm.configuration.testproperty=foobar 9 | -------------------------------------------------------------------------------- /core/src/test/resources/hibernate.properties: -------------------------------------------------------------------------------- 1 | # 2 | # Hibernate OGM, Domain model persistence for NoSQL datastores 3 | # 4 | # License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | # See the lgpl.txt file in the root directory or . 6 | # 7 | 8 | #@author Emmanuel Bernard 9 | hibernate.search.lucene_version=LUCENE_CURRENT 10 | hibernate.ogm.datastore.provider=map 11 | -------------------------------------------------------------------------------- /core/src/test/resources/log4j.properties: -------------------------------------------------------------------------------- 1 | # 2 | # Hibernate OGM, Domain model persistence for NoSQL datastores 3 | # 4 | # License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | # See the lgpl.txt file in the root directory or . 6 | # 7 | # @author Emmanuel Bernard 8 | log4j.appender.stdout=org.apache.log4j.ConsoleAppender 9 | log4j.appender.stdout.Target=System.out 10 | log4j.appender.stdout.layout=org.apache.log4j.PatternLayout 11 | log4j.appender.stdout.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{3}:%L - %m%n 12 | 13 | log4j.rootLogger=info, stdout 14 | 15 | log4j.logger.org.hibernate=info 16 | log4j.logger.org.hibernate.ogm.datastore.access=trace 17 | log4j.logger.org.hibernate.ogm=debug 18 | -------------------------------------------------------------------------------- /core/src/test/resources/persistencexml/ogm-noprovider.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 12 | 13 | 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /core/src/test/resources/persistencexml/ogm.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 12 | 13 | org.hibernate.ogm.jpa.HibernateOgmPersistence 14 | 15 | 16 | -------------------------------------------------------------------------------- /core/src/test/resources/persistencexml/transaction-type-jta.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 12 | 13 | org.hibernate.ogm.jpa.HibernateOgmPersistence 14 | 15 | 16 | -------------------------------------------------------------------------------- /core/src/test/resources/persistencexml/transaction-type-resource-local.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 12 | 13 | org.hibernate.ogm.jpa.HibernateOgmPersistence 14 | 15 | 16 | -------------------------------------------------------------------------------- /documentation/examples/gettingstarted/src/main/resources/log4j.properties: -------------------------------------------------------------------------------- 1 | # 2 | # Hibernate OGM, Domain model persistence for NoSQL datastores 3 | # 4 | # License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | # See the lgpl.txt file in the root directory or . 6 | # 7 | # @author Emmanuel Bernard 8 | log4j.appender.stdout=org.apache.log4j.ConsoleAppender 9 | log4j.appender.stdout.Target=System.out 10 | log4j.appender.stdout.layout=org.apache.log4j.PatternLayout 11 | log4j.appender.stdout.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L - %m%n 12 | 13 | log4j.rootLogger=warn, stdout 14 | log4j.logger.org.hibernate.ogm.examples.gettingstarted=debug 15 | -------------------------------------------------------------------------------- /documentation/examples/gettingstarted/src/test/java/org/hibernate/ogm/gettingstarted/GettingstartedGuideBootsTest.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.gettingstarted; 8 | 9 | import org.hibernate.ogm.examples.gettingstarted.DogBreedRunner; 10 | import org.junit.Test; 11 | 12 | public class GettingstartedGuideBootsTest { 13 | 14 | @Test 15 | public void bootsWithoutExceptions() { 16 | DogBreedRunner.main( new String[0] ); 17 | } 18 | 19 | } 20 | -------------------------------------------------------------------------------- /documentation/manual/.gitignore: -------------------------------------------------------------------------------- 1 | # Asciidoctor 2 | 3 | Rakefile 4 | Gemfile 5 | Gemfile.lock 6 | .bundle/ 7 | _bin/ 8 | .rvmrc 9 | -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/data-association-document.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/data-association-document.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/data-association.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/data-association.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/data-entity.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/data-entity.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/hibernate_ogm_600px.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/hibernate_ogm_600px.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-@Column-@Table-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-@Column-@Table-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-@ElementCollection-@OrderColumn-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-@ElementCollection-@OrderColumn-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-@ElementCollection-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-@ElementCollection-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-@ElementCollection-map-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-@ElementCollection-map-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-@Embedded-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-@Embedded-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-@EmbeddedId-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-@EmbeddedId-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-bi-many-to-many-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-bi-many-to-many-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-bi-many-to-one-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-bi-many-to-one-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-bi-one-to-one-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-bi-one-to-one-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-bi-one-to-one-many-to-many-same-entity-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-bi-one-to-one-many-to-many-same-entity-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-sequence-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-sequence-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-single-node-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-single-node-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-table-based-sequence-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-table-based-sequence-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-uni-many-to-many-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-uni-many-to-many-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-uni-many-to-one-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-uni-many-to-one-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-uni-one-to-many-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-uni-one-to-many-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-uni-one-to-many-with-@MapKeyColumn-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-uni-one-to-many-with-@MapKeyColumn-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-uni-one-to-many-with-map-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-uni-one-to-many-with-map-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-uni-one-to-one-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-uni-one-to-one-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/neo4j-unii-many-to-one-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/neo4j-unii-many-to-one-example.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/nosql.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/nosql.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/ogm-architecture-with-hsearch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/ogm-architecture-with-hsearch.png -------------------------------------------------------------------------------- /documentation/manual/src/main/resources/images/ogm-architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/documentation/manual/src/main/resources/images/ogm-architecture.png -------------------------------------------------------------------------------- /featurepack/core/assembly.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | assembly 4 | 5 | zip 6 | 7 | false 8 | 9 | 10 | target/${project.artifactId}-${project.version} 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /featurepack/core/src/main/alias/ogm/core/module.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 11 | -------------------------------------------------------------------------------- /featurepack/core/src/main/feature-pack-def/feature-pack-template.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /featurepack/core/src/main/modules/ogm/jipijapa/module.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /featurepack/core/src/main/modules/org/parboiled/module.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /featurepack/infinispan-embedded/assembly.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | assembly 4 | 5 | zip 6 | 7 | false 8 | 9 | 10 | target/${project.artifactId}-${project.version} 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /featurepack/infinispan-embedded/src/main/alias/ogm/infinispan-embedded/module.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 11 | -------------------------------------------------------------------------------- /featurepack/infinispan-embedded/src/main/feature-pack-def/feature-pack-template.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /featurepack/infinispan-remote/assembly.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | assembly 4 | 5 | zip 6 | 7 | false 8 | 9 | 10 | target/${project.artifactId}-${project.version} 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /featurepack/infinispan-remote/src/main/alias/ogm/infinispan-remote/module.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 11 | -------------------------------------------------------------------------------- /featurepack/infinispan-remote/src/main/feature-pack-def/feature-pack-template.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /featurepack/mongodb/assembly.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | assembly 4 | 5 | zip 6 | 7 | false 8 | 9 | 10 | target/${project.artifactId}-${project.version} 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /featurepack/mongodb/src/main/alias/ogm/mongodb/module.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 11 | -------------------------------------------------------------------------------- /featurepack/mongodb/src/main/feature-pack-def/feature-pack-template.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /featurepack/neo4j/assembly.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | assembly 4 | 5 | zip 6 | 7 | false 8 | 9 | 10 | target/${project.artifactId}-${project.version} 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /featurepack/neo4j/src/main/alias/ogm/neo4j/module.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 11 | -------------------------------------------------------------------------------- /featurepack/neo4j/src/main/feature-pack-def/feature-pack-template.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /infinispan-embedded/src/main/java/org/hibernate/ogm/datastore/infinispan/options/navigation/InfinispanEntityContext.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispan.options.navigation; 8 | 9 | import org.hibernate.ogm.datastore.keyvalue.options.navigation.KeyValueStoreEntityContext; 10 | 11 | /** 12 | * Allows to configure Infinispan-specific options applying on a global level. These options may be overridden for single 13 | * properties. 14 | * 15 | * @author Gunnar Morling 16 | */ 17 | public interface InfinispanEntityContext extends KeyValueStoreEntityContext { 18 | } 19 | -------------------------------------------------------------------------------- /infinispan-embedded/src/main/java/org/hibernate/ogm/datastore/infinispan/options/navigation/InfinispanGlobalContext.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispan.options.navigation; 8 | 9 | import org.hibernate.ogm.datastore.keyvalue.options.navigation.KeyValueStoreGlobalContext; 10 | 11 | /** 12 | * Allows to configure Infinispan-specific options applying on a global level. These options may be overridden for single 13 | * entities or properties. 14 | * 15 | * @author Gunnar Morling 16 | */ 17 | public interface InfinispanGlobalContext extends KeyValueStoreGlobalContext { 18 | } 19 | -------------------------------------------------------------------------------- /infinispan-embedded/src/main/java/org/hibernate/ogm/datastore/infinispan/options/navigation/InfinispanPropertyContext.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispan.options.navigation; 8 | 9 | import org.hibernate.ogm.datastore.keyvalue.options.navigation.KeyValueStorePropertyContext; 10 | 11 | /** 12 | * Allows to configure Infinispan-specific options for a single property. 13 | * 14 | * @author Gunnar Morling 15 | */ 16 | public interface InfinispanPropertyContext extends KeyValueStorePropertyContext { 17 | } 18 | -------------------------------------------------------------------------------- /infinispan-embedded/src/main/java/org/hibernate/ogm/datastore/infinispan/persistencestrategy/kind/impl/CacheNames.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispan.persistencestrategy.kind.impl; 8 | 9 | /** 10 | * The names of the caches used to store entities etc. in Infinispan. 11 | * 12 | * @author Emmanuel Bernard <emmanuel@hibernate.org> 13 | */ 14 | public final class CacheNames { 15 | public static final String ENTITY_CACHE = "ENTITIES"; 16 | public static final String ASSOCIATION_CACHE = "ASSOCIATIONS"; 17 | public static final String IDENTIFIER_CACHE = "IDENTIFIERS"; 18 | } 19 | -------------------------------------------------------------------------------- /infinispan-embedded/src/main/resources/META-INF/services/org.infinispan.lifecycle.ModuleLifecycle: -------------------------------------------------------------------------------- 1 | org.hibernate.ogm.datastore.infinispan.impl.InfinispanExtension 2 | -------------------------------------------------------------------------------- /infinispan-embedded/src/test/java/org/hibernate/ogm/datastore/infinispan/test/storedprocedures/InvalidStoredProcedure.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | 8 | package org.hibernate.ogm.datastore.infinispan.test.storedprocedures; 9 | 10 | import java.util.concurrent.Callable; 11 | 12 | /** 13 | * Store procedures should implement {@link Callable}. 14 | * 15 | * @author The Viet Nguyen &ntviet18@gmail.com& 16 | */ 17 | public class InvalidStoredProcedure implements Runnable { 18 | 19 | public static String INVALID_STORED_PROCEDURE_NAME = "invalidaStoredProcedure"; 20 | 21 | @Override 22 | public void run() { 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /infinispan-embedded/src/test/java/org/hibernate/ogm/datastore/infinispan/test/storedprocedures/SimpleValueProcedure.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | 8 | package org.hibernate.ogm.datastore.infinispan.test.storedprocedures; 9 | 10 | import java.util.concurrent.Callable; 11 | 12 | /** 13 | * When called returns the value passed as parameter. 14 | * 15 | * @see NamedParametersStoredProcedureCallTest 16 | * 17 | * @author The Viet Nguyen &ntviet18@gmail.com& 18 | */ 19 | public class SimpleValueProcedure implements Callable { 20 | 21 | private Integer param; 22 | 23 | public void setParam(Integer param) { 24 | this.param = param; 25 | } 26 | 27 | @Override 28 | public Integer call() { 29 | return param; 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /infinispan-embedded/src/test/resources/hibernate.properties: -------------------------------------------------------------------------------- 1 | # 2 | # Hibernate OGM, Domain model persistence for NoSQL datastores 3 | # 4 | # License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | # See the lgpl.txt file in the root directory or . 6 | # 7 | 8 | #@author Emmanuel Bernard 9 | hibernate.search.lucene_version=LUCENE_CURRENT 10 | hibernate.ogm.datastore.provider=infinispan 11 | hibernate.ogm.infinispan.configuration_resource_name=infinispan-local.xml 12 | -------------------------------------------------------------------------------- /infinispan-embedded/src/test/resources/log4j.properties: -------------------------------------------------------------------------------- 1 | # 2 | # Hibernate OGM, Domain model persistence for NoSQL datastores 3 | # 4 | # License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | # See the lgpl.txt file in the root directory or . 6 | # 7 | 8 | #@author Emmanuel Bernard 9 | log4j.appender.stdout=org.apache.log4j.ConsoleAppender 10 | log4j.appender.stdout.Target=System.out 11 | log4j.appender.stdout.layout=org.apache.log4j.PatternLayout 12 | log4j.appender.stdout.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L - %m%n 13 | 14 | log4j.rootLogger=trace, stdout 15 | 16 | log4j.logger.org.hibernate=info 17 | log4j.logger.org.infinispan=info 18 | log4j.logger.org.jgroups=info 19 | log4j.logger.com.arjuna=info 20 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/impl/AssociationCacheOperation.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.impl; 8 | 9 | import org.hibernate.ogm.datastore.infinispanremote.impl.protostream.ProtostreamAssociationPayload; 10 | import org.hibernate.ogm.datastore.infinispanremote.impl.protostream.ProtostreamId; 11 | import org.infinispan.client.hotrod.RemoteCache; 12 | 13 | @FunctionalInterface 14 | public interface AssociationCacheOperation { 15 | 16 | T doOnCache(RemoteCache c); 17 | 18 | } 19 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/impl/CacheOperation.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.impl; 8 | 9 | import org.hibernate.ogm.datastore.infinispanremote.impl.protostream.ProtostreamId; 10 | import org.hibernate.ogm.datastore.infinispanremote.impl.protostream.ProtostreamPayload; 11 | import org.infinispan.client.hotrod.RemoteCache; 12 | 13 | @FunctionalInterface 14 | public interface CacheOperation { 15 | 16 | T doOnCache(RemoteCache c); 17 | 18 | } 19 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/impl/ProtoStreamMappingAdapter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.impl; 8 | 9 | import org.hibernate.ogm.datastore.infinispanremote.impl.protostream.ProtostreamId; 10 | import org.hibernate.ogm.datastore.infinispanremote.impl.protostream.ProtostreamPayload; 11 | import org.hibernate.ogm.model.spi.Tuple; 12 | 13 | public interface ProtoStreamMappingAdapter { 14 | 15 | ProtostreamPayload createValuePayload(Tuple tuple); 16 | 17 | ProtostreamId createIdPayload(String[] columnNames, Object[] columnValues); 18 | 19 | T withinCacheEncodingContext(CacheOperation function); 20 | 21 | String[] listIdColumnNames(); 22 | 23 | } 24 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/impl/VersionedAssociation.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.impl; 8 | 9 | import org.hibernate.ogm.model.spi.Association; 10 | import org.hibernate.ogm.model.spi.AssociationSnapshot; 11 | 12 | 13 | public class VersionedAssociation extends Association { 14 | 15 | private long version; 16 | 17 | public VersionedAssociation() { 18 | super(); 19 | } 20 | 21 | public VersionedAssociation(AssociationSnapshot snapshot) { 22 | super( snapshot ); 23 | } 24 | 25 | public long getVersion() { 26 | return version; 27 | } 28 | 29 | public void setVersion(long version) { 30 | this.version = version; 31 | } 32 | 33 | } 34 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/impl/VersionedTuple.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.impl; 8 | 9 | import org.hibernate.ogm.model.spi.Tuple; 10 | import org.hibernate.ogm.model.spi.TupleSnapshot; 11 | 12 | public final class VersionedTuple extends Tuple { 13 | 14 | private long version; 15 | 16 | public VersionedTuple() { 17 | } 18 | 19 | public VersionedTuple(TupleSnapshot snapshot, SnapshotType snapshotType) { 20 | super( snapshot, snapshotType ); 21 | } 22 | 23 | public long getVersion() { 24 | return version; 25 | } 26 | 27 | public void setVersion(long version) { 28 | this.version = version; 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/impl/cachehandler/HotRodCacheHandler.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.impl.cachehandler; 8 | 9 | import java.util.Set; 10 | 11 | import org.infinispan.client.hotrod.RemoteCacheManager; 12 | 13 | /** 14 | * Handles {@link org.infinispan.client.hotrod.RemoteCache} at startup 15 | * Validating and optionally Creating them 16 | * 17 | * @author Fabio Massimo Ercoli 18 | */ 19 | public interface HotRodCacheHandler { 20 | 21 | void startAndValidateCaches(RemoteCacheManager hotrodClient); 22 | 23 | Set getCaches(); 24 | 25 | String getConfiguration(String cacheName); 26 | 27 | } 28 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/impl/protobuf/ProtofieldDecoder.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.impl.protobuf; 8 | 9 | import java.io.IOException; 10 | 11 | import org.infinispan.protostream.MessageMarshaller.ProtoStreamReader; 12 | 13 | @FunctionalInterface 14 | public interface ProtofieldDecoder { 15 | 16 | T read(ProtoStreamReader reader) throws IOException; 17 | 18 | } 19 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/impl/protobuf/ProtofieldEncoder.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.impl.protobuf; 8 | 9 | import java.io.IOException; 10 | 11 | import org.infinispan.protostream.MessageMarshaller.ProtoStreamWriter; 12 | 13 | @FunctionalInterface 14 | public interface ProtofieldEncoder { 15 | 16 | void encode(ProtoStreamWriter outProtobuf, T value) throws IOException; 17 | 18 | } 19 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/impl/protostream/ProtostreamMappedField.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.impl.protostream; 8 | 9 | 10 | public interface ProtostreamMappedField extends ProtostreamReadWriteable { 11 | 12 | String getColumnName(); 13 | 14 | String getProtobufName(); 15 | 16 | } 17 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/impl/protostream/ProtostreamReadWriteable.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.impl.protostream; 8 | 9 | import org.infinispan.protostream.MessageMarshaller.ProtoStreamReader; 10 | import org.infinispan.protostream.MessageMarshaller.ProtoStreamWriter; 11 | 12 | public interface ProtostreamReadWriteable { 13 | 14 | void writeTo(ProtoStreamWriter outProtobuf, T value); 15 | 16 | T read(ProtoStreamReader reader); 17 | 18 | } 19 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/impl/protostream/multimessage/MultiMessage.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.impl.protostream.multimessage; 8 | 9 | import java.io.Serializable; 10 | 11 | /** 12 | * Could have more than one Protocol Buffer message types representations. 13 | * 14 | * The final message type couldn't be derived from class. 15 | * On the other hand it could discovered on instances, 16 | * using {@link MultiMessage#getMessageType()}. 17 | * 18 | * @author Fabio Massimo Ercoli 19 | */ 20 | public interface MultiMessage extends Serializable { 21 | 22 | String getMessageType(); 23 | } 24 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/impl/schema/ProtobufEntryExporter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.impl.schema; 8 | 9 | 10 | public interface ProtobufEntryExporter { 11 | 12 | void exportProtobufEntry(StringBuilder output); 13 | 14 | } 15 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/impl/schema/ProtobufFieldConsumer.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.impl.schema; 8 | 9 | import java.util.function.Consumer; 10 | 11 | public interface ProtobufFieldConsumer extends Consumer { 12 | 13 | } 14 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/impl/schema/ProtobufFieldExporter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.impl.schema; 8 | 9 | public interface ProtobufFieldExporter { 10 | 11 | void exportProtobufFieldDefinition(StringBuilder sb); 12 | 13 | } 14 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/impl/schema/ProtobufTypeConsumer.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.impl.schema; 8 | 9 | import java.util.function.Consumer; 10 | 11 | public interface ProtobufTypeConsumer extends Consumer { 12 | 13 | } 14 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/impl/schema/ProtobufTypeExporter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.impl.schema; 8 | 9 | import org.hibernate.ogm.datastore.infinispanremote.impl.protobuf.TypeDeclarationsCollector; 10 | 11 | public interface ProtobufTypeExporter { 12 | 13 | void collectTypeDefinitions(TypeDeclarationsCollector typesDefCollector); 14 | 15 | } 16 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/impl/sequences/SequenceId.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.impl.sequences; 8 | 9 | import java.util.Objects; 10 | 11 | public final class SequenceId { 12 | 13 | private final String segmentName; 14 | 15 | public SequenceId(String segmentName) { 16 | this.segmentName = Objects.requireNonNull( segmentName ); 17 | } 18 | 19 | public String getSegmentName() { 20 | return segmentName; 21 | } 22 | 23 | } 24 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/impl/sequences/SequencesCacheOperation.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.impl.sequences; 8 | 9 | import org.infinispan.client.hotrod.RemoteCache; 10 | 11 | @FunctionalInterface 12 | public interface SequencesCacheOperation { 13 | 14 | T doOnCache(RemoteCache c); 15 | 16 | } 17 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/logging/impl/StringSetFormatter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.logging.impl; 8 | 9 | import java.util.Set; 10 | 11 | public final class StringSetFormatter { 12 | 13 | private final Set names; 14 | 15 | public StringSetFormatter(Set names) { 16 | this.names = names; 17 | } 18 | 19 | @Override 20 | public String toString() { 21 | return names.toString(); 22 | } 23 | 24 | } 25 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/options/cache/impl/CacheConfigurationConverter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.options.cache.impl; 8 | 9 | import org.hibernate.ogm.datastore.infinispanremote.options.cache.CacheConfiguration; 10 | import org.hibernate.ogm.options.spi.AnnotationConverter; 11 | import org.hibernate.ogm.options.spi.OptionValuePair; 12 | 13 | public class CacheConfigurationConverter implements AnnotationConverter { 14 | @Override 15 | public OptionValuePair convert(CacheConfiguration annotation) { 16 | return OptionValuePair.getInstance( new CacheConfigurationOption(), annotation ); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/options/cache/impl/CacheConfigurationOption.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.options.cache.impl; 8 | 9 | import org.hibernate.ogm.datastore.infinispanremote.options.cache.CacheConfiguration; 10 | import org.hibernate.ogm.options.spi.UniqueOption; 11 | import org.hibernate.ogm.util.configurationreader.spi.ConfigurationPropertyReader; 12 | 13 | public class CacheConfigurationOption extends UniqueOption { 14 | 15 | @Override 16 | public CacheConfiguration getDefaultValue(ConfigurationPropertyReader propertyReader) { 17 | return null; 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/options/navigation/InfinispanRemoteEntityContext.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.options.navigation; 8 | 9 | import org.hibernate.ogm.datastore.keyvalue.options.navigation.KeyValueStoreEntityContext; 10 | 11 | /** 12 | * Allows to configure Infinispan Remote specific options applying on a global level. 13 | * These options may be overridden for single properties. 14 | * 15 | * @author Gunnar Morling 16 | */ 17 | public interface InfinispanRemoteEntityContext extends KeyValueStoreEntityContext { 18 | } 19 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/options/navigation/InfinispanRemoteGlobalContext.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.options.navigation; 8 | 9 | import org.hibernate.ogm.datastore.keyvalue.options.navigation.KeyValueStoreGlobalContext; 10 | 11 | /** 12 | * Allows to configure Infinispan Remote specific options applying on a global level. 13 | * These options may be overridden for single entities or properties. 14 | * 15 | * @author Gunnar Morling 16 | */ 17 | public interface InfinispanRemoteGlobalContext extends KeyValueStoreGlobalContext { 18 | } 19 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/options/navigation/InfinispanRemotePropertyContext.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.options.navigation; 8 | 9 | import org.hibernate.ogm.datastore.keyvalue.options.navigation.KeyValueStorePropertyContext; 10 | 11 | /** 12 | * Allows to configure Infinispan Remote specific options for a single property. 13 | * 14 | * @author Gunnar Morling 15 | */ 16 | public interface InfinispanRemotePropertyContext extends KeyValueStorePropertyContext { 17 | } 18 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/query/parsing/impl/InfinispanRemoteQueryParameter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.query.parsing.impl; 8 | 9 | import java.io.Serializable; 10 | 11 | /** 12 | * Class represents a parameter of an Infinispan server query 13 | */ 14 | public class InfinispanRemoteQueryParameter implements Serializable { 15 | 16 | private final String name; 17 | 18 | public InfinispanRemoteQueryParameter(String name) { 19 | this.name = name; 20 | } 21 | 22 | @Override 23 | public String toString() { 24 | return ":" + name; 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/schema/spi/MapSchemaCapture.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.schema.spi; 8 | 9 | import java.util.Collections; 10 | import java.util.HashMap; 11 | import java.util.Map; 12 | 13 | public final class MapSchemaCapture implements SchemaCapture { 14 | 15 | private final Map map = new HashMap<>(); 16 | 17 | @Override 18 | public void put(String generatedProtobufName, String generatedProtoschema) { 19 | map.put( generatedProtobufName, generatedProtoschema ); 20 | } 21 | 22 | public Map asMap() { 23 | return Collections.unmodifiableMap( map ); 24 | } 25 | 26 | } 27 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/schema/spi/ProvidedSchemaOverride.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.schema.spi; 8 | 9 | public final class ProvidedSchemaOverride implements SchemaOverride { 10 | 11 | private final String schema; 12 | 13 | public ProvidedSchemaOverride(String schema) { 14 | this.schema = schema; 15 | } 16 | 17 | @Override 18 | public String createProtobufSchema() { 19 | return schema; 20 | } 21 | 22 | } 23 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/schema/spi/SchemaCapture.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.schema.spi; 8 | 9 | public interface SchemaCapture { 10 | 11 | void put(String generatedProtobufName, String generatedProtoschema); 12 | 13 | } 14 | -------------------------------------------------------------------------------- /infinispan-remote/src/main/java/org/hibernate/ogm/datastore/infinispanremote/schema/spi/SchemaOverride.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.schema.spi; 8 | 9 | public interface SchemaOverride { 10 | 11 | String createProtobufSchema(); 12 | 13 | } 14 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/java/org/hibernate/ogm/datastore/infinispanremote/test/configuration/ExistCacheConfigurationEntity.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.test.configuration; 8 | 9 | import javax.persistence.Entity; 10 | import javax.persistence.Id; 11 | 12 | import org.hibernate.ogm.datastore.infinispanremote.options.cache.CacheConfiguration; 13 | 14 | /** 15 | * Used an existing cache as a configuration configuration 16 | * 17 | * @author Fabio Massimo Ercoli 18 | */ 19 | @Entity 20 | @CacheConfiguration("ogm-config") 21 | public class ExistCacheConfigurationEntity { 22 | 23 | @Id 24 | private String id; 25 | 26 | } 27 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/java/org/hibernate/ogm/datastore/infinispanremote/test/configuration/NoAnnotationEntity.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.test.configuration; 8 | 9 | import javax.persistence.Entity; 10 | import javax.persistence.Id; 11 | 12 | /** 13 | * This class not overrides a cache configuration 14 | * 15 | * @author Fabio Massimo Ercoli 16 | */ 17 | @Entity 18 | public class NoAnnotationEntity { 19 | 20 | @Id 21 | private String id; 22 | 23 | } 24 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/java/org/hibernate/ogm/datastore/infinispanremote/test/configuration/NotExistCacheConfigurationEntity.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.test.configuration; 8 | 9 | import javax.persistence.Entity; 10 | import javax.persistence.Id; 11 | 12 | import org.hibernate.ogm.datastore.infinispanremote.options.cache.CacheConfiguration; 13 | 14 | /** 15 | * Used a NOT existing cache configuration 16 | * 17 | * @author Fabio Massimo Ercoli 18 | */ 19 | @Entity 20 | @CacheConfiguration("notExist") 21 | public class NotExistCacheConfigurationEntity { 22 | 23 | @Id 24 | private String id; 25 | 26 | } 27 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/java/org/hibernate/ogm/datastore/infinispanremote/test/initialize/DisneyGrandChild.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.test.initialize; 8 | 9 | import javax.persistence.Embeddable; 10 | 11 | /** 12 | * @author Davide D'Alto 13 | */ 14 | @Embeddable 15 | public class DisneyGrandChild { 16 | private String name; 17 | 18 | public String getName() { 19 | return name; 20 | } 21 | 22 | public void setName(String name) { 23 | this.name = name; 24 | } 25 | 26 | } 27 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/java/org/hibernate/ogm/datastore/infinispanremote/test/protobuf/SimpleEntity.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.test.protobuf; 8 | 9 | import javax.persistence.Entity; 10 | import javax.persistence.Id; 11 | import javax.persistence.Table; 12 | 13 | /** 14 | * @author Fabio Massimo Ercoli 15 | */ 16 | @Entity 17 | @Table(name = "SimpleTable") 18 | public class SimpleEntity { 19 | 20 | @Id 21 | private String id; 22 | 23 | private String name; 24 | 25 | } 26 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/java/org/hibernate/ogm/datastore/infinispanremote/test/query/parsing/CommunityMemberST.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.test.query.parsing; 8 | 9 | import javax.persistence.DiscriminatorValue; 10 | import javax.persistence.Entity; 11 | 12 | /** 13 | * @author Davide D'Alto 14 | */ 15 | @Entity 16 | @DiscriminatorValue("CMM") 17 | public class CommunityMemberST extends PersonST { 18 | 19 | private String project; 20 | 21 | public String getProject() { 22 | return project; 23 | } 24 | 25 | public void setProject(String project) { 26 | this.project = project; 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/java/org/hibernate/ogm/datastore/infinispanremote/test/query/parsing/EmployeeST.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.infinispanremote.test.query.parsing; 8 | 9 | import javax.persistence.DiscriminatorValue; 10 | import javax.persistence.Entity; 11 | 12 | /** 13 | * @author Davide D'Alto 14 | */ 15 | @Entity 16 | @DiscriminatorValue("EMP") 17 | public class EmployeeST extends CommunityMemberST { 18 | 19 | private String employer; 20 | 21 | public String getEmployer() { 22 | return employer; 23 | } 24 | 25 | public void setEmployer(String employer) { 26 | this.employer = employer; 27 | } 28 | 29 | } 30 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/resources/findInterrupt.btm: -------------------------------------------------------------------------------- 1 | # This is extremely useful to find issues with interaction with Infinispan 2 | 3 | RULE findInterrupt 4 | CLASS java.lang.Thread 5 | METHOD interrupt 6 | IF TRUE 7 | DO traceStack("found the caller!\n", 10) 8 | ENDRULE 9 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/resources/hibernate.properties: -------------------------------------------------------------------------------- 1 | # 2 | # Hibernate OGM, Domain model persistence for NoSQL datastores 3 | # 4 | # License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | # See the lgpl.txt file in the root directory or . 6 | # 7 | hibernate.search.lucene_version=LUCENE_CURRENT 8 | hibernate.ogm.datastore.provider=infinispan_remote 9 | hibernate.ogm.create_database=true 10 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/resources/hotrodclient-minimal.properties: -------------------------------------------------------------------------------- 1 | # empty HotRod configuration file 2 | # we use default for all properties here 3 | # it should work if there is an Infinispan server listening on host:port 127.0.0.1:11222 4 | 5 | # infinispan.client.hotrod.server_list = 127.0.0.1:11222 6 | # infinispan.client.hotrod.marshaller = org.hibernate.ogm.datastore.infinispanremote.impl.protostream.OgmProtoStreamMarshaller 7 | # infinispan.client.hotrod.async_executor_factory = org.infinispan.client.hotrod.impl.async.DefaultAsyncExecutorFactory 8 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/resources/log4j.properties: -------------------------------------------------------------------------------- 1 | # 2 | # Hibernate OGM, Domain model persistence for NoSQL datastores 3 | # 4 | # License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | # See the lgpl.txt file in the root directory or . 6 | # 7 | log4j.appender.stdout=org.apache.log4j.ConsoleAppender 8 | log4j.appender.stdout.Target=System.out 9 | log4j.appender.stdout.layout=org.apache.log4j.PatternLayout 10 | log4j.appender.stdout.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L - %m%n 11 | 12 | log4j.rootLogger=debug, stdout 13 | 14 | log4j.logger.org.hibernate=info 15 | log4j.logger.org.hibernate.ogm=debug 16 | log4j.logger.org.infinispan=info 17 | log4j.logger.org.jgroups=info 18 | log4j.logger.com.arjuna=info 19 | #it's noisy: 20 | log4j.logger.org.infinispan.expiration=error 21 | log4j.logger.org.infinispan.client.hotrod.impl.iteration=error 22 | log4j.logger.io.netty=error 23 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/resources/protoschema-expectations/Hero_SuperHero.protobuf: -------------------------------------------------------------------------------- 1 | package HibernateOGMGenerated; 2 | 3 | message Hero_id { 4 | required string name = 1; 5 | } 6 | 7 | message Hero { 8 | optional string DTYPE = 1; 9 | required string name = 2; 10 | optional string specialPower = 3; 11 | } 12 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/resources/protoschema-expectations/Hypothesis_Helicopter.protobuf: -------------------------------------------------------------------------------- 1 | package HibernateOGMGenerated; 2 | 3 | message Helicopter_id { 4 | required string UUID = 1; 5 | } 6 | 7 | message Helicopter { 8 | required string UUID = 1; 9 | optional string name = 2; 10 | } 11 | 12 | message Hypothesis_id { 13 | required string id = 1; 14 | } 15 | 16 | message Hypothesis { 17 | required string id = 1; 18 | optional string description = 2; 19 | optional int32 pos = 3; 20 | } 21 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/resources/protoschema-expectations/IllegalFormat.protobuf: -------------------------------------------------------------------------------- 1 | package HibernateOGMGenerated; 2 | 3 | message SnowFlake { 4 | required string id = 1; 5 | optional string description = 1; 6 | } -------------------------------------------------------------------------------- /infinispan-remote/src/test/resources/protoschema-expectations/sequenceTableGenerationTest.protobuf: -------------------------------------------------------------------------------- 1 | package HibernateOGMGenerated; 2 | 3 | message Actor_id { 4 | required int64 id = 1; 5 | } 6 | 7 | message Actor { 8 | required int64 id = 1; 9 | optional string bestMovieTitle = 2; 10 | optional string name = 3; 11 | } 12 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/resources/protoschema-expectations/tableGenerationTest.protobuf: -------------------------------------------------------------------------------- 1 | package HibernateOGMGenerated; 2 | 3 | message hibernate_sequences_id { 4 | required string sequence_name = 1; 5 | } 6 | 7 | message hibernate_sequences { 8 | required int64 next_val = 2; 9 | } 10 | 11 | message TableWithTableGenerator_id { 12 | required int64 id = 1; 13 | } 14 | 15 | message TableWithTableGenerator { 16 | required int64 id = 1; 17 | optional int64 moment = 2; 18 | optional string subject = 3; 19 | } 20 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/resources/protoschema-userdefined/entities-id-generators-schema.proto: -------------------------------------------------------------------------------- 1 | package HibernateOGMGenerated; 2 | 3 | message hibernate_sequences_id { 4 | required string sequence_name = 1; 5 | } 6 | 7 | message hibernate_sequences { 8 | required int64 next_val = 2; 9 | } 10 | 11 | message TableWithTableGenerator_id { 12 | required int64 id = 1; 13 | } 14 | 15 | message TableWithTableGenerator { 16 | required int64 id = 1; 17 | optional int64 moment = 2; 18 | 19 | /** 20 | * @IndexedField(index=true, store=false, analyze=true) 21 | */ 22 | optional string subject = 3; 23 | } 24 | 25 | message TableWithSequenceGenerator_id { 26 | required int32 id = 1; 27 | } 28 | 29 | message TableWithSequenceGenerator { 30 | required int32 id = 1; 31 | optional string type = 2; 32 | } 33 | 34 | message SimpleTable_id { 35 | required string id = 1; 36 | } 37 | 38 | message SimpleTable { 39 | required string id = 1; 40 | optional string name = 2; 41 | } 42 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/resources/protoschema-userdefined/entity-schema.proto: -------------------------------------------------------------------------------- 1 | package HibernateOGMGenerated; 2 | 3 | message SimpleTable_id { 4 | required string id = 1; 5 | } 6 | 7 | /** 8 | * @Indexed 9 | */ 10 | message SimpleTable { 11 | required string id = 1; 12 | 13 | /** 14 | * @IndexedField(index=true, store=false) 15 | */ 16 | optional string name = 2; 17 | } 18 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/resources/protoschema-userdefined/entity-wrong-schema.proto: -------------------------------------------------------------------------------- 1 | package HibernateOGMGenerated; 2 | 3 | message SimpleTable_id { 4 | required int32 id = 1; 5 | } 6 | 7 | message SimpleTable { 8 | required int32 id = 1; 9 | 10 | /** 11 | * @IndexedField(index=true, store=false) 12 | */ 13 | optional string name = 2; 14 | } 15 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/resources/protoschema-userdefined/sequence-gen-schema.proto: -------------------------------------------------------------------------------- 1 | package HibernateOGMGenerated; 2 | 3 | /** 4 | * @Indexed 5 | */ 6 | message TableWithSequenceGenerator { 7 | required int32 id = 1; 8 | 9 | /** 10 | * @IndexedField(index=true, store=false) 11 | */ 12 | optional string type = 2; 13 | } 14 | 15 | message TableWithSequenceGenerator_id { 16 | required int32 id = 1; 17 | } 18 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/resources/protoschema-userdefined/table-gen-schema.proto: -------------------------------------------------------------------------------- 1 | package HibernateOGMGenerated; 2 | 3 | message TableWithTableGenerator_id { 4 | required int64 id = 1; 5 | } 6 | 7 | message hibernate_sequences { 8 | required int64 next_val = 2; 9 | } 10 | 11 | message hibernate_sequences_id { 12 | required string sequence_name = 1; 13 | } 14 | 15 | message TableWithTableGenerator { 16 | required int64 id = 1; 17 | 18 | /** 19 | * @IndexedField(index=true, store=false) 20 | */ 21 | optional int64 moment = 2; 22 | 23 | /** 24 | * @IndexedField(index=true, store=true) 25 | */ 26 | optional string subject = 3; 27 | } 28 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/resources/storedprocedures/exceptionalProcedure.js: -------------------------------------------------------------------------------- 1 | // mode=local,language=javascript 2 | var RuntimeException = Java.type( 'java.lang.RuntimeException' ); 3 | throw new RuntimeException( 'failed!' ); 4 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/resources/storedprocedures/resultSetProcedure.js: -------------------------------------------------------------------------------- 1 | // mode=local,language=javascript,parameters=[id,title] 2 | var HashMap = Java.type( 'java.util.HashMap' ); 3 | var Collectors = Java.type( "java.util.stream.Collectors" ); 4 | cache.clear(); 5 | cache.put( id, title ); 6 | cache 7 | .entrySet() 8 | .stream() 9 | .filter( function (e) { 10 | return e.getKey() === id 11 | } ) 12 | .limit( 1 ) 13 | .map( function (e) { 14 | var hashMap = new HashMap(); 15 | hashMap.put( 'id', e.getKey() ); 16 | hashMap.put( 'title', e.getValue() ); 17 | return hashMap 18 | } ) 19 | .collect( Collectors.toList() ); 20 | -------------------------------------------------------------------------------- /infinispan-remote/src/test/resources/storedprocedures/simpleValueProcedure.js: -------------------------------------------------------------------------------- 1 | // mode=local,language=javascript 2 | param; 3 | -------------------------------------------------------------------------------- /infinispan/moved.txt: -------------------------------------------------------------------------------- 1 | The dialect for Infinispan Embedded has been renamed in version 5.2 to 2 | hibernate-ogm-infinispan-embedded 3 | 4 | The updated Maven artifact coordinates are: 5 | 6 | org.hibernate.ogm 7 | hibernate-ogm-infinispan 8 | 9 | For any questions and feedback, please get in touch 10 | - http://hibernate.org/community/ 11 | -------------------------------------------------------------------------------- /integrationtest/server-provisioning.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /integrationtest/src/test/java/org/hibernate/ogm/test/integration/neo4j/remote/controller/RemoteNeo4jJtaCleaner.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.test.integration.neo4j.remote.controller; 8 | 9 | import javax.annotation.PreDestroy; 10 | import javax.ejb.Singleton; 11 | import javax.ejb.Startup; 12 | import javax.inject.Inject; 13 | import javax.persistence.EntityManager; 14 | 15 | /** 16 | * @author Davide D'Alto 17 | */ 18 | @Singleton 19 | @Startup 20 | public class RemoteNeo4jJtaCleaner { 21 | 22 | @Inject 23 | private EntityManager em; 24 | 25 | @PreDestroy 26 | public void deleteAll() { 27 | em.createNativeQuery( "MATCH (n) DETACH DELETE (n)" ).executeUpdate(); 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /integrationtest/src/test/java/org/hibernate/ogm/test/integration/testcase/controller/MemberRegistration.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.test.integration.testcase.controller; 8 | 9 | import org.hibernate.ogm.test.integration.testcase.model.Member; 10 | 11 | /** 12 | * Represents a class used to register and find club's members. 13 | * 14 | * @author Davide D'Alto 15 | */ 16 | public interface MemberRegistration { 17 | 18 | Member getNewMember(); 19 | 20 | void register(); 21 | 22 | Member find(Long id); 23 | 24 | Member findWithQuery(Long id); 25 | 26 | Member findWithEmail(String string); 27 | 28 | Member findWithNativeQuery(String nativeQuery); 29 | 30 | void deleteAll(); 31 | 32 | void close(); 33 | } 34 | -------------------------------------------------------------------------------- /integrationtest/src/test/java/org/hibernate/ogm/test/integration/testcase/util/JtaResources.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.test.integration.testcase.util; 8 | 9 | import javax.enterprise.inject.Produces; 10 | import javax.persistence.EntityManager; 11 | import javax.persistence.PersistenceContext; 12 | 13 | /** 14 | * This class uses CDI to alias Java EE resources, such as the persistence context, to CDI beans 15 | */ 16 | public class JtaResources { 17 | 18 | @Produces 19 | @PersistenceContext 20 | private EntityManager em; 21 | 22 | } 23 | -------------------------------------------------------------------------------- /integrationtest/src/test/resources/META-INF/services/org.jboss.arquillian.core.spi.LoadableExtension: -------------------------------------------------------------------------------- 1 | org.hibernate.ogm.test.integration.infinispanremote.HotRodServerLifecycleManager -------------------------------------------------------------------------------- /integrationtest/src/test/resources/module-versions.properties: -------------------------------------------------------------------------------- 1 | #This is to let Maven properties be injected in the file, making it easier to run tests in the IDE as well 2 | #module-slot.org.hibernate.ogm.short-id = ${module-slot.org.hibernate.ogm.short-id} #This one requires specific handling, see org.hibernate.ogm.test.integration.testcase.util.ModulesHelper.getModuleSlotString() 3 | module-slot.org.hibernate.search.short-id = ${module-slot.org.hibernate.search.short-id} 4 | dependency.version.org.hibernate.ogm = ${project.version} -------------------------------------------------------------------------------- /integrationtest/src/test/resources/neo4j-test.properties: -------------------------------------------------------------------------------- 1 | build.directory=${project.build.directory} 2 | -------------------------------------------------------------------------------- /jipijapa/src/main/resources/META-INF/services/org.jipijapa.plugin.spi.PersistenceProviderAdaptor: -------------------------------------------------------------------------------- 1 | org.wildfly.jpa.hibernateogm5.HibernateOGMPersistenceProviderAdaptor 2 | -------------------------------------------------------------------------------- /mongodb/src/main/java/org/hibernate/ogm/datastore/mongodb/options/AssociationDocumentStorageType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.options; 8 | 9 | /** 10 | * Strategies for storing MongoDB association documents. 11 | * 12 | * @author Gunnar Morling 13 | */ 14 | public enum AssociationDocumentStorageType { 15 | 16 | /** 17 | * Stores the association info in the same MongoDB collection for all associations 18 | */ 19 | GLOBAL_COLLECTION, 20 | 21 | /** 22 | * Stores the association in a dedicated MongoDB collection per association 23 | */ 24 | COLLECTION_PER_ASSOCIATION 25 | } 26 | -------------------------------------------------------------------------------- /mongodb/src/main/java/org/hibernate/ogm/datastore/mongodb/options/impl/GridFSBucketConverter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.options.impl; 8 | 9 | import org.hibernate.ogm.datastore.mongodb.options.GridFSBucket; 10 | import org.hibernate.ogm.options.spi.AnnotationConverter; 11 | import org.hibernate.ogm.options.spi.OptionValuePair; 12 | 13 | /** 14 | * @author Sergey Chernolyas &sergey_chernolyas@gmail.com& 15 | */ 16 | public class GridFSBucketConverter implements AnnotationConverter { 17 | 18 | @Override 19 | public OptionValuePair convert(GridFSBucket annotation) { 20 | return OptionValuePair.getInstance( new GridFSBucketOption(), annotation.value() ); 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /mongodb/src/main/java/org/hibernate/ogm/datastore/mongodb/options/impl/GridFSBucketOption.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.options.impl; 8 | 9 | import org.hibernate.ogm.options.spi.UniqueOption; 10 | 11 | /** 12 | * @author Sergey Chernolyas &sergey_chernolyas@gmail.com& 13 | */ 14 | public class GridFSBucketOption extends UniqueOption { 15 | 16 | } 17 | -------------------------------------------------------------------------------- /mongodb/src/main/java/org/hibernate/ogm/datastore/mongodb/query/parsing/nativequery/impl/NativeQueryParseException.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.query.parsing.nativequery.impl; 8 | 9 | /** 10 | * An exception thrown by {@link MongoDBQueryDescriptorBuilder} 11 | * if the input is not correct. 12 | */ 13 | public class NativeQueryParseException extends RuntimeException { 14 | public NativeQueryParseException(String message) { 15 | super( message ); 16 | } 17 | 18 | public NativeQueryParseException(Exception e) { 19 | super( e ); 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /mongodb/src/main/java/org/hibernate/ogm/datastore/mongodb/query/parsing/predicate/impl/MongoDBRootPredicate.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.query.parsing.predicate.impl; 8 | 9 | import org.hibernate.hql.ast.spi.predicate.RootPredicate; 10 | 11 | import org.bson.Document; 12 | 13 | 14 | /** 15 | * MongoDB-based implementation of {@link RootPredicate}. 16 | * 17 | * @author Gunnar Morling 18 | */ 19 | public class MongoDBRootPredicate extends RootPredicate { 20 | 21 | @Override 22 | public Document getQuery() { 23 | return child == null ? new Document() : child.getQuery(); 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /mongodb/src/main/java/org/hibernate/ogm/datastore/mongodb/type/impl/GeoCollectionGridTypeDescriptor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.type.impl; 8 | 9 | import org.hibernate.ogm.datastore.mongodb.type.GeoCollection; 10 | 11 | /** 12 | * Persists {@link GeoCollection} in the format expected by MongoDB. 13 | * 14 | * @author Aleksandr Mylnikov 15 | */ 16 | public class GeoCollectionGridTypeDescriptor extends AbstractGeoJsonObjectGridTypeDescriptor { 17 | 18 | public static final GeoCollectionGridTypeDescriptor INSTANCE = new GeoCollectionGridTypeDescriptor(); 19 | 20 | protected GeoCollectionGridTypeDescriptor() { 21 | super( GeoCollection.class, GeoCollection::fromDocument ); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /mongodb/src/main/java/org/hibernate/ogm/datastore/mongodb/type/impl/GeoCollectionTypeDescriptor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.type.impl; 8 | 9 | import org.hibernate.ogm.datastore.mongodb.type.GeoCollection; 10 | 11 | /** 12 | * Persists {@link GeoCollection} in the format expected by MongoDB. 13 | * 14 | * @author Aleksandr Mylnikov 15 | */ 16 | public class GeoCollectionTypeDescriptor extends AbstractGeoJsonObjectTypeDescriptor { 17 | 18 | public static final GeoCollectionTypeDescriptor INSTANCE = new GeoCollectionTypeDescriptor(); 19 | 20 | protected GeoCollectionTypeDescriptor() { 21 | super( GeoCollection.class ); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /mongodb/src/main/java/org/hibernate/ogm/datastore/mongodb/type/impl/GeoLineStringGridTypeDescriptor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.type.impl; 8 | 9 | import org.hibernate.ogm.datastore.mongodb.type.GeoLineString; 10 | 11 | /** 12 | * Persists {@link GeoLineString} in the format expected by MongoDB. 13 | * 14 | * @author Guillaume Smet 15 | */ 16 | public class GeoLineStringGridTypeDescriptor extends AbstractGeoJsonObjectGridTypeDescriptor { 17 | 18 | public static final GeoLineStringGridTypeDescriptor INSTANCE = new GeoLineStringGridTypeDescriptor(); 19 | 20 | private GeoLineStringGridTypeDescriptor() { 21 | super( GeoLineString.class, GeoLineString::fromDocument ); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /mongodb/src/main/java/org/hibernate/ogm/datastore/mongodb/type/impl/GeoLineStringTypeDescriptor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.type.impl; 8 | 9 | import org.hibernate.ogm.datastore.mongodb.type.GeoLineString; 10 | 11 | /** 12 | * Persists {@link GeoLineString} in the format expected by MongoDB. 13 | * 14 | * @author Guillaume Smet 15 | */ 16 | public class GeoLineStringTypeDescriptor extends AbstractGeoJsonObjectTypeDescriptor { 17 | 18 | public static final GeoLineStringTypeDescriptor INSTANCE = new GeoLineStringTypeDescriptor(); 19 | 20 | public GeoLineStringTypeDescriptor() { 21 | super( GeoLineString.class ); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /mongodb/src/main/java/org/hibernate/ogm/datastore/mongodb/type/impl/GeoMultiLineStringTypeDescriptor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.type.impl; 8 | 9 | import org.hibernate.ogm.datastore.mongodb.type.GeoMultiLineString; 10 | 11 | /** 12 | * Persists {@link GeoMultiLineString} in the format expected by MongoDB. 13 | * 14 | * @author Guillaume Smet 15 | */ 16 | public class GeoMultiLineStringTypeDescriptor extends AbstractGeoJsonObjectTypeDescriptor { 17 | 18 | public static final GeoMultiLineStringTypeDescriptor INSTANCE = new GeoMultiLineStringTypeDescriptor(); 19 | 20 | public GeoMultiLineStringTypeDescriptor() { 21 | super( GeoMultiLineString.class ); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /mongodb/src/main/java/org/hibernate/ogm/datastore/mongodb/type/impl/GeoMultiPointGridTypeDescriptor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.type.impl; 8 | 9 | import org.hibernate.ogm.datastore.mongodb.type.GeoMultiPoint; 10 | 11 | /** 12 | * Persists {@link GeoMultiPoint} in the format expected by MongoDB. 13 | * 14 | * @author Guillaume Smet 15 | */ 16 | public class GeoMultiPointGridTypeDescriptor extends AbstractGeoJsonObjectGridTypeDescriptor { 17 | 18 | public static final GeoMultiPointGridTypeDescriptor INSTANCE = new GeoMultiPointGridTypeDescriptor(); 19 | 20 | private GeoMultiPointGridTypeDescriptor() { 21 | super( GeoMultiPoint.class, GeoMultiPoint::fromDocument ); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /mongodb/src/main/java/org/hibernate/ogm/datastore/mongodb/type/impl/GeoMultiPointTypeDescriptor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.type.impl; 8 | 9 | import org.hibernate.ogm.datastore.mongodb.type.GeoMultiPoint; 10 | 11 | /** 12 | * Persists {@link GeoMultiPoint} in the format expected by MongoDB. 13 | * 14 | * @author Guillaume Smet 15 | */ 16 | public class GeoMultiPointTypeDescriptor extends AbstractGeoJsonObjectTypeDescriptor { 17 | 18 | public static final GeoMultiPointTypeDescriptor INSTANCE = new GeoMultiPointTypeDescriptor(); 19 | 20 | public GeoMultiPointTypeDescriptor() { 21 | super( GeoMultiPoint.class ); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /mongodb/src/main/java/org/hibernate/ogm/datastore/mongodb/type/impl/GeoMultiPolygonGridTypeDescriptor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.type.impl; 8 | 9 | import org.hibernate.ogm.datastore.mongodb.type.GeoMultiPolygon; 10 | 11 | /** 12 | * Persists {@link GeoMultiPolygon} in the format expected by MongoDB. 13 | * 14 | * @author Guillaume Smet 15 | */ 16 | public class GeoMultiPolygonGridTypeDescriptor extends AbstractGeoJsonObjectGridTypeDescriptor { 17 | 18 | public static final GeoMultiPolygonGridTypeDescriptor INSTANCE = new GeoMultiPolygonGridTypeDescriptor(); 19 | 20 | private GeoMultiPolygonGridTypeDescriptor() { 21 | super( GeoMultiPolygon.class, GeoMultiPolygon::fromDocument ); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /mongodb/src/main/java/org/hibernate/ogm/datastore/mongodb/type/impl/GeoMultiPolygonTypeDescriptor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.type.impl; 8 | 9 | import org.hibernate.ogm.datastore.mongodb.type.GeoMultiPolygon; 10 | 11 | /** 12 | * Persists {@link GeoMultiPolygon} in the format expected by MongoDB. 13 | * 14 | * @author Guillaume Smet 15 | */ 16 | public class GeoMultiPolygonTypeDescriptor extends AbstractGeoJsonObjectTypeDescriptor { 17 | 18 | public static final GeoMultiPolygonTypeDescriptor INSTANCE = new GeoMultiPolygonTypeDescriptor(); 19 | 20 | public GeoMultiPolygonTypeDescriptor() { 21 | super( GeoMultiPolygon.class ); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /mongodb/src/main/java/org/hibernate/ogm/datastore/mongodb/type/impl/GeoPointGridTypeDescriptor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.type.impl; 8 | 9 | import org.hibernate.ogm.datastore.mongodb.type.GeoPoint; 10 | 11 | /** 12 | * Persists {@link GeoPoint} in the format expected by MongoDB. 13 | * 14 | * @author Guillaume Smet 15 | */ 16 | public class GeoPointGridTypeDescriptor extends AbstractGeoJsonObjectGridTypeDescriptor { 17 | 18 | public static final GeoPointGridTypeDescriptor INSTANCE = new GeoPointGridTypeDescriptor(); 19 | 20 | private GeoPointGridTypeDescriptor() { 21 | super( GeoPoint.class, GeoPoint::fromDocument ); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /mongodb/src/main/java/org/hibernate/ogm/datastore/mongodb/type/impl/GeoPointTypeDescriptor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.type.impl; 8 | 9 | import org.hibernate.ogm.datastore.mongodb.type.GeoPoint; 10 | 11 | /** 12 | * Persists {@link GeoPoint} in the format expected by MongoDB. 13 | * 14 | * @author Guillaume Smet 15 | */ 16 | public class GeoPointTypeDescriptor extends AbstractGeoJsonObjectTypeDescriptor { 17 | 18 | public static final GeoPointTypeDescriptor INSTANCE = new GeoPointTypeDescriptor(); 19 | 20 | public GeoPointTypeDescriptor() { 21 | super( GeoPoint.class ); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /mongodb/src/main/java/org/hibernate/ogm/datastore/mongodb/type/impl/GeoPolygonGridTypeDescriptor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.type.impl; 8 | 9 | import org.hibernate.ogm.datastore.mongodb.type.GeoPolygon; 10 | 11 | /** 12 | * Persists {@link GeoPolygon} in the format expected by MongoDB. 13 | * 14 | * @author Guillaume Smet 15 | */ 16 | public class GeoPolygonGridTypeDescriptor extends AbstractGeoJsonObjectGridTypeDescriptor { 17 | 18 | public static final GeoPolygonGridTypeDescriptor INSTANCE = new GeoPolygonGridTypeDescriptor(); 19 | 20 | private GeoPolygonGridTypeDescriptor() { 21 | super( GeoPolygon.class, GeoPolygon::fromDocument ); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /mongodb/src/main/java/org/hibernate/ogm/datastore/mongodb/type/impl/GeoPolygonTypeDescriptor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.type.impl; 8 | 9 | import org.hibernate.ogm.datastore.mongodb.type.GeoPolygon; 10 | 11 | /** 12 | * Persists {@link GeoPolygon} in the format expected by MongoDB. 13 | * 14 | * @author Guillaume Smet 15 | */ 16 | public class GeoPolygonTypeDescriptor extends AbstractGeoJsonObjectTypeDescriptor { 17 | 18 | public static final GeoPolygonTypeDescriptor INSTANCE = new GeoPolygonTypeDescriptor(); 19 | 20 | public GeoPolygonTypeDescriptor() { 21 | super( GeoPolygon.class ); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /mongodb/src/main/resources/META-INF/services/org.hibernate.boot.model.TypeContributor: -------------------------------------------------------------------------------- 1 | # 2 | # Hibernate OGM, Domain model persistence for NoSQL datastores 3 | # 4 | # License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | # See the lgpl.txt file in the root directory or . 6 | # 7 | 8 | org.hibernate.ogm.datastore.mongodb.type.impl.MongoDBTypeContributor 9 | -------------------------------------------------------------------------------- /mongodb/src/test/java/org/hibernate/ogm/datastore/mongodb/test/inheritance/singletable/SimpleNode.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.test.inheritance.singletable; 8 | 9 | import javax.persistence.Entity; 10 | 11 | @Entity 12 | public class SimpleNode extends Node { 13 | 14 | public SimpleNode() { 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /mongodb/src/test/java/org/hibernate/ogm/datastore/mongodb/test/inheritance/singletable/TextNode.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.test.inheritance.singletable; 8 | 9 | import javax.persistence.Entity; 10 | 11 | @Entity 12 | public class TextNode extends Node { 13 | 14 | private String text; 15 | 16 | public TextNode() { 17 | } 18 | 19 | public String getText() { 20 | return text; 21 | } 22 | 23 | public void setText(String text) { 24 | this.text = text; 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /mongodb/src/test/java/org/hibernate/ogm/datastore/mongodb/test/inheritance/tableperclass/SimpleNode.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.test.inheritance.tableperclass; 8 | 9 | import javax.persistence.Entity; 10 | 11 | @Entity 12 | public class SimpleNode extends Node { 13 | 14 | public SimpleNode() { 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /mongodb/src/test/java/org/hibernate/ogm/datastore/mongodb/test/inheritance/tableperclass/TextNode.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.test.inheritance.tableperclass; 8 | 9 | import javax.persistence.Entity; 10 | 11 | @Entity 12 | public class TextNode extends Node { 13 | 14 | private String text; 15 | 16 | public TextNode() { 17 | } 18 | 19 | public String getText() { 20 | return text; 21 | } 22 | 23 | public void setText(String text) { 24 | this.text = text; 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /mongodb/src/test/java/org/hibernate/ogm/datastore/mongodb/test/query/parsing/model/inheritance/singletable/CommunityMemberST.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.test.query.parsing.model.inheritance.singletable; 8 | 9 | import javax.persistence.DiscriminatorValue; 10 | import javax.persistence.Entity; 11 | 12 | /** 13 | * @author Davide D'Alto 14 | */ 15 | @Entity 16 | @DiscriminatorValue("CMM") 17 | public class CommunityMemberST extends PersonST { 18 | 19 | private String project; 20 | 21 | public String getProject() { 22 | return project; 23 | } 24 | 25 | public void setProject(String project) { 26 | this.project = project; 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /mongodb/src/test/java/org/hibernate/ogm/datastore/mongodb/test/query/parsing/model/inheritance/singletable/EmployeeST.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.test.query.parsing.model.inheritance.singletable; 8 | 9 | import javax.persistence.DiscriminatorValue; 10 | import javax.persistence.Entity; 11 | 12 | /** 13 | * @author Davide D'Alto 14 | */ 15 | @Entity 16 | @DiscriminatorValue("EMP") 17 | public class EmployeeST extends CommunityMemberST { 18 | 19 | private String employer; 20 | 21 | public String getEmployer() { 22 | return employer; 23 | } 24 | 25 | public void setEmployer(String employer) { 26 | this.employer = employer; 27 | } 28 | 29 | } 30 | -------------------------------------------------------------------------------- /mongodb/src/test/java/org/hibernate/ogm/datastore/mongodb/utils/MongoDBBackendTckHelper.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.mongodb.utils; 8 | 9 | import org.junit.extensions.cpsuite.ClasspathSuite; 10 | import org.junit.runner.RunWith; 11 | 12 | /** 13 | * Helper class allowing you to run all or any specified subset of test available on the classpath. 14 | * 15 | * This method is for example useful to run all or parts of the backendtck. 16 | * 17 | * @author Hardy Ferentschik 18 | */ 19 | @RunWith(ClasspathSuite.class) 20 | @ClasspathSuite.ClassnameFilters({ "org.hibernate.ogm.backendtck.*" }) 21 | //@ClasspathSuite.ClassnameFilters({ ".*BuiltInTypeTest" }) 22 | public class MongoDBBackendTckHelper { 23 | } 24 | -------------------------------------------------------------------------------- /mongodb/src/test/resources/hibernate.properties: -------------------------------------------------------------------------------- 1 | # 2 | # Hibernate OGM, Domain model persistence for NoSQL datastores 3 | # 4 | # License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | # See the lgpl.txt file in the root directory or . 6 | # 7 | 8 | hibernate.ogm.datastore.provider = ${datastoreProvider} 9 | hibernate.ogm.datastore.database = ogm_test_database 10 | hibernate.ogm.datastore.create_database=true 11 | 12 | hibernate.ogm.mongodb.connection_timeout = 1000 13 | -------------------------------------------------------------------------------- /mongodb/src/test/resources/log4j.properties: -------------------------------------------------------------------------------- 1 | # 2 | # Hibernate OGM, Domain model persistence for NoSQL datastores 3 | # 4 | # License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | # See the lgpl.txt file in the root directory or . 6 | # 7 | 8 | log4j.appender.stdout=org.apache.log4j.ConsoleAppender 9 | log4j.appender.stdout.Target=System.out 10 | log4j.appender.stdout.layout=org.apache.log4j.PatternLayout 11 | log4j.appender.stdout.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L - %m%n 12 | 13 | log4j.rootLogger=trace, stdout 14 | 15 | log4j.logger.org.hibernate=trace 16 | -------------------------------------------------------------------------------- /neo4j/src/main/java/org/hibernate/ogm/datastore/neo4j/Neo4jDialect.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.neo4j; 8 | 9 | import org.hibernate.ogm.datastore.neo4j.embedded.impl.EmbeddedNeo4jDatastoreProvider; 10 | 11 | /** 12 | * Equivalent to {@link EmbeddedNeo4jDialect}. 13 | * 14 | * @deprecated Use {@link EmbeddedNeo4jDialect} instead 15 | * @author Davide D'Alto 16 | */ 17 | @Deprecated 18 | public class Neo4jDialect extends EmbeddedNeo4jDialect { 19 | 20 | public Neo4jDialect(EmbeddedNeo4jDatastoreProvider provider) { 21 | super( provider ); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /neo4j/src/main/java/org/hibernate/ogm/datastore/neo4j/RemoteNeo4jDialect.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.neo4j; 8 | 9 | import org.hibernate.ogm.dialect.spi.GridDialect; 10 | 11 | /** 12 | * Flag a Neo4j {@link GridDialect} as remote. 13 | * 14 | * @author Davide D'Alto 15 | */ 16 | public interface RemoteNeo4jDialect extends GridDialect { 17 | 18 | } 19 | -------------------------------------------------------------------------------- /neo4j/src/main/java/org/hibernate/ogm/datastore/neo4j/dialect/impl/NodeLabel.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.neo4j.dialect.impl; 8 | 9 | import org.neo4j.graphdb.Label; 10 | 11 | /** 12 | * Identifies the role of the node created by the neo4j dialect. 13 | * 14 | * @author Davide D'Alto <davide@hibernate.org> 15 | */ 16 | public enum NodeLabel implements Label { 17 | /** 18 | * A node mapping an entity 19 | */ 20 | ENTITY, 21 | 22 | /** 23 | * Represents an embedded (dependent) entity. 24 | */ 25 | EMBEDDED, 26 | 27 | /** 28 | * A node representing a sequence. 29 | */ 30 | SEQUENCE, 31 | 32 | /** 33 | * A node representing a table-based sequence. 34 | */ 35 | TABLE_BASED_SEQUENCE; 36 | } 37 | -------------------------------------------------------------------------------- /neo4j/src/main/java/org/hibernate/ogm/datastore/neo4j/embedded/dialect/impl/EmbeddedNeo4jTypeConverter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.neo4j.embedded.dialect.impl; 8 | 9 | import org.hibernate.ogm.datastore.neo4j.dialect.impl.BaseNeo4jTypeConverter; 10 | 11 | /** 12 | * A type {@link BaseNeo4jTypeConverter} for embedded Neo4j. 13 | * 14 | * @author Davide D'Alto 15 | */ 16 | public class EmbeddedNeo4jTypeConverter extends BaseNeo4jTypeConverter { 17 | 18 | public static final EmbeddedNeo4jTypeConverter INSTANCE = new EmbeddedNeo4jTypeConverter(); 19 | 20 | private EmbeddedNeo4jTypeConverter() { 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /neo4j/src/main/java/org/hibernate/ogm/datastore/neo4j/query/parsing/impl/Neo4jQueryParameter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.neo4j.query.parsing.impl; 8 | 9 | 10 | /** 11 | * @author Gunnar Morling 12 | * 13 | */ 14 | public class Neo4jQueryParameter { 15 | 16 | private final String name; 17 | 18 | public Neo4jQueryParameter(String name) { 19 | this.name = name; 20 | } 21 | 22 | @Override 23 | public String toString() { 24 | return "{" + name + "}"; 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /neo4j/src/main/java/org/hibernate/ogm/datastore/neo4j/query/parsing/impl/predicate/impl/Neo4jRootPredicate.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.neo4j.query.parsing.impl.predicate.impl; 8 | 9 | import org.hibernate.hql.ast.spi.predicate.RootPredicate; 10 | 11 | /** 12 | * @author Davide D'Alto <davide@hibernate.org> 13 | */ 14 | public class Neo4jRootPredicate extends RootPredicate { 15 | 16 | @Override 17 | public StringBuilder getQuery() { 18 | if ( child == null ) { 19 | return null; 20 | } 21 | else { 22 | return child.getQuery(); 23 | } 24 | } 25 | 26 | } 27 | -------------------------------------------------------------------------------- /neo4j/src/test/java/org/hibernate/ogm/datastore/neo4j/test/query/parsing/model/inheritance/CommunityMemberST.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.neo4j.test.query.parsing.model.inheritance; 8 | 9 | import javax.persistence.DiscriminatorValue; 10 | import javax.persistence.Entity; 11 | 12 | /** 13 | * @author Davide D'Alto 14 | */ 15 | @Entity 16 | @DiscriminatorValue("CMM") 17 | public class CommunityMemberST extends PersonST { 18 | 19 | private String project; 20 | 21 | public String getProject() { 22 | return project; 23 | } 24 | 25 | public void setProject(String project) { 26 | this.project = project; 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /neo4j/src/test/java/org/hibernate/ogm/datastore/neo4j/test/query/parsing/model/inheritance/EmployeeST.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.neo4j.test.query.parsing.model.inheritance; 8 | 9 | import javax.persistence.DiscriminatorValue; 10 | import javax.persistence.Entity; 11 | 12 | /** 13 | * @author Davide D'Alto 14 | */ 15 | @Entity 16 | @DiscriminatorValue("EMP") 17 | public class EmployeeST extends CommunityMemberST { 18 | 19 | private String employer; 20 | 21 | public String getEmployer() { 22 | return employer; 23 | } 24 | 25 | public void setEmployer(String employer) { 26 | this.employer = employer; 27 | } 28 | 29 | } 30 | -------------------------------------------------------------------------------- /neo4j/src/test/java/org/hibernate/ogm/datastore/neo4j/test/util/ExceptionHelper.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | 8 | package org.hibernate.ogm.datastore.neo4j.test.util; 9 | 10 | /** 11 | * @author The Viet Nguyen 12 | */ 13 | public class ExceptionHelper { 14 | 15 | private ExceptionHelper() { 16 | // util class 17 | } 18 | 19 | public static T extract(Class class1, Exception e) throws Throwable { 20 | Throwable cause = e; 21 | while ( cause != null ) { 22 | if ( cause.getClass().equals( class1 ) ) { 23 | break; 24 | } 25 | cause = cause.getCause(); 26 | } 27 | if ( cause == null ) { 28 | throw e; 29 | } 30 | throw cause; 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /neo4j/src/test/java/org/hibernate/ogm/datastore/neo4j/utils/Neo4JBackendTckHelper.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.neo4j.utils; 8 | 9 | import org.junit.extensions.cpsuite.ClasspathSuite; 10 | import org.junit.runner.RunWith; 11 | 12 | /** 13 | * Helper class allowing you to run all or any specified subset of test available on the classpath. 14 | * 15 | * This method is for example useful to run all or parts of the backendtck. 16 | * 17 | * @author Hardy Ferentschik 18 | */ 19 | @RunWith(ClasspathSuite.class) 20 | //@ClasspathSuite.ClassnameFilters({ "org.hibernate.ogm.backendtck.*" }) 21 | @ClasspathSuite.ClassnameFilters({ ".*CompositeEmbeddedIdTest" }) 22 | public class Neo4JBackendTckHelper { 23 | } 24 | -------------------------------------------------------------------------------- /neo4j/src/test/java/org/hibernate/ogm/datastore/neo4j/utils/NotUniqueException.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Hibernate OGM, Domain model persistence for NoSQL datastores 3 | * 4 | * License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | * See the lgpl.txt file in the root directory or . 6 | */ 7 | package org.hibernate.ogm.datastore.neo4j.utils; 8 | 9 | import org.hibernate.HibernateException; 10 | 11 | /** 12 | * A generic exception that can be used when a query should return a single result. 13 | *

14 | * It is supposed to be used by the queries that are checking that the mapping is correct. 15 | * 16 | * @author Davide D'Alto 17 | */ 18 | public class NotUniqueException extends HibernateException { 19 | 20 | public NotUniqueException() { 21 | super( "Expected unique result" ); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /neo4j/src/test/resources/hibernate.properties: -------------------------------------------------------------------------------- 1 | # 2 | # Hibernate OGM, Domain model persistence for NoSQL datastores 3 | # 4 | # License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | # See the lgpl.txt file in the root directory or . 6 | # 7 | 8 | hibernate.ogm.datastore.provider = ${datastoreProvider} 9 | 10 | # Only for embedded 11 | hibernate.ogm.neo4j.database_path = ${project.build.directory}/neo4jdb/ 12 | 13 | # Neo4j configuration file 14 | hibernate.ogm.neo4j.configuration_resource_name = ${project.basedir}/src/test/resources/neo4j.conf 15 | -------------------------------------------------------------------------------- /neo4j/src/test/resources/log4j.properties: -------------------------------------------------------------------------------- 1 | # 2 | # Hibernate OGM, Domain model persistence for NoSQL datastores 3 | # 4 | # License: GNU Lesser General Public License (LGPL), version 2.1 or later 5 | # See the lgpl.txt file in the root directory or . 6 | # 7 | 8 | log4j.appender.stdout=org.apache.log4j.ConsoleAppender 9 | log4j.appender.stdout.Target=System.out 10 | log4j.appender.stdout.layout=org.apache.log4j.PatternLayout 11 | log4j.appender.stdout.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L - %m%n 12 | 13 | log4j.rootLogger=debug, stdout 14 | 15 | log4j.logger.org.hibernate=debug 16 | -------------------------------------------------------------------------------- /neo4j/src/test/resources/neo4j-embedded-test.properties: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hibernate/hibernate-ogm/87363d69ff105eabbbfd51f0cc6c95904d0d222a/neo4j/src/test/resources/neo4j-embedded-test.properties -------------------------------------------------------------------------------- /neo4j/src/test/resources/neo4j.conf: -------------------------------------------------------------------------------- 1 | # Max size of the page cache file 2 | # see https://neo4j.com/docs/operations-manual/current/performance/ 3 | 4 | dbms.memory.pagecache.size=128M 5 | -------------------------------------------------------------------------------- /performance/src/main/resources/native-settings.properties: -------------------------------------------------------------------------------- 1 | database=perf_test_native_api 2 | host=127.0.0.1 3 | -------------------------------------------------------------------------------- /src/main/release-scripts/Gemfile: -------------------------------------------------------------------------------- 1 | source 'http://rubygems.org' 2 | 3 | gem 'choice' 4 | gem 'git' 5 | gem 'json' 6 | -------------------------------------------------------------------------------- /src/main/release-scripts/Gemfile.lock: -------------------------------------------------------------------------------- 1 | GEM 2 | remote: http://rubygems.org/ 3 | specs: 4 | choice (0.2.0) 5 | git (1.2.9.1) 6 | json (1.8.2) 7 | 8 | PLATFORMS 9 | java 10 | ruby 11 | 12 | DEPENDENCIES 13 | choice 14 | git 15 | json 16 | 17 | BUNDLED WITH 18 | 1.11.2 19 | -------------------------------------------------------------------------------- /src/main/release-scripts/create-tag.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | RELEASE_VERSION=$1 4 | 5 | git commit -a -m "[Jenkins release job] Preparing release $RELEASE_VERSION" 6 | git tag $RELEASE_VERSION 7 | 8 | -------------------------------------------------------------------------------- /src/main/release-scripts/deploy.sh: -------------------------------------------------------------------------------- 1 | mvn clean deploy -s $HOME/.m2/settings-search-release.xml -DskipTests=true -Dcheckstyle.skip=true -Dmaven.compiler.useIncrementalCompilation=false -DmongodbProvider=external 2 | -------------------------------------------------------------------------------- /src/main/release-scripts/prepare-release.sh: -------------------------------------------------------------------------------- 1 | 2 | RELEASE_VERSION=$1 3 | WORKSPACE=${WORKSPACE:-'.'} 4 | 5 | if [ -z "$RELEASE_VERSION" ]; 6 | then 7 | echo "ERROR: Release version argument not supplied" 8 | exit 1 9 | else 10 | echo "Setting version to '$RELEASE_VERSION'"; 11 | fi 12 | 13 | echo "Preparing the release ..." 14 | 15 | pushd $WORKSPACE/src/main/release-scripts 16 | bundle install 17 | ./pre-release.rb -v $RELEASE_VERSION -r $WORKSPACE/README.md -c $WORKSPACE/changelog.txt 18 | sh validate-release.sh $RELEASE_VERSION 19 | sh update-version.sh $RELEASE_VERSION 20 | sh create-tag.sh $RELEASE_VERSION 21 | popd 22 | 23 | echo "Release ready: version is updated to $RELEASE_VERSION" 24 | -------------------------------------------------------------------------------- /src/main/release-scripts/push-upstream.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | RELEASE_VERSION=$1 4 | BRANCH=$2 5 | PUSH_CHANGES=${3:-false} 6 | 7 | if [ -z "$RELEASE_VERSION" ] 8 | then 9 | echo "Release version not supplied" 10 | exit 1 11 | fi 12 | 13 | if [ -z "$BRANCH" ] 14 | then 15 | echo "Branch not supplied" 16 | exit 1 17 | fi 18 | 19 | git commit -a -m "[Jenkins release job] Preparing next development iteration" 20 | 21 | if [ "$PUSH_CHANGES" = true ] ; then 22 | echo "Pushing changes to the upstream repository." 23 | git push origin $BRANCH 24 | git push origin $RELEASE_VERSION 25 | fi 26 | if [ "$PUSH_CHANGES" != true ] ; then 27 | echo "WARNING: Not pushing changes to the upstream repository." 28 | fi 29 | -------------------------------------------------------------------------------- /src/main/release-scripts/update-version.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | NEW_VERSION=$1 4 | WORKSPACE=${WORKSPACE:-'.'} 5 | 6 | if [ -z "$NEW_VERSION" ]; 7 | then 8 | echo "ERROR: New version argument not supplied" 9 | exit 1 10 | else 11 | echo "Setting version to '$NEW_VERSION'"; 12 | fi 13 | 14 | pushd $WORKSPACE 15 | mvn clean versions:set -DnewVersion=$NEW_VERSION -DgenerateBackupPoms=false -f bom/pom.xml 16 | popd 17 | -------------------------------------------------------------------------------- /src/main/release-scripts/validate-release.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | RELEASE_VERSION=$1 4 | WORKSPACE=${WORKSPACE:-'.'} 5 | CHANGELOG=$WORKSPACE/changelog.txt 6 | README=$WORKSPACE/README.md 7 | 8 | git fetch --tags 9 | 10 | if [ `git tag -l | grep $RELEASE_VERSION` ] 11 | then 12 | echo "ERROR: tag '$RELEASE_VERSION' already exists, aborting. If you really want to release this version, delete the tag in the workspace first." 13 | exit 1 14 | else 15 | echo "SUCCESS: tag '$RELEASE_VERSION' does not exist" 16 | fi 17 | 18 | if grep -q "$RELEASE_VERSION" $README ; 19 | then 20 | echo "SUCCESS: $README looks updated" 21 | else 22 | echo "ERROR: $README has not been updated" 23 | exit 1 24 | fi 25 | 26 | if grep -q "$RELEASE_VERSION" $CHANGELOG ; 27 | then 28 | echo "SUCCESS: $CHANGELOG looks updated" 29 | else 30 | echo "ERROR: $CHANGELOG has not been updated" 31 | exit 1 32 | fi 33 | --------------------------------------------------------------------------------