Skip to content

Commit

Permalink
refactor: javax.servlet --> jakarta.servlet
Browse files Browse the repository at this point in the history
  • Loading branch information
jo-elimu committed Jan 15, 2025
1 parent 3beea4b commit 7d73179
Show file tree
Hide file tree
Showing 158 changed files with 435 additions and 436 deletions.
54 changes: 24 additions & 30 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@
<java.version>17</java.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<model.version>2.0.74</model.version>
<hibernate.version>5.6.15.Final</hibernate.version>
<jetty.version>10.0.22</jetty.version>
<spring.version>5.3.18</spring.version>
<spring.security.version>5.6.2</spring.security.version>
<hibernate.version>6.1.7.Final</hibernate.version>
<jetty.version>11.0.24</jetty.version>
<spring.version>6.0.8</spring.version>
<spring.security.version>6.0.5</spring.security.version>
<surefire-plugin.version>3.1.2</surefire-plugin.version>
</properties>

Expand Down Expand Up @@ -370,11 +370,6 @@
</dependency>

<!-- Apache Commons -->
<dependency>
<groupId>commons-fileupload</groupId>
<artifactId>commons-fileupload</artifactId>
<version>1.4</version>
</dependency>
<dependency>
<groupId>commons-lang</groupId>
<artifactId>commons-lang</artifactId>
Expand Down Expand Up @@ -480,28 +475,27 @@
</dependency>

<dependency>
<groupId>javax.servlet</groupId>
<artifactId>jstl</artifactId>
<version>1.2</version>
<groupId>jakarta.servlet.jsp.jstl</groupId>
<artifactId>jakarta.servlet.jsp.jstl-api</artifactId>
<version>3.0.0</version>
</dependency>
<dependency>
<groupId>org.glassfish.web</groupId>
<artifactId>jakarta.servlet.jsp.jstl</artifactId>
<version>3.0.1</version>
</dependency>

<!-- Hibernate (ORM) -->
<dependency>
<groupId>org.hibernate</groupId>
<groupId>org.hibernate.orm</groupId>
<artifactId>hibernate-core</artifactId>
<version>${hibernate.version}</version>
</dependency>
<dependency>
<groupId>org.hibernate</groupId>
<artifactId>hibernate-entitymanager</artifactId>
<version>${hibernate.version}</version>
</dependency>
<dependency>
<groupId>org.hibernate</groupId>
<artifactId>hibernate-tools</artifactId>
<groupId>org.hibernate.orm</groupId>
<artifactId>hibernate-ant</artifactId>
<version>${hibernate.version}</version>
</dependency>

<dependency>
<groupId>org.hibernate.validator</groupId>
<artifactId>hibernate-validator</artifactId>
Expand All @@ -515,9 +509,9 @@

<!-- Database -->
<dependency>
<groupId>javax.persistence</groupId>
<artifactId>javax.persistence-api</artifactId>
<version>2.2</version>
<groupId>jakarta.persistence</groupId>
<artifactId>jakarta.persistence-api</artifactId>
<version>3.0.0</version>
</dependency>
<dependency>
<groupId>javax.transaction</groupId>
Expand All @@ -542,15 +536,15 @@

<!-- Provided by Jetty -->
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<version>4.0.1</version>
<groupId>jakarta.servlet</groupId>
<artifactId>jakarta.servlet-api</artifactId>
<version>5.0.0</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>javax.servlet.jsp</groupId>
<artifactId>javax.servlet.jsp-api</artifactId>
<version>2.3.3</version>
<groupId>jakarta.servlet.jsp</groupId>
<artifactId>jakarta.servlet.jsp-api</artifactId>
<version>3.0.0</version>
<scope>provided</scope>
</dependency>

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ai/elimu/dao/jpa/ApplicationDaoJpa.java
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package ai.elimu.dao.jpa;

import java.util.List;
import javax.persistence.NoResultException;
import jakarta.persistence.NoResultException;
import ai.elimu.dao.ApplicationDao;
import ai.elimu.model.admin.Application;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package ai.elimu.dao.jpa;

import java.util.List;
import javax.persistence.NoResultException;
import jakarta.persistence.NoResultException;
import ai.elimu.dao.ApplicationVersionDao;
import ai.elimu.model.admin.Application;
import ai.elimu.model.admin.ApplicationVersion;
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ai/elimu/dao/jpa/AudioDaoJpa.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import java.util.List;

import javax.persistence.NoResultException;
import jakarta.persistence.NoResultException;
import ai.elimu.dao.AudioDao;
import ai.elimu.model.content.StoryBookParagraph;
import ai.elimu.model.content.Word;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import ai.elimu.model.contributor.AudioPeerReviewEvent;
import ai.elimu.model.contributor.Contributor;
import java.util.List;
import javax.persistence.NoResultException;
import jakarta.persistence.NoResultException;
import org.springframework.dao.DataAccessException;

public class AudioPeerReviewEventDaoJpa extends GenericDaoJpa<AudioPeerReviewEvent> implements AudioPeerReviewEventDao {
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ai/elimu/dao/jpa/ContributorDaoJpa.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import java.util.Calendar;
import java.util.List;
import javax.persistence.NoResultException;
import jakarta.persistence.NoResultException;
import ai.elimu.dao.ContributorDao;

import org.springframework.dao.DataAccessException;
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ai/elimu/dao/jpa/DbMigrationDaoJpa.java
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package ai.elimu.dao.jpa;

import java.util.List;
import javax.persistence.NoResultException;
import jakarta.persistence.NoResultException;
import ai.elimu.dao.DbMigrationDao;

import org.springframework.dao.DataAccessException;
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ai/elimu/dao/jpa/DeviceDaoJpa.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package ai.elimu.dao.jpa;

import javax.persistence.NoResultException;
import jakarta.persistence.NoResultException;
import ai.elimu.dao.DeviceDao;

import org.springframework.dao.DataAccessException;
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ai/elimu/dao/jpa/EmojiDaoJpa.java
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package ai.elimu.dao.jpa;

import java.util.List;
import javax.persistence.NoResultException;
import jakarta.persistence.NoResultException;
import ai.elimu.dao.EmojiDao;

import org.springframework.dao.DataAccessException;
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/ai/elimu/dao/jpa/GenericDaoJpa.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
import java.lang.reflect.Type;
import java.util.List;

import javax.persistence.EntityManager;
import javax.persistence.PersistenceContext;
import jakarta.persistence.EntityManager;
import jakarta.persistence.PersistenceContext;

import org.springframework.dao.DataAccessException;
import org.springframework.stereotype.Repository;
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ai/elimu/dao/jpa/ImageDaoJpa.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import java.util.List;

import javax.persistence.NoResultException;
import jakarta.persistence.NoResultException;

import org.springframework.dao.DataAccessException;

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ai/elimu/dao/jpa/LetterDaoJpa.java
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package ai.elimu.dao.jpa;

import java.util.List;
import javax.persistence.NoResultException;
import jakarta.persistence.NoResultException;
import ai.elimu.dao.LetterDao;

import org.springframework.dao.DataAccessException;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import ai.elimu.model.analytics.LetterLearningEvent;
import ai.elimu.model.content.Letter;
import java.util.Calendar;
import javax.persistence.NoResultException;
import jakarta.persistence.NoResultException;
import org.springframework.dao.DataAccessException;

public class LetterLearningEventDaoJpa extends GenericDaoJpa<LetterLearningEvent> implements LetterLearningEventDao {
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ai/elimu/dao/jpa/NumberDaoJpa.java
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package ai.elimu.dao.jpa;

import java.util.List;
import javax.persistence.NoResultException;
import jakarta.persistence.NoResultException;

import org.springframework.dao.DataAccessException;

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ai/elimu/dao/jpa/SoundDaoJpa.java
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package ai.elimu.dao.jpa;

import java.util.List;
import javax.persistence.NoResultException;
import jakarta.persistence.NoResultException;
import ai.elimu.model.content.Sound;

import org.springframework.dao.DataAccessException;
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ai/elimu/dao/jpa/StoryBookDaoJpa.java
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package ai.elimu.dao.jpa;

import java.util.List;
import javax.persistence.NoResultException;
import jakarta.persistence.NoResultException;
import ai.elimu.dao.StoryBookDao;

import org.springframework.dao.DataAccessException;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import ai.elimu.model.content.StoryBook;
import java.util.Calendar;
import java.util.List;
import javax.persistence.NoResultException;
import jakarta.persistence.NoResultException;
import org.springframework.dao.DataAccessException;

public class StoryBookLearningEventDaoJpa extends GenericDaoJpa<StoryBookLearningEvent> implements StoryBookLearningEventDao {
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ai/elimu/dao/jpa/SyllableDaoJpa.java
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package ai.elimu.dao.jpa;

import java.util.List;
import javax.persistence.NoResultException;
import jakarta.persistence.NoResultException;
import ai.elimu.dao.SyllableDao;

import org.springframework.dao.DataAccessException;
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/ai/elimu/dao/jpa/VideoDaoJpa.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import java.util.List;

import javax.persistence.NoResultException;
import jakarta.persistence.NoResultException;
import ai.elimu.dao.VideoDao;

import org.springframework.dao.DataAccessException;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import java.util.Calendar;
import java.util.List;

import javax.persistence.NoResultException;
import jakarta.persistence.NoResultException;
import org.springframework.dao.DataAccessException;

public class VideoLearningEventDaoJpa extends GenericDaoJpa<VideoLearningEvent> implements VideoLearningEventDao {
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/ai/elimu/dao/jpa/WordDaoJpa.java
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package ai.elimu.dao.jpa;

import java.util.List;
import javax.persistence.NoResultException;
import javax.persistence.Query;
import jakarta.persistence.NoResultException;
import jakarta.persistence.Query;

import ai.elimu.model.v2.enums.content.WordType;
import org.springframework.dao.DataAccessException;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import ai.elimu.model.analytics.WordLearningEvent;
import ai.elimu.model.content.Word;
import java.util.Calendar;
import javax.persistence.NoResultException;
import jakarta.persistence.NoResultException;
import org.springframework.dao.DataAccessException;

public class WordLearningEventDaoJpa extends GenericDaoJpa<WordLearningEvent> implements WordLearningEventDao {
Expand Down
8 changes: 4 additions & 4 deletions src/main/java/ai/elimu/model/BaseEntity.java
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
package ai.elimu.model;

import java.io.Serializable;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.MappedSuperclass;
import jakarta.persistence.GeneratedValue;
import jakarta.persistence.GenerationType;
import jakarta.persistence.Id;
import jakarta.persistence.MappedSuperclass;

@MappedSuperclass
public abstract class BaseEntity implements Serializable {
Expand Down
8 changes: 4 additions & 4 deletions src/main/java/ai/elimu/model/DbMigration.java
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
package ai.elimu.model;

import java.util.Calendar;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
import jakarta.persistence.Column;
import jakarta.persistence.Entity;
import jakarta.persistence.Temporal;
import jakarta.persistence.TemporalType;
import javax.validation.constraints.NotNull;

@Entity
Expand Down
8 changes: 4 additions & 4 deletions src/main/java/ai/elimu/model/Device.java
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
package ai.elimu.model;

import java.util.Calendar;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
import jakarta.persistence.Column;
import jakarta.persistence.Entity;
import jakarta.persistence.Temporal;
import jakarta.persistence.TemporalType;
import javax.validation.constraints.NotNull;

@Entity
Expand Down
12 changes: 6 additions & 6 deletions src/main/java/ai/elimu/model/admin/Application.java
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
package ai.elimu.model.admin;

import java.util.Set;
import javax.persistence.ElementCollection;
import javax.persistence.Entity;
import javax.persistence.EnumType;
import javax.persistence.Enumerated;
import javax.persistence.FetchType;
import javax.persistence.ManyToOne;
import jakarta.persistence.ElementCollection;
import jakarta.persistence.Entity;
import jakarta.persistence.EnumType;
import jakarta.persistence.Enumerated;
import jakarta.persistence.FetchType;
import jakarta.persistence.ManyToOne;
import javax.validation.constraints.NotNull;
import ai.elimu.model.BaseEntity;
import ai.elimu.model.contributor.Contributor;
Expand Down
12 changes: 6 additions & 6 deletions src/main/java/ai/elimu/model/admin/ApplicationVersion.java
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
package ai.elimu.model.admin;

import java.util.Calendar;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Lob;
import javax.persistence.ManyToOne;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
import jakarta.persistence.Column;
import jakarta.persistence.Entity;
import jakarta.persistence.Lob;
import jakarta.persistence.ManyToOne;
import jakarta.persistence.Temporal;
import jakarta.persistence.TemporalType;
import javax.validation.constraints.NotNull;
import ai.elimu.model.BaseEntity;
import ai.elimu.model.contributor.Contributor;
Expand Down
14 changes: 7 additions & 7 deletions src/main/java/ai/elimu/model/analytics/LearningEvent.java
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@
import ai.elimu.model.v2.enums.analytics.LearningEventType;
import java.util.Calendar;

import javax.persistence.Column;
import javax.persistence.EnumType;
import javax.persistence.Enumerated;
import javax.persistence.ManyToOne;
import javax.persistence.MappedSuperclass;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
import jakarta.persistence.Column;
import jakarta.persistence.EnumType;
import jakarta.persistence.Enumerated;
import jakarta.persistence.ManyToOne;
import jakarta.persistence.MappedSuperclass;
import jakarta.persistence.Temporal;
import jakarta.persistence.TemporalType;
import javax.validation.constraints.NotNull;

@MappedSuperclass
Expand Down
Loading

0 comments on commit 7d73179

Please sign in to comment.