Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/maven.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
strategy:
matrix:
platform: [ ubuntu-latest ]
java-version: [ 8 ]
java-version: [ 8, 11, 17, 21 ]

runs-on: ${{ matrix.platform }}
env:
Expand Down
14 changes: 8 additions & 6 deletions api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,21 @@
<artifactId>idgen</artifactId>
<version>4.15.0-SNAPSHOT</version>
</parent>
<groupId>org.openmrs.module</groupId>
<artifactId>idgen-api</artifactId>
<packaging>jar</packaging>
<name>ID Generation API</name>
<description>API project for ID Generation</description>

<properties>
<MOCKITO_INLINE_VERSION>3.12.4</MOCKITO_INLINE_VERSION>
</properties>

<dependencies>
<dependency>
<groupId>org.codehaus.jackson</groupId>
<artifactId>jackson-mapper-asl</artifactId>
<version>1.5.0</version>
<type>jar</type>
<scope>provided</scope>
<groupId>org.mockito</groupId>
<artifactId>mockito-inline</artifactId>
<version>${MOCKITO_INLINE_VERSION}</version>
<scope>test</scope>
</dependency>
</dependencies>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,11 @@
*/
package org.openmrs.module.idgen;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;

import java.util.Date;
import java.util.UUID;

import org.codehaus.jackson.annotate.JsonIgnoreProperties;

/**
* Component which encapsulates an identifier that has been allocated to an Identifier Pool
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,6 @@ public List<String> generateIdentifiers(IdentifierSource source, Integer batchSi
* @param processor
* @return
*/
@Transactional(propagation = Propagation.REQUIRES_NEW)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this being removed?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mseaton I'm getting the following error when running this line:

[ERROR] org.openmrs.module.idgen.integration.RemoteWithLocalPoolIntegrationTest.testConfigurePoolFilledFromRemoteSource -- Time elapsed: 0.127 s <<< ERROR!
java.lang.NullPointerException
	at org.openmrs.module.idgen.service.BaseIdentifierSourceService.getProcessor(BaseIdentifierSourceService.java:152)
	at org.openmrs.module.idgen.service.BaseIdentifierSourceService.generateIdentifiersInternal(BaseIdentifierSourceService.java:195)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
	at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:344)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:198)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)
	at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:123)
	at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:388)
	at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:119)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
	at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:241)
	at com.sun.proxy.$Proxy254.generateIdentifiersInternal(Unknown Source)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
	at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:344)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:198)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)
	at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:123)
	at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:388)
	at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:119)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
	at org.springframework.aop.framework.adapter.MethodBeforeAdviceInterceptor.invoke(MethodBeforeAdviceInterceptor.java:58)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
	at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:241)
	at com.sun.proxy.$Proxy255.generateIdentifiersInternal(Unknown Source)
	at org.openmrs.module.idgen.service.BaseIdentifierSourceService.generateIdentifiers(BaseIdentifierSourceService.java:177)
	at org.openmrs.module.idgen.service.BaseIdentifierSourceService.generateIdentifier(BaseIdentifierSourceService.java:252)
	at org.openmrs.module.idgen.service.BaseIdentifierSourceService.generateIdentifier(BaseIdentifierSourceService.java:227)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
	at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:344)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:198)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)
	at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:123)
	at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:388)
	at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:119)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
	at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:241)
	at com.sun.proxy.$Proxy254.generateIdentifier(Unknown Source)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
	at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:344)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:198)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)
	at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:123)
	at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:388)
	at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:119)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
	at org.springframework.aop.framework.adapter.MethodBeforeAdviceInterceptor.invoke(MethodBeforeAdviceInterceptor.java:58)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
	at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:241)
	at com.sun.proxy.$Proxy255.generateIdentifier(Unknown Source)
	at org.openmrs.module.idgen.integration.RemoteWithLocalPoolIntegrationTest.testConfigurePoolFilledFromRemoteSource(RemoteWithLocalPoolIntegrationTest.java:50)
	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
	at org.springframework.test.context.junit4.statements.RunBeforeTestExecutionCallbacks.evaluate(RunBeforeTestExecutionCallbacks.java:74)
	at org.springframework.test.context.junit4.statements.RunAfterTestExecutionCallbacks.evaluate(RunAfterTestExecutionCallbacks.java:84)
	at org.springframework.test.context.junit4.statements.RunBeforeTestMethodCallbacks.evaluate(RunBeforeTestMethodCallbacks.java:75)
	at org.springframework.test.context.junit4.statements.RunAfterTestMethodCallbacks.evaluate(RunAfterTestMethodCallbacks.java:86)
	at org.springframework.test.context.junit4.statements.SpringRepeat.evaluate(SpringRepeat.java:84)
	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:251)
	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:97)
	at org.springframework.test.context.junit4.statements.RunBeforeTestClassCallbacks.evaluate(RunBeforeTestClassCallbacks.java:61)
	at org.springframework.test.context.junit4.statements.RunAfterTestClassCallbacks.evaluate(RunAfterTestClassCallbacks.java:70)
	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.run(SpringJUnit4ClassRunner.java:190)

I'm not exactly sure what’s causing this issue. However, I suspect that the proxy call doesn’t see the registered processor because the processors haven’t been populated in that proxy context. We might not have encountered this in older versions because Spring's proxying and transaction handling used to be more permissive.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Requires_New transactional annotation is very important (or at least it's goal is) which is to ensure that identifier generation does not result in duplicate identifiers being issued. It should not be removed without understanding it's purpose and ensuring with sufficient testing (which is difficult in our unit test framework) that the goals continue to be met.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agree with @mseaton 100%. We should not be removing annotations just as a way to fix tests. Though admittedly this could be a difficult one to solve.

public List<String> generateIdentifiersInternal(Integer sourceId, Integer batchSize, String comment) {

IdentifierSource source = getIdentifierSource(sourceId);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
import org.openmrs.module.idgen.SequentialIdentifierGenerator;
import org.openmrs.module.idgen.processor.IdentifierSourceProcessor;
import org.openmrs.util.OpenmrsConstants;
import org.openmrs.util.PrivilegeConstants;
import org.springframework.transaction.annotation.Transactional;

/**
Expand Down Expand Up @@ -117,23 +118,23 @@ public interface IdentifierSourceService extends OpenmrsService {
* Returns null if this PatientIdentifierType is not set to be auto-generated
*/
@Transactional
@Authorized(OpenmrsConstants.PRIV_EDIT_PATIENT_IDENTIFIERS)
@Authorized(PrivilegeConstants.EDIT_PATIENT_IDENTIFIERS)
public String generateIdentifier(PatientIdentifierType type, String comment);

/**
* Given a PatientIdentifierType and Location, generates an identifier using the proper IdentifierSource
* Returns null if this PatientIdentifierType is not set to be auto-generated
*/
@Transactional
@Authorized(OpenmrsConstants.PRIV_EDIT_PATIENT_IDENTIFIERS)
@Authorized(PrivilegeConstants.EDIT_PATIENT_IDENTIFIERS)
public String generateIdentifier(PatientIdentifierType type, Location location, String comment);

/**
* Generates a Single Identifiers from the given source
* @throws APIException
*/
@Transactional
@Authorized( OpenmrsConstants.PRIV_EDIT_PATIENT_IDENTIFIERS )
@Authorized(PrivilegeConstants.EDIT_PATIENT_IDENTIFIERS)
public String generateIdentifier(IdentifierSource source, String comment) throws APIException;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public Properties getRuntimeProperties() {
Properties props = super.getRuntimeProperties();
String url = props.getProperty(Environment.URL);
if (url.contains("jdbc:h2:") && !url.toLowerCase().contains(";mvcc=true")) {
props.setProperty(Environment.URL, url + ";mvcc=true");
props.setProperty(Environment.URL, url);
}
return props;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,14 @@
import static org.hamcrest.core.Is.is;
import static org.junit.Assert.assertThat;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.mockStatic;
import static org.mockito.Mockito.when;
import static org.powermock.api.mockito.PowerMockito.mockStatic;

import org.junit.After;
import org.junit.Assert;
import org.junit.Before;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.mockito.MockedStatic;
import org.openmrs.Location;
import org.openmrs.LocationAttribute;
import org.openmrs.LocationAttributeType;
Expand All @@ -20,19 +21,19 @@
import org.openmrs.module.idgen.prefixprovider.PrefixProvider;
import org.openmrs.module.idgen.suffixprovider.LocationBasedSuffixProvider;
import org.openmrs.module.idgen.suffixprovider.SuffixProvider;
import org.powermock.core.classloader.annotations.PrepareForTest;
import org.powermock.modules.junit4.PowerMockRunner;

/**
* test class for {@link SequentialIdentifierGenerator}
*/
@RunWith(PowerMockRunner.class)
@PrepareForTest(Context.class)

public class SequentialIdentifierGeneratorTest {

private MockedStatic<Context> mockedContext;

@Before
public void setup() {
mockStatic(Context.class);
mockedContext = mockStatic(Context.class);
}

@After
public void teardown() {
mockedContext.close();
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@
import org.openmrs.module.idgen.IdentifierSource;
import org.openmrs.module.idgen.IdgenBaseTest;
import org.openmrs.module.idgen.service.IdentifierSourceService;
import org.springframework.test.annotation.NotTransactional;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

import java.util.ArrayList;
import java.util.HashSet;
Expand Down Expand Up @@ -37,31 +38,30 @@ public void setUp() throws Exception {
}

@Test
@NotTransactional
public void testUnderLoad() throws Exception {
@Transactional(propagation = Propagation.NEVER)
public void testUnderLoad() {

final List<String> generated = new ArrayList<String>();

List<Thread> threads = new ArrayList<Thread>();
List<Thread> threads = new ArrayList<>();
for (int i = 0; i < NUM_THREADS; ++i) {
Thread thread = new Thread(new Runnable() {
@Override
public void run() {
Context.openSession();
Context.authenticate("admin", "test");
IdentifierSource source = getService().getIdentifierSource(4);
try {
authenticate();
sleep(100);
Thread thread = new Thread(() -> {
Context.openSession();
Context.authenticate("admin", "test");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you explain why we needed to make all the changes here?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since multiple threads are writing to the same ArrayList at the same time, it’s not thread-safe. That’s why the test started failing randomly after the update. I fixed it by wrapping the add logic in a synchronized block.

Not totally sure why this didn’t happen before, though.

IdentifierSource source = getService().getIdentifierSource(4);
try {
authenticate();
sleep(100);
synchronized (generated) {
generated.addAll(getService().generateIdentifiers(source, 1, "thread"));
sleep(100);
}
catch (Exception e) {
throw new RuntimeException(e);
}
finally {
Context.closeSession();
}
sleep(100);
}
catch (Exception e) {
throw new RuntimeException(e);
}
finally {
Context.closeSession();
}
});
thread.start();
Expand All @@ -77,7 +77,7 @@ public void run() {
}

assertThat(generated.size(), is(NUM_THREADS));
assertThat(new HashSet<String>(generated).size(), is(NUM_THREADS));
assertThat(new HashSet<>(generated).size(), is(NUM_THREADS));
}

public void sleep(long time) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,28 +2,24 @@

import static org.hamcrest.core.Is.is;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.mockStatic;
import static org.mockito.Mockito.when;
import static org.powermock.api.mockito.PowerMockito.mockStatic;

import java.util.Collections;

import org.junit.After;
import org.junit.Assert;
import org.junit.Before;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.mockito.MockedStatic;
import org.openmrs.Location;
import org.openmrs.LocationAttribute;
import org.openmrs.LocationAttributeType;
import org.openmrs.api.AdministrationService;
import org.openmrs.api.LocationService;
import org.openmrs.api.context.Context;
import org.openmrs.api.context.UserContext;
import org.openmrs.module.idgen.prefixprovider.LocationBasedPrefixProvider;
import org.powermock.core.classloader.annotations.PrepareForTest;
import org.powermock.modules.junit4.PowerMockRunner;

@RunWith(PowerMockRunner.class)
@PrepareForTest(Context.class)
public class LocationBasedPrefixProviderTest {

LocationBasedPrefixProvider locationPrefixProvider;
Expand All @@ -36,24 +32,32 @@ public class LocationBasedPrefixProviderTest {
Location location3;
Location location5;
Location locationA2;

private MockedStatic<Context> mockedContext;

@Before
public void setup() {
mockedContext = mockStatic(Context.class);
locationPrefixProvider = new LocationBasedPrefixProvider();

mockStatic(Context.class);
userContext = mock(UserContext.class);
when(Context.getUserContext()).thenReturn(userContext);


mockedContext.when(Context::getUserContext).thenReturn(userContext);

LocationService ls = mock(LocationService.class);
AdministrationService as = mock(AdministrationService.class);
when(Context.getLocationService()).thenReturn(ls);
when(Context.getAdministrationService()).thenReturn(as);
when(ls.getAllLocationAttributeTypes()).thenReturn(Collections.<LocationAttributeType>emptyList());
mockedContext.when(Context::getLocationService).thenReturn(ls);
mockedContext.when(Context::getAdministrationService).thenReturn(as);
mockedContext.when(ls::getAllLocationAttributeTypes).thenReturn(Collections.<LocationAttributeType>emptyList());
when(as.getGlobalProperty(LocationBasedPrefixProvider.PREFIX_LOCATION_ATTRIBUTE_TYPE_GP))
.thenReturn("Location Code");
setupLocationTree();
}

@After
public void teardown() {
mockedContext.close();
}

@Test
public void getValue_shouldReturnPrefixDependingOnLocationInUserContext() {
Expand Down
9 changes: 9 additions & 0 deletions api/src/test/resources/TestingApplicationContext.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,11 @@
<ref bean="mappingJarResources" />
</property>
<!-- default properties must be set in the hibernate.default.properties -->
<property name="packagesToScan">
<list>
<value>org.openmrs</value>
</list>
</property>
</bean>

<bean id="idgenTestTimerFactory" class="org.springframework.scheduling.concurrent.ScheduledExecutorFactoryBean">
Expand All @@ -39,5 +44,9 @@
</list>
</property>
</bean>


<bean id="LocationBasedSuffixProvider" class="org.openmrs.module.idgen.suffixprovider.LocationBasedSuffixProvider" />
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What are these beans for?

<bean id="LocationBasedPrefixProvider" class="org.openmrs.module.idgen.prefixprovider.LocationBasedPrefixProvider" />

</beans>
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<dataset>
<patient_identifier_type patient_identifier_type_id="50" name="Location Prefixed Identification Number" description="Identifier generated from a location prefix" format="[A-Z]{3,5}\-[0]{3}\-[0-9]{3}" creator="1" date_created="2019-04-1 15:59:20.0" required="false" format_description="" validator="" CHECK_DIGIT="5" retired="false" uuid="b0d10dc0-d8ce-11e3-9c1a-0jhg89c9a66"/>
<patient_identifier_type patient_identifier_type_id="50" name="Location Prefixed Identification Number" description="Identifier generated from a location prefix" format="[A-Z]{3,5}\-[0]{3}\-[0-9]{3}" creator="1" date_created="2019-04-1 15:59:20.0" required="false" format_description="" validator="" retired="false" uuid="b0d10dc0-d8ce-11e3-9c1a-0jhg89c9a66"/>
<global_property PROPERTY="idgen.prefixLocationAttributeType" PROPERTY_VALUE="Location Code" DESCRIPTION="" UUID="932ce5e6-5hj-443f-a6e3-6768421c17e9"/>

<location location_id="10" name="Location 1" parent_location="[NULL]" description="test description" creator="1" date_created="2005-01-01 00:00:00.0" retired="false" uuid="f0f8ba64b-ea57-4a41-b33c-9dfc59b0c60a"/>
Expand Down Expand Up @@ -46,7 +46,7 @@

<IDGEN_LOG_ENTRY ID="1" SOURCE="1" GENERATED_BY="1" IDENTIFIER="100892" COMMENT="New patient " DATE_GENERATED="2016-10-03 12:00:00.489" />
<IDGEN_LOG_ENTRY ID="2" SOURCE="1" GENERATED_BY="1" IDENTIFIER="100HH9" COMMENT="New Visit" DATE_GENERATED="2017-10-03 12:00:00.489" />
<IDGEN_LOG_ENTRY ID="3" SOURCE="1" GENERATED_BY="2" IDENTIFIER="100H9T" DATE_GENERATED="2017-10-01 12:00:00.489" />
<IDGEN_LOG_ENTRY ID="4" SOURCE="2" GENERATED_BY="3" IDENTIFIER="100H28" COMMENT="Demo Data" DATE_GENERATED="2017-10-02 12:00:00.489" />
<IDGEN_LOG_ENTRY ID="5" SOURCE="3" GENERATED_BY="4" IDENTIFIER="100GYF" DATE_GENERATED="2017-09-20 12:00:00.489" />
<IDGEN_LOG_ENTRY ID="3" SOURCE="1" GENERATED_BY="1" IDENTIFIER="100H9T" DATE_GENERATED="2017-10-01 12:00:00.489" />
<IDGEN_LOG_ENTRY ID="4" SOURCE="2" GENERATED_BY="1" IDENTIFIER="100H28" COMMENT="Demo Data" DATE_GENERATED="2017-10-02 12:00:00.489" />
<IDGEN_LOG_ENTRY ID="5" SOURCE="3" GENERATED_BY="1" IDENTIFIER="100GYF" DATE_GENERATED="2017-09-20 12:00:00.489" />
</dataset>
38 changes: 22 additions & 16 deletions omod/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
<artifactId>idgen</artifactId>
<version>4.15.0-SNAPSHOT</version>
</parent>
<groupId>org.openmrs.module</groupId>
<artifactId>idgen-omod</artifactId>
<packaging>jar</packaging>
<name>ID Generation OMOD</name>
Expand All @@ -16,7 +15,9 @@
<MODULE_NAME>${project.parent.name}</MODULE_NAME>
<MODULE_VERSION>${project.parent.version}</MODULE_VERSION>
<MODULE_PACKAGE>${project.parent.groupId}.${project.parent.artifactId}</MODULE_PACKAGE>
<WEBSERVICES_VERSION>2.23.0</WEBSERVICES_VERSION>
<WEBSERVICES_VERSION>3.0.0-SNAPSHOT</WEBSERVICES_VERSION>
<LEGACY_UI_VERSION>2.0.0-SNAPSHOT</LEGACY_UI_VERSION>
<JAVAX_VERSION>4.0.1</JAVAX_VERSION>
</properties>

<dependencies>
Expand All @@ -25,13 +26,6 @@
<artifactId>idgen-api</artifactId>
<version>${project.parent.version}</version>
</dependency>
<dependency>
<groupId>org.codehaus.jackson</groupId>
<artifactId>jackson-mapper-asl</artifactId>
<version>1.5.0</version>
<type>jar</type>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.openmrs.module</groupId>
<artifactId>webservices.rest-omod</artifactId>
Expand All @@ -58,13 +52,25 @@
<version>${WEBSERVICES_VERSION}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.openmrs.module</groupId>
<artifactId>idgen-api</artifactId>
<version>${project.parent.version}</version>
<scope>test</scope>
<type>test-jar</type>
</dependency>
<dependency>
<groupId>org.openmrs.module</groupId>
<artifactId>idgen-api</artifactId>
<version>${project.parent.version}</version>
<scope>test</scope>
<type>test-jar</type>
</dependency>
<dependency>
<groupId>org.openmrs.module</groupId>
<artifactId>legacyui-omod</artifactId>
<version>${LEGACY_UI_VERSION}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<version>${JAVAX_VERSION}</version>
<scope>provided</scope>
</dependency>
</dependencies>

<build>
Expand Down
Loading