change generator http method
This commit is contained in:
parent
2844619423
commit
e267e0c55c
@ -24,7 +24,6 @@ dependencies {
|
|||||||
ext {
|
ext {
|
||||||
versionSLF4J = '1.7.24'
|
versionSLF4J = '1.7.24'
|
||||||
versionJetty = '9.3.16.v20170120'
|
versionJetty = '9.3.16.v20170120'
|
||||||
versionJackson = '2.9.4'
|
|
||||||
}
|
}
|
||||||
|
|
||||||
implementation group: 'org.springframework.boot', name: 'spring-boot-starter-web'
|
implementation group: 'org.springframework.boot', name: 'spring-boot-starter-web'
|
||||||
@ -35,9 +34,9 @@ dependencies {
|
|||||||
implementation group: 'org.javassist', name: 'javassist', version: '3.25.0-GA'
|
implementation group: 'org.javassist', name: 'javassist', version: '3.25.0-GA'
|
||||||
implementation group: 'org.eclipse.jetty', name: 'jetty-servlet', version: versionJetty
|
implementation group: 'org.eclipse.jetty', name: 'jetty-servlet', version: versionJetty
|
||||||
|
|
||||||
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version: versionJackson
|
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-databind'
|
||||||
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-annotations', version: versionJackson
|
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-annotations'
|
||||||
implementation group: 'com.fasterxml.jackson.datatype', name: 'jackson-datatype-jsr310', version: versionJackson
|
implementation group: 'com.fasterxml.jackson.datatype', name: 'jackson-datatype-jsr310'
|
||||||
|
|
||||||
implementation group: 'org.springdoc', name: 'springdoc-openapi-ui', version: '1.6.5'
|
implementation group: 'org.springdoc', name: 'springdoc-openapi-ui', version: '1.6.5'
|
||||||
|
|
||||||
|
@ -12,6 +12,7 @@ import org.springframework.web.bind.annotation.RestController;
|
|||||||
import ru.ulstu.configuration.ApiConfiguration;
|
import ru.ulstu.configuration.ApiConfiguration;
|
||||||
import ru.ulstu.datamodel.ts.TimeSeries;
|
import ru.ulstu.datamodel.ts.TimeSeries;
|
||||||
import ru.ulstu.service.UtilService;
|
import ru.ulstu.service.UtilService;
|
||||||
|
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
@RestController
|
@RestController
|
||||||
@ -30,7 +31,7 @@ public class UtilController {
|
|||||||
return new ResponseEntity<>(Map.of("result", true), HttpStatus.OK);
|
return new ResponseEntity<>(Map.of("result", true), HttpStatus.OK);
|
||||||
}
|
}
|
||||||
|
|
||||||
@GetMapping("getRandom")
|
@PostMapping("getRandom")
|
||||||
@Operation(description = "Получить временной ряд рандомной длины")
|
@Operation(description = "Получить временной ряд рандомной длины")
|
||||||
public ResponseEntity<TimeSeries> getRandomTimeSeries(@RequestParam("length") int length) {
|
public ResponseEntity<TimeSeries> getRandomTimeSeries(@RequestParam("length") int length) {
|
||||||
return new ResponseEntity<>(utilService.getRandomTimeSeries(length), HttpStatus.OK);
|
return new ResponseEntity<>(utilService.getRandomTimeSeries(length), HttpStatus.OK);
|
||||||
|
Loading…
Reference in New Issue
Block a user