Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/issues/131_m-rc-deployments' into
Browse files Browse the repository at this point in the history
develop
  • Loading branch information
hhund committed Dec 12, 2023
2 parents fef882e + 9687336 commit 55ce3d8
Showing 1 changed file with 10 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,9 @@

public class ProcessPluginLoaderImpl implements ProcessPluginLoader, InitializingBean
{
public static final String FILE_DRAFT_SUFFIX = "-SNAPSHOT.jar";
public static final String SNAPSHOT_FILE_SUFFIX = "-SNAPSHOT.jar";
public static final String MILESTONE_FILE_PATTERN = ".*-M[0-9]+.jar";
public static final String RELEASE_CANDIDATE_FILE_PATTERN = ".*-RC[0-9]+.jar";

private static final Logger logger = LoggerFactory.getLogger(ProcessPluginLoaderImpl.class);

Expand Down Expand Up @@ -118,7 +120,13 @@ else if (!p.getFileName().toString().endsWith(".jar"))
if (definitions.size() != 1)
return null;

boolean draft = jar.getFileName().toString().endsWith(FILE_DRAFT_SUFFIX);
String filename = jar.getFileName().toString();
boolean isSnapshot = filename.endsWith(SNAPSHOT_FILE_SUFFIX);
boolean isMilestone = filename.matches(MILESTONE_FILE_PATTERN);
boolean isReleaseCandidate = filename.matches(RELEASE_CANDIDATE_FILE_PATTERN);

boolean draft = isSnapshot || isMilestone || isReleaseCandidate;

return factory.createProcessPlugin(definitions.get(0).get(), draft, jar, classLoader, fhirContext,
environment);
}
Expand Down

0 comments on commit 55ce3d8

Please sign in to comment.