From 305fc37a0e09e9ecafe4d84bcf01c525edd91c87 Mon Sep 17 00:00:00 2001 From: JoseBaezx Date: Wed, 11 May 2022 11:57:44 -0400 Subject: [PATCH] Se cambia dependencia javax por jakarta --- .idea/vcs.xml | 6 ++++++ pom.xml | 6 +++--- src/main/java/com/roshka/proyectofinal/HelloServlet.java | 14 +++++++------- 3 files changed, 16 insertions(+), 10 deletions(-) create mode 100644 .idea/vcs.xml diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 0000000..94a25f7 --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/pom.xml b/pom.xml index 2887850..967ae10 100644 --- a/pom.xml +++ b/pom.xml @@ -19,9 +19,9 @@ - javax.servlet - javax.servlet-api - 4.0.1 + jakarta.servlet + jakarta.servlet-api + 5.0.0 provided diff --git a/src/main/java/com/roshka/proyectofinal/HelloServlet.java b/src/main/java/com/roshka/proyectofinal/HelloServlet.java index 37d63ca..52997b6 100644 --- a/src/main/java/com/roshka/proyectofinal/HelloServlet.java +++ b/src/main/java/com/roshka/proyectofinal/HelloServlet.java @@ -1,16 +1,16 @@ package com.roshka.proyectofinal; +import jakarta.servlet.annotation.WebServlet; +import jakarta.servlet.http.HttpServlet; +import jakarta.servlet.http.HttpServletRequest; +import jakarta.servlet.http.HttpServletResponse; + import java.io.*; -import javax.servlet.http.*; -import javax.servlet.annotation.*; + @WebServlet(name = "helloServlet", value = "/hello-servlet") public class HelloServlet extends HttpServlet { - private String message; - - public void init() { - message = "Hello World!"; - } + private String message="HOLA"; public void doGet(HttpServletRequest request, HttpServletResponse response) throws IOException { response.setContentType("text/html"); -- libgit2 0.26.0