Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat : Refactored partasplanned and SingleLevelBoMAsPlanned maven module to support multi versions #143

Conversation

ChetanT-System
Copy link
Contributor

@ChetanT-System ChetanT-System commented Apr 26, 2024

Description

  • Refactored/Updated PartAsPlanned and SingleLevelBoMAsPlanned maven module to support multi version.

Pre-review checks

Please ensure to do as many of the following checks as possible, before asking for committer review:

@Modifying
@Transactional
@SneakyThrows
public int saveSubmodelData(List<String> colNames, String tableEntityName, String processId, JsonNode submodelData,

Check notice

Code scanning / CodeQL

Useless parameter Note

The parameter 'processId' is never used.
Comment on lines 125 to 129
JsonObject calculatedPCFValue = jsonObjectList.stream()
.filter(ele -> request.getProductId()
.equals(JsonObjectUtility.getValueFromJsonObject(ele, PRODUCT_ID)))
.findAny().orElseThrow(() -> new NoDataFoundException(
"No data found for product_id " + request.getProductId()));

Check notice

Code scanning / CodeQL

Unread local variable Note

Variable 'JsonObject calculatedPCFValue' is never read.
}

@SneakyThrows
public String checkShellAndGetIdIfExist(ObjectNode jsonObject, Map<String, String> specificAssetIds)

Check notice

Code scanning / CodeQL

Useless parameter Note

The parameter 'jsonObject' is never used.
}

@SneakyThrows
public int getUpdatedData(String processId) {

Check notice

Code scanning / CodeQL

Missing Override annotation Note

This method overrides
DatabaseUsecaseStep.getUpdatedData
; it is advisable to add an Override annotation.
}

@SneakyThrows
public JsonObject readCreatedTwinsDetails(String uuid) {

Check notice

Code scanning / CodeQL

Missing Override annotation Note

This method overrides
DatabaseUsecaseStep.readCreatedTwinsDetails
; it is advisable to add an Override annotation.

String resource = "single-level-bom-as-planned-v3.0.0.json";
// this is the path within the jar file
InputStream input = this.getClass().getResourceAsStream("/resources/" + resource);

Check warning

Code scanning / CodeQL

Unsafe use of getResource Warning

The idiom getClass().getResource() is unsafe for classes that may be extended.
…pport' into CX_R24.05_part_as_planned_multi_version_support
…pport' into CX_R24.05_part_as_planned_multi_version_support
Copy link
Contributor

@sachinargade123 sachinargade123 left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@adityagajbhiye9 adityagajbhiye9 left a comment

Choose a reason for hiding this comment

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

LGTM

@ChetanT-System
Copy link
Contributor Author

@almadigabor Please review and approve the PR.

@almadigabor almadigabor merged commit 257e104 into eclipse-tractusx:main Apr 30, 2024
6 checks passed
@almadigabor almadigabor deleted the CX_R24.05_part_as_planned_multi_version_support branch April 30, 2024 14:13
sachinargade123 added a commit to sachinargade123/dft-backend that referenced this pull request May 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants