Skip to content
Snippets Groups Projects
Unverified Commit b423eff4 authored by Martin Weise's avatar Martin Weise
Browse files

Identifier ID still null, idk why

parent e30d0185
No related branches found
No related tags found
2 merge requests!81New stable release,!80Multiple features connected with user management and ownership of databases
Showing
with 175 additions and 115 deletions
......@@ -86,6 +86,8 @@ services:
fda-userdb:
fda-public:
environment:
GATEWAY_ENDPOINT: http://fda-gateway-service:9095
SEARCH_ENDPOINT: fda-search-service:9200
SPRING_PROFILES_ACTIVE: docker
TZ: Europe/Vienna
ports:
......@@ -111,6 +113,7 @@ services:
networks:
fda-public:
environment:
GATEWAY_ENDPOINT: http://fda-gateway-service:9095
SPRING_PROFILES_ACTIVE: docker
TZ: Europe/Vienna
ports:
......@@ -132,8 +135,6 @@ services:
networks:
fda-public:
environment:
TOKEN: ${INVENIO_TOKEN}
REFERER: https://dbrepo.ossdip.at
DOCUMENT_ENDPOINT: https://test.researchdata.tuwien.ac.at
GATEWAY_ENDPOINT: http://fda-gateway-service:9095
SPRING_PROFILES_ACTIVE: docker
......@@ -207,8 +208,9 @@ services:
fda-public:
fda-userdb:
environment:
GATEWAY_ENDPOINT: http://fda-gateway-service:9095
SEARCH_ENDPOINT: fda-search-service:9200
SPRING_PROFILES_ACTIVE: docker
SYSTEM_PASSWORD: ${ADMIN_PASSWORD:-admin}
multipart.location: /tmp
TZ: Europe/Vienna
ports:
......@@ -235,6 +237,7 @@ services:
networks:
fda-public:
environment:
GATEWAY_ENDPOINT: http://fda-gateway-service:9095
SPRING_PROFILES_ACTIVE: docker
TZ: Europe/Vienna
ports:
......
......@@ -29,4 +29,4 @@ eureka:
fda:
mount.path: /tmp
ready.path: /ready
gateway.endpoint: http://fda-gateway-service:9095
\ No newline at end of file
gateway.endpoint: "${GATEWAY_ENDPOINT}"
\ No newline at end of file
......@@ -30,4 +30,4 @@ eureka:
fda:
mount.path: /tmp
ready.path: ./ready
gateway.endpoint: http://localhost:9095
\ No newline at end of file
gateway.endpoint: "${GATEWAY_ENDPOINT}"
\ No newline at end of file
......@@ -32,6 +32,6 @@ eureka:
instance.hostname: fda-database-service
client.serviceUrl.defaultZone: http://fda-discovery-service:9090/eureka/
fda:
elastic.endpoint: fda-search-service:9200
elastic.endpoint: "${SEARCH_ENDPOINT}"
ready.path: /ready
gateway.endpoint: http://fda-gateway-service:9095
\ No newline at end of file
gateway.endpoint: "${GATEWAY_ENDPOINT}"
\ No newline at end of file
......@@ -31,6 +31,6 @@ eureka:
instance.hostname: fda-database-service
client.serviceUrl.defaultZone: http://localhost:9090/eureka/
fda:
elastic.endpoint: localhost:9200
elastic.endpoint: "${SEARCH_ENDPOINT}"
ready.path: ./ready
gateway.endpoint: http://fda-gateway-service:9095
\ No newline at end of file
gateway.endpoint: "${GATEWAY_ENDPOINT}"
\ No newline at end of file
......@@ -7,7 +7,6 @@ target/
### Generated ###
ready
service_ready
### STS ###
.apt_generated
......
......@@ -35,4 +35,4 @@ fda:
mount.path: /tmp
ready.path: /ready
gateway.endpoint: "${GATEWAY_ENDPOINT}"
document.endpoint: https://test.researchdata.tuwien.ac.at
\ No newline at end of file
document.endpoint: "${DOCUMENT_ENDPOINT}"
\ No newline at end of file
......@@ -35,4 +35,4 @@ fda:
mount.path: /tmp
ready.path: ./ready
gateway.endpoint: "${GATEWAY_ENDPOINT}"
document.endpoint: https://test.researchdata.tuwien.ac.at
\ No newline at end of file
document.endpoint: "${DOCUMENT_ENDPOINT}"
\ No newline at end of file
......@@ -29,4 +29,4 @@ eureka:
client.serviceUrl.defaultZone: http://fda-discovery-service:9090/eureka/
fda:
ready.path: /ready
gateway.endpoint: http://fda-gateway-service:9095
\ No newline at end of file
gateway.endpoint: "${GATEWAY_ENDPOINT}"
\ No newline at end of file
......@@ -29,4 +29,4 @@ eureka:
client.serviceUrl.defaultZone: http://localhost:9090/eureka/
fda:
ready.path: ~/
gateway.endpoint: http://fda-gateway-service:9095
\ No newline at end of file
gateway.endpoint: "${GATEWAY_ENDPOINT}"
\ No newline at end of file
......@@ -25,10 +25,14 @@ public abstract class BaseUnitTest {
public final static String USER_1_USERNAME = "junit";
public final static String USER_1_PASSWORD = "junit";
public final static String USER_1_EMAIL = "junit@example.com";
public final static Boolean USER_1_EMAIL_VERIFIED = true;
public final static User USER_1 = User.builder()
.username(USER_1_USERNAME)
.password(USER_1_PASSWORD)
.email(USER_1_EMAIL)
.emailVerified(USER_1_EMAIL_VERIFIED)
.build();
public final static Long DATABASE_1_ID = 1L;
......@@ -56,20 +60,13 @@ public abstract class BaseUnitTest {
public final static Instant CREATOR_1_CREATED = Instant.ofEpochSecond(1641588352);
public final static Instant CREATOR_1_MODIFIED = Instant.ofEpochSecond(1541588352);
public final static Creator CREATOR_1 = Creator.builder()
.id(CREATOR_1_ID)
.orcid(CREATOR_1_ORCID)
.name(CREATOR_1_NAME)
.created(CREATOR_1_CREATED)
.lastModified(CREATOR_1_MODIFIED)
.build();
public final static Creator CREATOR_1_REQUEST = Creator.builder()
.orcid(CREATOR_1_ORCID)
.name(CREATOR_1_NAME)
.created(CREATOR_1_CREATED)
.lastModified(CREATOR_1_MODIFIED)
.build();
public final static Long CREATOR_3_ID = 3L;
public final static Long CREATOR_3_QUERY_ID = 1L;
public final static String CREATOR_3_ORCID = "00000-00000-00000";
public final static String CREATOR_3_AFFIL = "TU Graz";
public final static String CREATOR_3_NAME = "Mustermann, Max";
public final static Instant CREATOR_3_CREATED = Instant.ofEpochSecond(1641588352);
public final static Instant CREATOR_3_MODIFIED = Instant.ofEpochSecond(1541588352);
public final static Long CREATOR_2_ID = 2L;
public final static Long CREATOR_2_QUERY_ID = 1L;
......@@ -79,46 +76,13 @@ public abstract class BaseUnitTest {
public final static Instant CREATOR_2_CREATED = Instant.ofEpochSecond(1641588352);
public final static Instant CREATOR_2_MODIFIED = Instant.ofEpochSecond(1541588352);
public final static Creator CREATOR_2 = Creator.builder()
.id(CREATOR_2_ID)
.orcid(CREATOR_2_ORCID)
.name(CREATOR_2_NAME)
.created(CREATOR_2_CREATED)
.lastModified(CREATOR_2_MODIFIED)
.build();
public final static Creator CREATOR_2_REQUEST = Creator.builder()
.orcid(CREATOR_2_ORCID)
.name(CREATOR_2_NAME)
.created(CREATOR_2_CREATED)
.lastModified(CREATOR_2_MODIFIED)
.build();
public final static CreatorDto CREATOR_1_DTO = CreatorDto.builder()
.id(CREATOR_1_ID)
.affiliation(CREATOR_1_AFFIL)
.orcid(CREATOR_1_ORCID)
.name(CREATOR_1_NAME)
.build();
public final static CreatorCreateDto CREATOR_1_CREATE_DTO = CreatorCreateDto.builder()
.affiliation(CREATOR_1_AFFIL)
.orcid(CREATOR_1_ORCID)
.name(CREATOR_1_NAME)
.build();
public final static CreatorDto CREATOR_2_DTO = CreatorDto.builder()
.id(CREATOR_2_ID)
.affiliation(CREATOR_2_AFFIL)
.orcid(CREATOR_2_ORCID)
.name(CREATOR_2_NAME)
.build();
public final static CreatorCreateDto CREATOR_2_CREATE_DTO = CreatorCreateDto.builder()
.affiliation(CREATOR_2_AFFIL)
.orcid(CREATOR_2_ORCID)
.name(CREATOR_2_NAME)
.build();
public final static Long CREATOR_4_ID = 4L;
public final static Long CREATOR_4_QUERY_ID = 1L;
public final static String CREATOR_4_ORCID = "00000-00000-00000";
public final static String CREATOR_4_AFFIL = "TU Wien";
public final static String CREATOR_4_NAME = "Mustermann, Martina";
public final static Instant CREATOR_4_CREATED = Instant.ofEpochSecond(1641588352);
public final static Instant CREATOR_4_MODIFIED = Instant.ofEpochSecond(1541588352);
public final static Long IMAGE_1_ID = 1L;
public final static String IMAGE_1_REPOSITORY = "postgres";
......@@ -225,9 +189,11 @@ public abstract class BaseUnitTest {
public final static Long QUERY_1_CONTAINER_ID = CONTAINER_1_ID;
public final static Long QUERY_1_DATABASE_ID = DATABASE_1_ID;
public final static String QUERY_1_STATEMENT = "SELECT * FROM `weather`;";
public final static String QUERY_1_HASH = "ff3f7cbe1b96d296957f6e39e55b8b1b577fa3d205d4795af99594cfd20cb80d";
public final static String QUERY_1_RESULT_HASH = "ff3f7cbe1b96d296957f6e39e55b8b1b577fa3d205d4795af99594cfd20cb80d";
public final static Long QUERY_1_RESULT_NUMBER = 9L;
public final static Instant QUERY_1_CREATED = Instant.ofEpochSecond(1641588352);
public final static Instant QUERY_1_EXECUTED = Instant.ofEpochSecond(1641588352);
public final static Instant QUERY_1_LAST_MODIFIED = Instant.ofEpochSecond(1541588352);
public final static QueryDto QUERY_1_DTO = QueryDto.builder()
......@@ -240,15 +206,19 @@ public abstract class BaseUnitTest {
.resultHash(QUERY_1_RESULT_HASH)
.lastModified(QUERY_1_LAST_MODIFIED)
.created(QUERY_1_CREATED)
.queryHash(QUERY_1_HASH)
.execution(QUERY_1_EXECUTED)
.build();
public final static Long QUERY_2_ID = 2L;
public final static Long QUERY_2_CONTAINER_ID = CONTAINER_2_ID;
public final static Long QUERY_2_DATABASE_ID = DATABASE_2_ID;
public final static String QUERY_2_STATEMENT = "SELECT * FROM `weather`;";
public final static String QUERY_2_HASH = "ff3f7cbe1b96d296957f6e39e55b8b1b577fa3d205d4795af99594cfd20cb80d";
public final static String QUERY_2_RESULT_HASH = "ff3f7cbe1b96d296957f6e39e55b8b1b577fa3d205d4795af99594cfd20cb80d";
public final static Long QUERY_2_RESULT_NUMBER = 5L;
public final static Instant QUERY_2_CREATED = Instant.ofEpochSecond(1641588352);
public final static Instant QUERY_2_EXECUTED = Instant.ofEpochSecond(1641588352);
public final static Instant QUERY_2_LAST_MODIFIED = Instant.ofEpochSecond(1541588352);
public final static QueryDto QUERY_2_DTO = QueryDto.builder()
......@@ -261,6 +231,8 @@ public abstract class BaseUnitTest {
.resultHash(QUERY_2_RESULT_HASH)
.lastModified(QUERY_2_LAST_MODIFIED)
.created(QUERY_2_CREATED)
.queryHash(QUERY_2_HASH)
.execution(QUERY_2_EXECUTED)
.build();
public final static Long IDENTIFIER_1_ID = 1L;
......@@ -269,10 +241,17 @@ public abstract class BaseUnitTest {
public final static String IDENTIFIER_1_DESCRIPTION = "Selecting all from the weather Australia table";
public final static String IDENTIFIER_1_TITLE = "Australia weather data";
public final static String IDENTIFIER_1_DOI = "10.1000/182";
public final static VisibilityType IDENTIFIER_1_VISIBILITY = VisibilityType.SELF;
public final static VisibilityTypeDto IDENTIFIER_1_VISIBILITY_DTO = VisibilityTypeDto.SELF;
public final static VisibilityType IDENTIFIER_1_VISIBILITY = VisibilityType.EVERYONE;
public final static VisibilityTypeDto IDENTIFIER_1_VISIBILITY_DTO = VisibilityTypeDto.EVERYONE;
public final static Instant IDENTIFIER_1_CREATED = Instant.ofEpochSecond(1641588352);
public final static Instant IDENTIFIER_1_MODIFIED = Instant.ofEpochSecond(1541588352);
public final static Instant IDENTIFIER_1_EXECUTION = Instant.ofEpochSecond(1541588352);
public final static Short IDENTIFIER_1_PUBLICATION_YEAR = 2022;
public final static String IDENTIFIER_1_QUERY_HASH = "abc";
public final static String IDENTIFIER_1_RESULT_HASH = "def";
public final static String IDENTIFIER_1_QUERY = "SELECT `id` FROM `foobar`";
public final static String IDENTIFIER_1_NORMALIZED = "SELECT `id` FROM `foobar`";
public final static Long IDENTIFIER_1_RESULT_NUMBER = 2L;
public final static Long IDENTIFIER_2_ID = 2L;
public final static Long IDENTIFIER_2_QUERY_ID = QUERY_2_ID;
......@@ -280,13 +259,22 @@ public abstract class BaseUnitTest {
public final static String IDENTIFIER_2_DESCRIPTION = "Selecting all from the weather Austria table";
public final static String IDENTIFIER_2_TITLE = "Austria weather data";
public final static String IDENTIFIER_2_DOI = "10.1000/183";
public final static VisibilityType IDENTIFIER_2_VISIBILITY = VisibilityType.SELF;
public final static VisibilityTypeDto IDENTIFIER_2_VISIBILITY_DTO = VisibilityTypeDto.SELF;
public final static VisibilityType IDENTIFIER_2_VISIBILITY = VisibilityType.EVERYONE;
public final static VisibilityTypeDto IDENTIFIER_2_VISIBILITY_DTO = VisibilityTypeDto.EVERYONE;
public final static Instant IDENTIFIER_2_CREATED = Instant.ofEpochSecond(1641588352);
public final static Instant IDENTIFIER_2_MODIFIED = Instant.ofEpochSecond(1541588352);
public final static Instant IDENTIFIER_2_EXECUTION = Instant.ofEpochSecond(1541588352);
public final static Short IDENTIFIER_2_PUBLICATION_YEAR = 2022;
public final static String IDENTIFIER_2_QUERY_HASH = "abc";
public final static String IDENTIFIER_2_RESULT_HASH = "def";
public final static String IDENTIFIER_2_QUERY = "SELECT `id` FROM `foobar`";
public final static String IDENTIFIER_2_NORMALIZED = "SELECT `id` FROM `foobar`";
public final static Long IDENTIFIER_2_RESULT_NUMBER = 2L;
public final static Identifier IDENTIFIER_1 = Identifier.builder()
.id(IDENTIFIER_1_ID)
.cid(CONTAINER_1_ID)
.dbid(DATABASE_1_ID)
.qid(IDENTIFIER_1_QUERY_ID)
.dbid(IDENTIFIER_1_DATABASE_ID)
.description(IDENTIFIER_1_DESCRIPTION)
......@@ -295,10 +283,19 @@ public abstract class BaseUnitTest {
.visibility(IDENTIFIER_1_VISIBILITY)
.created(IDENTIFIER_1_CREATED)
.lastModified(IDENTIFIER_1_MODIFIED)
.execution(IDENTIFIER_1_EXECUTION)
.publicationYear(IDENTIFIER_1_PUBLICATION_YEAR)
.queryHash(IDENTIFIER_1_QUERY_HASH)
.resultHash(IDENTIFIER_1_RESULT_HASH)
.query(IDENTIFIER_1_QUERY)
.queryNormalized(IDENTIFIER_1_NORMALIZED)
.resultNumber(IDENTIFIER_1_RESULT_NUMBER)
.build();
public final static Identifier IDENTIFIER_2 = Identifier.builder()
.id(IDENTIFIER_2_ID)
.cid(CONTAINER_2_ID)
.dbid(DATABASE_2_ID)
.qid(IDENTIFIER_2_QUERY_ID)
.dbid(IDENTIFIER_2_DATABASE_ID)
.description(IDENTIFIER_2_DESCRIPTION)
......@@ -307,6 +304,73 @@ public abstract class BaseUnitTest {
.visibility(IDENTIFIER_2_VISIBILITY)
.created(IDENTIFIER_2_CREATED)
.lastModified(IDENTIFIER_2_MODIFIED)
.execution(IDENTIFIER_2_EXECUTION)
.publicationYear(IDENTIFIER_2_PUBLICATION_YEAR)
.queryHash(IDENTIFIER_2_QUERY_HASH)
.resultHash(IDENTIFIER_2_RESULT_HASH)
.query(IDENTIFIER_2_QUERY)
.queryNormalized(IDENTIFIER_2_NORMALIZED)
.resultNumber(IDENTIFIER_2_RESULT_NUMBER)
.build();
public final static Creator CREATOR_1 = Creator.builder()
.id(CREATOR_1_ID)
.pid(IDENTIFIER_1_ID)
.orcid(CREATOR_1_ORCID)
.name(CREATOR_1_NAME)
.created(CREATOR_1_CREATED)
.lastModified(CREATOR_1_MODIFIED)
.build();
public final static Creator CREATOR_1_REQUEST = Creator.builder()
.pid(IDENTIFIER_1_ID)
.orcid(CREATOR_1_ORCID)
.name(CREATOR_1_NAME)
.created(CREATOR_1_CREATED)
.lastModified(CREATOR_1_MODIFIED)
.build();
public final static Creator CREATOR_2 = Creator.builder()
.id(CREATOR_2_ID)
.pid(IDENTIFIER_1_ID)
.orcid(CREATOR_2_ORCID)
.name(CREATOR_2_NAME)
.created(CREATOR_2_CREATED)
.lastModified(CREATOR_2_MODIFIED)
.build();
public final static Creator CREATOR_2_REQUEST = Creator.builder()
.pid(IDENTIFIER_1_ID)
.orcid(CREATOR_2_ORCID)
.name(CREATOR_2_NAME)
.created(CREATOR_2_CREATED)
.lastModified(CREATOR_2_MODIFIED)
.build();
public final static CreatorDto CREATOR_1_DTO = CreatorDto.builder()
.id(CREATOR_1_ID)
.affiliation(CREATOR_1_AFFIL)
.orcid(CREATOR_1_ORCID)
.name(CREATOR_1_NAME)
.build();
public final static CreatorCreateDto CREATOR_1_CREATE_DTO = CreatorCreateDto.builder()
.affiliation(CREATOR_1_AFFIL)
.orcid(CREATOR_1_ORCID)
.name(CREATOR_1_NAME)
.build();
public final static CreatorDto CREATOR_2_DTO = CreatorDto.builder()
.id(CREATOR_2_ID)
.affiliation(CREATOR_2_AFFIL)
.orcid(CREATOR_2_ORCID)
.name(CREATOR_2_NAME)
.build();
public final static CreatorCreateDto CREATOR_2_CREATE_DTO = CreatorCreateDto.builder()
.affiliation(CREATOR_2_AFFIL)
.orcid(CREATOR_2_ORCID)
.name(CREATOR_2_NAME)
.build();
public final static Identifier IDENTIFIER_1_REQUEST = Identifier.builder()
......@@ -340,15 +404,28 @@ public abstract class BaseUnitTest {
.title(IDENTIFIER_1_TITLE)
.doi(IDENTIFIER_1_DOI)
.visibility(IDENTIFIER_1_VISIBILITY_DTO)
.publicationYear(IDENTIFIER_1_PUBLICATION_YEAR)
.creators(List.of(CREATOR_1_CREATE_DTO, CREATOR_2_CREATE_DTO))
.build();
public final static String RELATED_IDENTIFIER_1_VALUE = "10.5281/zenodo.6637333";
public final static RelatedTypeDto RELATED_IDENTIFIER_1_TYPE = RelatedTypeDto.DOI;
public final static RelationTypeDto RELATED_IDENTIFIER_1_RELATION = RelationTypeDto.CITES;
public final static RelatedIdentifierCreateDto RELATED_IDENTIFIER_1_CREATE_DTO = RelatedIdentifierCreateDto.builder()
.value(RELATED_IDENTIFIER_1_VALUE)
.type(RELATED_IDENTIFIER_1_TYPE)
.relation(RELATED_IDENTIFIER_1_RELATION)
.build();
public final static IdentifierCreateDto IDENTIFIER_2_DTO_REQUEST = IdentifierCreateDto.builder()
.qid(IDENTIFIER_2_QUERY_ID)
.description(IDENTIFIER_2_DESCRIPTION)
.title(IDENTIFIER_2_TITLE)
.doi(IDENTIFIER_2_DOI)
.visibility(IDENTIFIER_2_VISIBILITY_DTO)
.relatedIdentifiers(List.of(RELATED_IDENTIFIER_1_CREATE_DTO))
.publicationYear(IDENTIFIER_2_PUBLICATION_YEAR)
.creators(List.of(CREATOR_1_CREATE_DTO, CREATOR_2_CREATE_DTO))
.build();
......
......@@ -6,10 +6,7 @@ import at.tuwien.api.identifier.VisibilityTypeDto;
import at.tuwien.entities.identifier.Identifier;
import at.tuwien.exception.*;
import at.tuwien.gateway.QueryServiceGateway;
import at.tuwien.repository.jpa.ContainerRepository;
import at.tuwien.repository.jpa.CreatorRepository;
import at.tuwien.repository.jpa.DatabaseRepository;
import at.tuwien.repository.jpa.IdentifierRepository;
import at.tuwien.repository.jpa.*;
import at.tuwien.service.impl.IdentifierServiceImpl;
import lombok.extern.log4j.Log4j2;
import org.apache.http.auth.BasicUserPrincipal;
......@@ -57,9 +54,13 @@ public class IdentifierServiceIntegrationTest extends BaseUnitTest {
@MockBean
private QueryServiceGateway queryServiceGateway;
@Autowired
private UserRepository userRepository;
@BeforeEach
@Transactional
public void beforeEach() {
userRepository.save(USER_1);
containerRepository.save(CONTAINER_1);
databaseRepository.save(DATABASE_1);
identifierRepository.save(IDENTIFIER_1);
......@@ -122,6 +123,8 @@ public class IdentifierServiceIntegrationTest extends BaseUnitTest {
assertEquals(IDENTIFIER_2_TITLE, response.getTitle());
assertEquals(IDENTIFIER_2_DESCRIPTION, response.getDescription());
assertEquals(2, response.getCreators().size());
assertEquals(1, response.getRelatedIdentifiers().size());
assertEquals(IDENTIFIER_2_ID, response.getRelatedIdentifiers().get(0).getIdentifier().getId());
}
@Test
......
......@@ -118,7 +118,7 @@ public class IdentifierServiceImpl implements IdentifierService {
.stream()
.map(r -> {
final RelatedIdentifier id = identifierMapper.relatedIdentifierCreateDtoToRelatedIdentifier(r);
id.setIid(entity.getId());
id.setIdentifier(entity);
id.setCreator(creator);
return id;
})
......
......@@ -84,10 +84,7 @@ public class Identifier {
})
private Database database;
@OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.ALL)
@JoinColumns({
@JoinColumn(name = "iid", referencedColumnName = "id")
})
@OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.ALL, mappedBy = "identifier")
private List<RelatedIdentifier> relatedIdentifiers;
@Column(nullable = false, columnDefinition = "enum('EVERYONE', 'TRUSTED', 'SELF')")
......
......@@ -35,9 +35,6 @@ public class RelatedIdentifier {
)
private Long id;
@Column(nullable = false)
private Long iid;
@Column(nullable = false)
private String value;
......@@ -55,6 +52,13 @@ public class RelatedIdentifier {
})
private User creator;
@ToString.Exclude
@ManyToOne(fetch = FetchType.LAZY, cascade = CascadeType.ALL)
@JoinColumns({
@JoinColumn(name = "identifier_id", referencedColumnName = "id")
})
private Identifier identifier;
@Column(nullable = false, updatable = false)
@CreatedDate
private Instant created;
......
......@@ -478,7 +478,7 @@ CREATE TABLE IF NOT EXISTS mdb_identifiers
CREATE TABLE IF NOT EXISTS mdb_related_identifiers
(
id bigint DEFAULT nextval('mdb_related_identifiers_seq'),
iid bigint NOT NULL,
identifier_id bigint NOT NULL,
value text NOT NULL,
type varchar(255),
relation varchar(255),
......@@ -487,7 +487,7 @@ CREATE TABLE IF NOT EXISTS mdb_related_identifiers
last_modified timestamp without time zone,
deleted timestamp without time zone,
PRIMARY KEY (id), /* must be a single id from persistent identifier concept */
FOREIGN KEY (iid) REFERENCES mdb_identifiers (id),
FOREIGN KEY (identifier_id) REFERENCES mdb_identifiers (id),
FOREIGN KEY (created_by) REFERENCES mdb_users (UserID)
);
......
......@@ -35,8 +35,5 @@ eureka:
client.serviceUrl.defaultZone: http://fda-discovery-service:9090/eureka/
fda:
ready.path: /ready
system:
username: system
passwd: "${SYSTEM_PASSWORD}"
gateway.endpoint: http://fda-gateway-service:9095
elastic.endpoint: fda-search-service:9200
\ No newline at end of file
gateway.endpoint: "${GATEWAY_ENDPOINT}"
elastic.endpoint: "${SEARCH_ENDPOINT}"
\ No newline at end of file
......@@ -35,8 +35,5 @@ eureka:
client.serviceUrl.defaultZone: http://localhost:9090/eureka/
fda:
ready.path: ./ready
system:
username: system
passwd: "${SYSTEM_PASSWORD}"
gateway.endpoint: http://localhost:9095
elastic.endpoint: fda-search-service:9200
\ No newline at end of file
gateway.endpoint: "${GATEWAY_ENDPOINT}"
elastic.endpoint: "${SEARCH_ENDPOINT}"
\ No newline at end of file
package at.tuwien.config;
import lombok.Getter;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Configuration;
@Slf4j
@Getter
@Configuration
public class SecurityConfig {
@Value("${fda.system.username}")
private String systemUsername;
@Value("${fda.system.passwd}")
private String systemPassword;
}
......@@ -47,11 +47,13 @@
<v-card-actions>
<v-spacer />
<v-btn
class="mb-2"
@click="cancel">
Cancel
</v-btn>
<v-btn
id="createDB"
class="mb-2 mr-2 ml-4"
:disabled="!valid || loading"
color="primary"
type="submit"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment