Skip to content

Commit

Permalink
Merge branch 'konveyor:main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
wise-king-sullyman authored Feb 21, 2024
2 parents 139f251 + 9b8a0ff commit e89933d
Show file tree
Hide file tree
Showing 8 changed files with 88 additions and 22 deletions.
6 changes: 6 additions & 0 deletions client/public/locales/en/translation.json
Original file line number Diff line number Diff line change
Expand Up @@ -486,6 +486,12 @@
"required": "This field is required."
},
"wizard": {
"alert": {
"sourceMode": {
"title": "Source Code Mode",
"description": "This mode focuses on analyzing the source code. Language-specific dependency configurations, like in Java's POM files, are not the primary focus and may not be fully analyzed."
}
},
"composed": {
"enable": "Enable {{what}}",
"excluded": "Excluded {{what}}",
Expand Down
25 changes: 24 additions & 1 deletion client/public/templates/questionnaire-template.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ sections:
risk: unknown
rationale: Lack of clarity on architecture can lead to unplanned issues.
mitigation: Conduct an architectural review.

- order: 3
text: Is your application's data storage cloud-optimized?
explanation: Evaluate if the data storage solution is optimized for cloud usage.
Expand All @@ -81,6 +80,30 @@ sections:
risk: yellow
rationale: Hybrid solutions may have integration complexities.
mitigation: Evaluate and optimize cloud integration points.
- order: 4
text: Are you currently using any form of container orchestration?
explanation: Determine if the application utilizes container orchestration tools like Kubernetes, Docker Swarm, etc.
excludeFor:
- category: Deployment
tag: Serverless
- category: Architecture
tag: Monolith
answers:
- order: 1
text: Kubernetes
risk: green
rationale: Kubernetes is a robust orchestrator for container management.
mitigation: Ensure Kubernetes configurations are optimized for cloud.
- order: 2
text: Docker Swarm
risk: green
rationale: Docker Swarm provides a simpler, yet effective, orchestration.
mitigation: Validate that Docker Swarm meets all cloud scalability requirements.
- order: 3
text: No Container Orchestration
risk: yellow
rationale: Lack of container orchestration can hinder cloud adaptability.
mitigation: Explore container orchestration options for better cloud integration.
thresholds:
red: 1
yellow: 30
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,15 @@ export const SetMode: React.FC<ISetMode> = ({ isSingleApp, isModeValid }) => {
<p>{t("wizard.label.notAllAnalyzableDetails")}</p>
</Alert>
)}
{mode === "source-code" && (
<Alert
variant="info"
isInline
title={t("wizard.alert.sourceMode.title")}
>
<p>{t("wizard.alert.sourceMode.description")}</p>
</Alert>
)}
{mode === "binary-upload" && <UploadBinary />}
</Form>
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ import {
MenuToggle,
MenuToggleElement,
Modal,
Tooltip,
} from "@patternfly/react-core";
import { PencilAltIcon, TagIcon, EllipsisVIcon } from "@patternfly/react-icons";
import {
Expand Down Expand Up @@ -359,9 +360,8 @@ export const ApplicationsTable: React.FC = () => {
selectOptions: [
...new Set(
applications
.flatMap(
(application) =>
application?.archetypes?.map((archetype) => archetype.name)
.flatMap((application) =>
application?.archetypes?.map((archetype) => archetype.name)
)
.filter(Boolean)
),
Expand Down Expand Up @@ -948,13 +948,15 @@ export const ApplicationsTable: React.FC = () => {

<Td isActionCell id="pencil-action">
{applicationWriteAccess && (
<Button
variant="plain"
icon={<PencilAltIcon />}
onClick={() =>
setSaveApplicationModalState(application)
}
/>
<Tooltip content={t("actions.edit")}>
<Button
variant="plain"
icon={<PencilAltIcon />}
onClick={() =>
setSaveApplicationModalState(application)
}
/>
</Tooltip>
)}
</Td>
<Td isActionCell id="row-actions">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ import {
import { useLegacyFilterState } from "@app/hooks/useLegacyFilterState";
import { useHistory } from "react-router-dom";
import { ItemTagLabel } from "../../../../components/labels/item-tag-label/item-tag-label";
import { capitalizeFirstLetter } from "@app/utils/utils";

interface TagWithSource extends Tag {
source?: string;
Expand Down Expand Up @@ -216,7 +217,7 @@ export const ApplicationTags: React.FC<ApplicationTagsProps> = ({
component="h3"
className={`${spacing.mtSm} ${spacing.mbSm} ${textStyles.fontSizeMd}`}
>
{source === "" ? "Manual" : source}
{source === "" ? "Manual" : capitalizeFirstLetter(source)}
</Text>
</TextContent>
{Array.from(tagCategoriesInThisSource).map((tagCategory) => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,11 +58,14 @@ export const WaveStakeholdersTable: React.FC<IWaveStakeholdersTableProps> = ({
<Toolbar {...toolbarProps}>
<ToolbarContent>
<ToolbarItem {...paginationToolbarItemProps}>
<SimplePagination
idPrefix={`expanded-migration-wave-${migrationWave.name}-apps-table`}
isTop
paginationProps={paginationProps}
/>
{migrationWave.allStakeholders.length > 9 && (
<SimplePagination
idPrefix={`expanded-migration-wave-${migrationWave.name}-apps-table`}
isTop
paginationProps={paginationProps}
isCompact
/>
)}
</ToolbarItem>
</ToolbarContent>
</Toolbar>
Expand Down Expand Up @@ -116,6 +119,14 @@ export const WaveStakeholdersTable: React.FC<IWaveStakeholdersTableProps> = ({
</Tbody>
</ConditionalTableBody>
</Table>
{migrationWave.allStakeholders.length > 9 && (
<SimplePagination
idPrefix={`expanded-migration-wave-${migrationWave.name}-apps-table`}
isTop={false}
paginationProps={paginationProps}
isCompact
/>
)}
</>
);
};
Original file line number Diff line number Diff line change
Expand Up @@ -73,11 +73,14 @@ export const WaveApplicationsTable: React.FC<IWaveApplicationsTableProps> = ({
<Toolbar {...toolbarProps}>
<ToolbarContent>
<ToolbarItem {...paginationToolbarItemProps}>
<SimplePagination
idPrefix={`expanded-migration-wave-${migrationWave.name}-apps-table`}
isTop
paginationProps={paginationProps}
/>
{migrationWave.fullApplications.length > 9 && (
<SimplePagination
idPrefix={`expanded-migration-wave-${migrationWave.name}-apps-table`}
isTop
paginationProps={paginationProps}
isCompact
/>
)}
</ToolbarItem>
</ToolbarContent>
</Toolbar>
Expand Down Expand Up @@ -155,6 +158,14 @@ export const WaveApplicationsTable: React.FC<IWaveApplicationsTableProps> = ({
</Tbody>
</ConditionalTableBody>
</Table>
{migrationWave.fullApplications.length > 9 && (
<SimplePagination
idPrefix={`expanded-migration-wave-${migrationWave.name}-apps-table`}
isTop={false}
paginationProps={paginationProps}
isCompact
/>
)}
</>
);
};
3 changes: 3 additions & 0 deletions client/src/app/utils/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -189,3 +189,6 @@ export const collapseSpacesAndCompare = (

return a.localeCompare(b, locale);
};

export const capitalizeFirstLetter = (str: string) =>
str.charAt(0).toUpperCase() + str.slice(1);

0 comments on commit e89933d

Please sign in to comment.