Skip to content

Commit

Permalink
Major dependency updates and modernization, vulnerability reduction
Browse files Browse the repository at this point in the history
Engine:
- node: 16.x.x → 20.x.x

Dependencies:
- @blueprintjs/core: 3.29.0 → 4.20.2
- @blueprintjs/datetime: 3.18.3 → 4.4.37
- @emotion/react: 11.11.1 → 11.13.3
- @emotion/styled: 11.11.0 → 11.13.0
- @mui/icons-material: 5.13.7 → 6.3.0
- @mui/lab: 5.0.0-alpha.135 → 6.0.0-beta.21
- @mui/material: 5.13.7 → 6.3.0
- @mui/system: 5.13.7 → 6.3.0
- @mui/x-data-grid: 6.9.1 → 7.23.5
- @turf/*: 6.5.0 → 7.1.0
- @types/backbone: Added 1.4.4
- @types/backbone.radio: Added 0.8.37
- d3: 5.16.0 → 7.9.0
- jquery: 3.4.1 → 3.7.1
- lodash: 4.17.15 → 4.17.21
- moment: 2.27.0 → 2.30.1
- moment-timezone: 0.5.31 → 0.5.46
- openlayers/ol: 4.6.5 → 10.2.1
- plotly.js: 1.45.0 → 2.35.3
- react-router-dom: 5.3.4 → 6.28.1
- styled-components: 5.3.10 → 6.1.13
- tailwindcss: 3.3.1 → 3.4.17
- urijs: 1.19.1 → 1.19.11

Dev Dependencies:
- @connexta/ace: Updated git commit hash to latest
- @testing-library/jest-dom: Added 6.6.3
- @testing-library/dom: Added 10.4.0
- @testing-library/react: Added 16.0.1
- @testing-library/user-event: Added 14.5.2
- @types/d3: 5.0.0 → 7.4.3 - resolutions necessary because the main types does not specify a version for subtypes
- @types/jquery: Added 3.5.32
- autoprefixer: Added 10.4.20
- tslib: 2.5.0 → 2.8.1
- typescript: 5.0.4 → 5.7.2

Removed Dependencies:
- @types/enzyme
- @types/react-router-dom
- @types/styled-components
- @welldone-software/why-did-you-render
- enzyme - no longer supported, replaced with @testing-library
- @wojtekmaj/enzyme-adapter-react-17
- jsdom
- react-addons-test-utils
- @types/openlayers
- bootstrap

Build Tools:
- cpx → cpy-cli
- cpy: Added 11.1.0
- cpy-cli: Added 5.0.0
- move-cli: 1.2.1 → move-file-cli 3.0.0
- move-file: Added 3.1.0
- move-file-cli: Added 3.0.0
- json: 9.0.6 → 11.0.0

Script Changes:
- Removed m2 and install:m2 scripts
- Updated postbuild to use move-file instead of move-cli
- Updated publish scripts to use cpy instead of cpx

Type Definition Resolutions Added:
 - Fixes issues that result from multiple differing versions of dependencies being pulled in.
  • Loading branch information
andrewkfiedler committed Jan 22, 2025
1 parent 159b00f commit dbc611f
Show file tree
Hide file tree
Showing 251 changed files with 22,686 additions and 39,578 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/catalog-ui-search-dist-pr-onclose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: "16.x"
node-version: "20.x"

- name: Delete branch
uses: actions/github-script@v6
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/catalog-ui-search-dist-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: "16.x"
node-version: "20.x"

- name: Install dependencies
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/catalog-ui-search-dist-snapshot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: "16.x"
node-version: "20.x"

- name: Install dependencies
run: |
Expand Down
25 changes: 25 additions & 0 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,31 @@ pipeline {
}
steps {
withMaven(maven: 'maven-latest', jdk: 'jdk17', globalMavenSettingsConfig: 'default-global-settings', mavenSettingsConfig: 'codice-maven-settings', mavenOpts: '${LARGE_MVN_OPTS} ${LINUX_MVN_RANDOM}') {
sh '''
# Install Chrome dependencies
apt-get update
apt-get install -y libnss3 libnss3-dev libglib2.0-0 libc6
# Create directory for node
mkdir -p /root/.m2/repository/com/github/eirslett/node/20.18.1/
# Create a temporary directory for restructuring
TEMP_DIR=$(mktemp -d)
# Download and extract the glibc-compatible node
curl -L https://unofficial-builds.nodejs.org/download/release/v20.18.1/node-v20.18.1-linux-x64-glibc-217.tar.gz | tar xz -C "$TEMP_DIR"
# Repackage with the expected structure
cd "$TEMP_DIR"
mv node-v20.18.1-linux-x64-glibc-217 node-v20.18.1-linux-x64
tar czf node-20.18.1-linux-x64.tar.gz node-v20.18.1-linux-x64
# Move to the maven repository location
mv node-20.18.1-linux-x64.tar.gz /root/.m2/repository/com/github/eirslett/node/20.18.1/
# Cleanup
rm -rf "$TEMP_DIR"
'''
sh 'mvn clean install -B $DISABLE_DOWNLOAD_PROGRESS_OPTS'
}
}
Expand Down
4 changes: 2 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -121,10 +121,10 @@
<jknack.handlebars.version>2.0.0</jknack.handlebars.version>
<marionette.version>2.4.5</marionette.version>
<moment.version>2.20.1</moment.version>
<node.version>v16.16.0</node.version>
<node.version>v20.18.1</node.version>
<picocontainer.version>1.3_1</picocontainer.version>
<underscore.version>1.8.3</underscore.version>
<yarn.version>v1.22.4</yarn.version>
<yarn.version>v1.22.22</yarn.version>

<project.report.output.directory>project-info</project.report.output.directory>
</properties>
Expand Down
5 changes: 0 additions & 5 deletions ui-frontend/.eslintignore

This file was deleted.

21 changes: 0 additions & 21 deletions ui-frontend/.eslintrc.js

This file was deleted.

8 changes: 0 additions & 8 deletions ui-frontend/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -157,14 +157,6 @@ attach a new artifact, do:

ace pom

### OSGI Hot Deploy

To hot deploy a single web app, instead of building the entire maven
project, you can run `ace package` and `ace install` at the root of the
package. This will package any changes and install the OSGI bundle into
your local m2 using the maven coordinate
`mvn:org.codice.ddf/ui/${project.version}/jar/${package.name}`.

### Extensibility

Currently none of the sub-packages are published to a public javascript
Expand Down
3 changes: 1 addition & 2 deletions ui-frontend/lerna.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
{
"version": "2.12.0",
"lerna": "3.20.2",
"version": "independent",
"npmClient": "yarn",
"useWorkspaces": false
}
23 changes: 8 additions & 15 deletions ui-frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,29 +10,22 @@
"build:transpile": "yarn format && lerna run build -- --tsTranspileOnly true",
"postbuild": "mkdirp target && ace gen-feature",
"postinstall": "lerna bootstrap",
"m2": "yarn install:m2",
"install:m2": "yarn mvn:create-archive && yarn mvn:install-file",
"mvn:create-archive": "mvn org.apache.maven.plugins:maven-assembly-plugin:single@create-archive",
"mvn:install-file": "mvn org.apache.maven.plugins:maven-install-plugin:install-file -Dfile=target/packages-packages.zip -DpomFile=pom.xml -Dclassifier=packages -Dpackaging=zip"
},
"engines": {
"node": "20.x.x"
},
"devDependencies": {
"@connexta/ace": "git+https://github.com/connexta/ace.git#4cc376863e82757699cdaa1301f30266e66a1efe",
"@connexta/eslint-config-connexta": "git+https://github.com/connexta/eslint-config-connexta.git#105393617ec845b009b682882c95313ba50144b1",
"@connexta/eslint-plugin-connexta": "git+https://github.com/connexta/eslint-plugin-connexta.git#9b366b8924c3dbe03aedcfe6d25c8eb3567cc061",
"bootstrap-sass": "3.4.1",
"bootswatch": "3.3.7",
"compass-mixins": "0.12.10",
"cpr": "3.0.1",
"lerna": "3.20.2",
"mkdirp": "0.5.1",
"npm": "6.13.4",
"rimraf": "2.6.2",
"sass-lint": "1.12.1"
"@connexta/ace": "git+https://github.com/connexta/ace.git#3f371530327bb2aa6284685e16d1c6f9d7809871",
"lerna": "3.22.1",
"mkdirp": "3.0.1"
},
"ace": {
"features": [
"packages/*"
]
},
"name": "ui"
"name": "ui",
"packageManager": "yarn@1.22.22+sha512.a6b2f7906b721bba3d67d4aff083df04dad64c399707841b7acf00f6b133b7ac24255f2652fa22ae3534329dc6180534e98d17432037ff6fd140556e2bb3137e"
}
6 changes: 3 additions & 3 deletions ui-frontend/packages/admin/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,16 @@
"url": "https://github.com/codice/ddf.git"
},
"engines": {
"node": "16.x.x"
"node": "20.x.x"
},
"devDependencies": {
"@types/react": "16.9.34",
"@types/react-dom": "16.9.7",
"@types/styled-components": "5.1.0",
"@connexta/ace": "git+https://github.com/connexta/ace.git#4cc376863e82757699cdaa1301f30266e66a1efe"
"@connexta/ace": "git+https://github.com/connexta/ace.git#3f371530327bb2aa6284685e16d1c6f9d7809871"
},
"dependencies": {
"@connexta/kanri": "connexta/kanri#3218c8bc07b22d1c583c504acbdbb2fb0b099339",
"@connexta/kanri": "git+https://github.com/connexta/kanri.git#6f1f0bc9ad113bf0c3e65e680613c2cd10c74305",
"@material-ui/core": "4.9.12",
"@material-ui/icons": "4.9.1",
"@material-ui/lab": "4.0.0-alpha.51",
Expand Down
2 changes: 0 additions & 2 deletions ui-frontend/packages/admin/src/components/entry/entry.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { entry } from '@connexta/kanri/src/main/webapp/components/entry/entry'
import { hot } from 'react-hot-loader/root'
import * as React from 'react'
import BrandingIcon from '@material-ui/icons/Brush'
import { Branding } from '../branding/branding'
Expand All @@ -23,4 +22,3 @@ entry({
},
},
})
export default hot(() => {}) // just to enable hot reloading
Loading

0 comments on commit dbc611f

Please sign in to comment.