Skip to content

Commit

Permalink
Merge pull request #400 from lopezton-anthem/feature/merge-to-master
Browse files Browse the repository at this point in the history
NIMBUS-XX:: Feature/merge to master
  • Loading branch information
soham-anthem authored Feb 14, 2019
2 parents efe6e91 + d6ce7f4 commit 890f854
Show file tree
Hide file tree
Showing 425 changed files with 55,904 additions and 11,437 deletions.
10 changes: 3 additions & 7 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Contributing to Anthem Open Source projects

Want to hack on changes to an Anthem Open Source Project? We have a contributor's guide that explains
Want to hack on changes to the Nimbus Framework? We have a contributor's guide that explains
[setting up a development environment and the contribution
process](https://anthemopensource.atlassian.net/wiki/spaces/opensource/pages/45842524/Setup+Development+Environment).
process](https://anthemopensource.atlassian.net/wiki/spaces/OSS/pages/523436073/Contributing).

This page contains information about reporting issues as well as some tips and
guidelines useful to experienced open source contributors. Finally, make sure
Expand Down Expand Up @@ -146,7 +146,7 @@ Include an issue reference like `Closes #XXXX` or `Fixes #XXXX` in the pull requ
description that close an issue. Including references automatically closes the issue
on a merge.

Please see the [Coding Style](#coding-style) for further guidelines.
Please see the [Coding Style](https://anthemopensource.atlassian.net/wiki/spaces/OSS/pages/523698209/Nimbus+Framework+Code+Style) for further guidelines.

### Merge approval

Expand Down Expand Up @@ -224,7 +224,3 @@ intolerable.
* Contact [email protected] to report abuse or appeal violations. In the case of
appeals, we know that mistakes happen, and we'll work with you to come up with a
fair solution if there has been a misunderstanding.

## Coding Style

Anthem will define these guidelines soon.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ https://anthemopensource.atlassian.net/wiki/spaces/OSS/pages
[Nexus Sonatype](https://oss.sonatype.org/#nexus-search;quick~com.antheminc.oss)

## Issue Reporting
Are you stuck on an implementation or do you think you might have found an issue within the framework?
Please create a post in the [OSS Discourse Forum](http://discourse.oss.antheminc.com/) so that we might take a look and validate the issue you're seeing. In the case that a framework change is needed, one of the project admins will create an associated issue in JIRA (Coming soon...) to address the required change.

## Unit Tests

Expand Down
2 changes: 2 additions & 0 deletions nimbus-core/lombok.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
lombok.anyConstructor.addConstructorProperties=true
config.stopBubbling = true
4 changes: 2 additions & 2 deletions nimbus-core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@
<parent>
<groupId>com.antheminc.oss</groupId>
<artifactId>nimbus-parent</artifactId>
<version>1.2.0.BUILD-SNAPSHOT</version>
<version>2.0.0.BUILD-SNAPSHOT</version>
</parent>

<artifactId>nimbus-core</artifactId>

<properties>
<sonar.jacoco.reportPaths>target/jacoco.exec, ../nimbus-test/target/jacoco.exec</sonar.jacoco.reportPaths>
<sonar.coverage.exclusions>src/main/java/com/antheminc/oss/nimbus/entity/**/*.java</sonar.coverage.exclusions>
<sonar.coverage.exclusions>src/main/java/com/antheminc/oss/nimbus/entity/**/*.java, src/main/java/com/antheminc/oss/nimbus/domain/defn/ViewConfig.java</sonar.coverage.exclusions>
</properties>

<build>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,6 @@ public FrameworkRuntimeException(String message, Throwable cause) {
super(message, cause);
this.execEx = create(message);
}

public FrameworkRuntimeException(String message, Throwable cause, boolean enableSuppression, boolean writableStackTrace) {
super(message, cause, enableSuppression, writableStackTrace);
this.execEx = create(message);
}


private ExecuteError create(String msg) {
return new ExecuteError(this.getClass(), msg);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,16 +30,4 @@ public InvalidArgumentException(String message) {
super(message);
}

public InvalidArgumentException(Throwable cause) {
super(cause);
}

public InvalidArgumentException(String message, Throwable cause) {
super(message, cause);
}

public InvalidArgumentException(String message, Throwable cause, boolean enableSuppression, boolean writableStackTrace) {
super(message, cause, enableSuppression, writableStackTrace);
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -22,26 +22,13 @@
public class InvalidConfigException extends FrameworkRuntimeException {

private static final long serialVersionUID = 1L;


public InvalidConfigException() { }

public InvalidConfigException(String message) {
super(message);
}

public InvalidConfigException(Throwable cause) {
super(cause);
}

public InvalidConfigException(String message, Throwable cause) {
super(message, cause);
}

public InvalidConfigException(String message, Throwable cause, boolean enableSuppression,
boolean writableStackTrace) {

super(message, cause, enableSuppression, writableStackTrace);
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -22,26 +22,9 @@
public class InvalidOperationAttemptedException extends FrameworkRuntimeException {

private static final long serialVersionUID = 1L;


public InvalidOperationAttemptedException() { }

public InvalidOperationAttemptedException(String message) {
super(message);
}

public InvalidOperationAttemptedException(Throwable cause) {
super(cause);
}

public InvalidOperationAttemptedException(String message, Throwable cause) {
super(message, cause);
}

public InvalidOperationAttemptedException(String message, Throwable cause, boolean enableSuppression,
boolean writableStackTrace) {

super(message, cause, enableSuppression, writableStackTrace);
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -25,18 +25,6 @@ public class JsonConversionException extends FrameworkRuntimeException {
*
*/
private static final long serialVersionUID = 1L;

public JsonConversionException() {
super();
}

public JsonConversionException(String message) {
super(message);
}

public JsonConversionException(Throwable cause) {
super(cause);
}

public JsonConversionException(String message, Throwable cause) {
super(message, cause);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,22 +23,8 @@ public class UnsupportedScenarioException extends FrameworkRuntimeException {

private static final long serialVersionUID = 1L;

public UnsupportedScenarioException() {}

public UnsupportedScenarioException(String message) {
super(message);
}

public UnsupportedScenarioException(Throwable cause) {
super(cause);
}

public UnsupportedScenarioException(String message, Throwable cause) {
super(message, cause);
}

public UnsupportedScenarioException(String message, Throwable cause, boolean enableSuppression, boolean writableStackTrace) {
super(message, cause, enableSuppression, writableStackTrace);
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
import org.activiti.engine.impl.bpmn.parser.factory.DefaultActivityBehaviorFactory;
import org.activiti.engine.impl.history.HistoryLevel;
import org.activiti.engine.impl.persistence.deploy.Deployer;
import org.activiti.runtime.api.identity.UserGroupManager;
import org.activiti.spring.SpringAsyncExecutor;
import org.activiti.spring.SpringProcessEngineConfiguration;
import org.activiti.spring.boot.AbstractProcessEngineAutoConfiguration;
Expand Down Expand Up @@ -115,11 +116,11 @@ public class BPMEngineConfig extends AbstractProcessEngineAutoConfiguration {
@Bean
public SpringProcessEngineConfiguration springProcessEngineConfiguration(
@Qualifier("processDataSource") DataSource processDataSource,
PlatformTransactionManager jpaTransactionManager, SpringAsyncExecutor springAsyncExecutor,
BeanResolverStrategy beanResolver) throws Exception {
PlatformTransactionManager jpaTransactionManager, SpringAsyncExecutor springAsyncExecutor,
BeanResolverStrategy beanResolver, UserGroupManager userGroupManager) throws Exception {

SpringProcessEngineConfiguration engineConfiguration = this
.baseSpringProcessEngineConfiguration(processDataSource, jpaTransactionManager, springAsyncExecutor, null);
.baseSpringProcessEngineConfiguration(processDataSource, jpaTransactionManager, springAsyncExecutor,userGroupManager);

if (deploymentName.isPresent()) {
engineConfiguration.setDeploymentName(deploymentName.get());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,10 @@
import com.antheminc.oss.nimbus.domain.config.builder.AnnotationConfigHandler;
import com.antheminc.oss.nimbus.domain.config.builder.DefaultAnnotationConfigHandler;
import com.antheminc.oss.nimbus.domain.config.builder.DomainConfigBuilder;
import com.antheminc.oss.nimbus.domain.config.builder.EventAnnotationConfigHandler;
import com.antheminc.oss.nimbus.domain.config.builder.attributes.ConstraintAnnotationAttributeHandler;
import com.antheminc.oss.nimbus.domain.config.builder.attributes.DefaultAnnotationAttributeHandler;
import com.antheminc.oss.nimbus.domain.model.config.EntityConfig.Scope;
import com.antheminc.oss.nimbus.domain.model.config.builder.EntityConfigBuilder;
import com.antheminc.oss.nimbus.domain.model.config.builder.internal.DefaultEntityConfigBuilder;
import com.antheminc.oss.nimbus.domain.model.config.builder.internal.DefaultExecutionConfigProvider;
Expand Down Expand Up @@ -74,6 +76,10 @@ public class DefaultCoreBuilderConfig {

private List<String> basePackages;

private List<String> basePackagesToExclude;

private Map<Scope, List<String>> domainSet;

@Value("${platform.config.secure.regex}")
private String secureRegex;

Expand All @@ -90,7 +96,7 @@ public ChangeLogCommandEventHandler changeLogCommandEventHandler(BeanResolverStr

@Bean
public DomainConfigBuilder domainConfigBuilder(EntityConfigBuilder configBuilder){
return new DomainConfigBuilder(configBuilder, basePackages);
return new DomainConfigBuilder(configBuilder, basePackages, basePackagesToExclude);
}

@Bean
Expand Down Expand Up @@ -133,21 +139,29 @@ public DetourExecutionConfigProvider detourExecutionConfigProvider(BeanResolverS
return new DetourExecutionConfigProvider();
}

@Bean
public AnnotationConfigHandler annotationConfigHandler(PropertyResolver propertyResolver) {
@Bean(name="default.annotationConfigBuilder")
public AnnotationConfigHandler annotationConfigHandler(BeanResolverStrategy beanResolver, PropertyResolver propertyResolver) {
Map<Class<? extends Annotation>, AnnotationAttributeHandler> attributeHandlers = new HashMap<>();
attributeHandlers.put(Constraint.class, new ConstraintAnnotationAttributeHandler());
attributeHandlers.put(Constraint.class, new ConstraintAnnotationAttributeHandler(beanResolver));

return new DefaultAnnotationConfigHandler(new DefaultAnnotationAttributeHandler(), attributeHandlers, propertyResolver);
}

@Bean(name="default.eventAnnotationConfigBuilder")
public AnnotationConfigHandler eventAnnotationConfigHandler() {
return new EventAnnotationConfigHandler();
}

@Bean
public EntityConfigBuilder entityConfigBuilder(BeanResolverStrategy beanResolver){
if(typeClassMappings==null) {
typeClassMappings = new HashMap<>();
}
if(domainSet == null) {
domainSet = new HashMap<>();
}

return new DefaultEntityConfigBuilder(beanResolver, typeClassMappings);
return new DefaultEntityConfigBuilder(beanResolver, typeClassMappings, domainSet);
}

@Bean
Expand Down
Loading

0 comments on commit 890f854

Please sign in to comment.