simcaq-node issueshttps://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues2022-10-31T12:32:51Zhttps://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/18Filtro de ano não funciona2022-10-31T12:32:51ZPietro CavassinFiltro de ano não funcionaArrumar filtros de ano que não funcionamArrumar filtros de ano que não funcionamPietro CavassinPietro Cavassinhttps://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/15Start MongoDB in production2017-06-05T12:19:41ZJoão Victor Rissojvtr12@c3sl.ufpr.brStart MongoDB in productionWith the addition of MongoDB to the database layer, we'll also need a way to run it as service in production environments.With the addition of MongoDB to the database layer, we'll also need a way to run it as service in production environments.Lucas Gabriel LimaLucas Gabriel Limahttps://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/14Return errors in middlewares2017-06-05T12:19:41ZVytor Calixtovsbc14@inf.ufpr.brReturn errors in middlewaresCurrently the query middleware don't handle errors. It's important to return the error and let it be handled appropriately so errors in the DB can be logged and treated.Currently the query middleware don't handle errors. It's important to return the error and let it be handled appropriately so errors in the DB can be logged and treated.Entrega 19/09https://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/13Create views on DB2017-06-05T12:19:42ZVytor Calixtovsbc14@inf.ufpr.brCreate views on DBCreate views with the enrollments queriesCreate views with the enrollments queriesEntrega 19/09Vytor Calixtovsbc14@inf.ufpr.brVytor Calixtovsbc14@inf.ufpr.brhttps://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/12IBGE route is not working2017-06-05T12:19:42ZVytor Calixtovsbc14@inf.ufpr.brIBGE route is not workingNo result get back from the database and the server times out.
Removed the route in 55ff5ecaNo result get back from the database and the server times out.
Removed the route in 55ff5ecaVytor Calixtovsbc14@inf.ufpr.brVytor Calixtovsbc14@inf.ufpr.brhttps://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/11Implement development tasks using Gulp2017-06-05T12:19:42ZJoão Victor Rissojvtr12@c3sl.ufpr.brImplement development tasks using GulpImplement the following tasks using [Gulp](https://github.com/gulpjs/gulp/tree/master/docs):
* Transcompile the project from ECMASCript6 to ECMAScript5 into the build directory
* Compile the project, watch for changes and recompile
* Run...Implement the following tasks using [Gulp](https://github.com/gulpjs/gulp/tree/master/docs):
* Transcompile the project from ECMASCript6 to ECMAScript5 into the build directory
* Compile the project, watch for changes and recompile
* Run the node server using forever or other process manager
* Run tests automaticallyLucas Gabriel LimaLucas Gabriel Limahttps://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/10Refactor database querying2017-06-05T12:19:42ZJoão Victor Rissojvtr12@c3sl.ufpr.brRefactor database querying* Add support for (semi-)automatic SQL generation using [squel.js](https://hiddentao.com/squel/).
* Create a module/class to make the queries to the database. Currently, for every route the same code is replicated to make the query again...* Add support for (semi-)automatic SQL generation using [squel.js](https://hiddentao.com/squel/).
* Create a module/class to make the queries to the database. Currently, for every route the same code is replicated to make the query against the database. Since that code is pretty much the same in each route, there is a good potential for a rewrite as a module/class, preferably using [Promises](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise).https://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/9Enrollments route not working2017-06-05T12:19:42ZVytor Calixtovsbc14@inf.ufpr.brEnrollments route not workingThere isn't a mat_brasil table or view in the database anymore. Is this correct?There isn't a mat_brasil table or view in the database anymore. Is this correct?João Victor Rissojvtr12@c3sl.ufpr.brJoão Victor Rissojvtr12@c3sl.ufpr.brhttps://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/8Server-Side Caching2017-06-05T12:19:42ZJoão Victor Rissojvtr12@c3sl.ufpr.brServer-Side Caching# API cache
[NPM apicache library](https://www.npmjs.com/package/apicache)
# Reverse proxying
Use nginx as reverse proxy as well as a [cache](https://serversforhackers.com/nginx-caching/) for some routes, e.g. cities, states, th...# API cache
[NPM apicache library](https://www.npmjs.com/package/apicache)
# Reverse proxying
Use nginx as reverse proxy as well as a [cache](https://serversforhackers.com/nginx-caching/) for some routes, e.g. cities, states, that will likely never change.
# Database
Use a pool of connections to execute requests concurrently. Currently the API relies on a single connection to the database.
An interesting idea is use MonetDB's own [library for connection pooling](https://github.com/MonetDB/monetdb-pool-nodejs).
# Other guidelines
[Express.js - Performance Best Practices](https://expressjs.com/en/advanced/best-practice-performance.html)João Victor Rissojvtr12@c3sl.ufpr.brJoão Victor Rissojvtr12@c3sl.ufpr.brhttps://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/7Create middleware to handle responses2017-06-05T12:19:42ZVytor Calixtovsbc14@inf.ufpr.brCreate middleware to handle responsesAll the responses have the same code:
```javascript
if (req.query.format === 'csv') {
res.csv(result.data)
} else if (req.query.format === 'xml') {
res.set('Content-Type', 'text/xml')
res.send(xml({
...All the responses have the same code:
```javascript
if (req.query.format === 'csv') {
res.csv(result.data)
} else if (req.query.format === 'xml') {
res.set('Content-Type', 'text/xml')
res.send(xml({
result: result.data
}))
}
else {
res.json({
result: result.data
})
}
```
This can be done by a custom middlewareVytor Calixtovsbc14@inf.ufpr.brVytor Calixtovsbc14@inf.ufpr.brhttps://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/6Wrong XML conversion2017-06-05T12:19:42ZVytor Calixtovsbc14@inf.ufpr.brWrong XML conversionTake the example response in JSON:
```json
{
"result": [
{
"pk_regiao_id": 1,
"nome": "Norte"
},
{
"pk_regiao_id": 2,
"nome": "Nordeste"
},
{
"pk_regiao_id": 3,
"nom...Take the example response in JSON:
```json
{
"result": [
{
"pk_regiao_id": 1,
"nome": "Norte"
},
{
"pk_regiao_id": 2,
"nome": "Nordeste"
},
{
"pk_regiao_id": 3,
"nome": "Sudeste"
},
{
"pk_regiao_id": 4,
"nome": "Sul"
},
{
"pk_regiao_id": 5,
"nome": "Centro-Oeste"
}
]
}
```
This is converted to:
```xml
<result>
<pk_regiao_id>1</pk_regiao_id>
<pk_regiao_id>2</pk_regiao_id>
<pk_regiao_id>3</pk_regiao_id>
<pk_regiao_id>4</pk_regiao_id>
<pk_regiao_id>5</pk_regiao_id>
</result>
```https://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/5Continuous Delivery2017-06-05T12:19:42ZVytor Calixtovsbc14@inf.ufpr.brContinuous DeliveryContinuous delivery to automagically deploy the API to the development VM every commit on masterContinuous delivery to automagically deploy the API to the development VM every commit on masterVytor Calixtovsbc14@inf.ufpr.brVytor Calixtovsbc14@inf.ufpr.brhttps://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/4Add tests to the API2017-06-05T12:19:42ZVytor Calixtovsbc14@inf.ufpr.brAdd tests to the APICheckout [Mocha](https://mochajs.org/), frequently used with NodeJS and Express appsCheckout [Mocha](https://mochajs.org/), frequently used with NodeJS and Express appsLucas Gabriel LimaLucas Gabriel Limahttps://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/3Support different exporting formats2017-06-05T12:19:42ZJoão Victor Rissojvtr12@c3sl.ufpr.brSupport different exporting formatsAdd support for CSV, XLS, XML and other popular output formats to export data beside JSON and JSONP.
Maybe there is support using some npm module and/or in Express itself (must check).Add support for CSV, XLS, XML and other popular output formats to export data beside JSON and JSONP.
Maybe there is support using some npm module and/or in Express itself (must check).Vytor Calixtovsbc14@inf.ufpr.brVytor Calixtovsbc14@inf.ufpr.brhttps://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/2Fix route issues2017-06-05T12:19:42ZJoão Victor Rissojvtr12@c3sl.ufpr.brFix route issuesApplication cannot find routes (return 404), e.g., /matriculas or /dataApplication cannot find routes (return 404), e.g., /matriculas or /datahttps://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/1Handle different queries on matriculas2017-06-05T12:19:42ZJoão Victor Rissojvtr12@c3sl.ufpr.brHandle different queries on matriculasHandle different requests for matriculas:
* general: matriculas(total)
* per-state: matriculas_estado(nome_estado, total)
* per-region: matriculas_regiao(nome_regiao, total)Handle different requests for matriculas:
* general: matriculas(total)
* per-state: matriculas_estado(nome_estado, total)
* per-region: matriculas_regiao(nome_regiao, total)https://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/16Simulation - PUT retornando erro 5002018-03-03T16:11:29ZHugo Leonardohugo.com.h@gmail.comSimulation - PUT retornando erro 500O método [**PUT**](https://simcaq.c3sl.ufpr.br/api/v1/simulation/:id "Simulation PUT") da rota de **Simulação** está retornando erro 500 com o conteúdo abaixo:
```json
{
"error": "Simulation validation failed"
}
```O método [**PUT**](https://simcaq.c3sl.ufpr.br/api/v1/simulation/:id "Simulation PUT") da rota de **Simulação** está retornando erro 500 com o conteúdo abaixo:
```json
{
"error": "Simulation validation failed"
}
```https://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/17v1.1.02018-05-02T13:59:34ZVytor Calixtovsbc14@inf.ufpr.brv1.1.0* [x] População Fora da Escola (94dcf51ca64d6cb46864ab2f92a95b7da440e271)
* [x] Taxa de matrícula bruta
* [x] Taxa de matrícula líquida* [x] População Fora da Escola (94dcf51ca64d6cb46864ab2f92a95b7da440e271)
* [x] Taxa de matrícula bruta
* [x] Taxa de matrícula líquidahttps://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/19Rota com Integral_time ="true" retorna erro2023-03-09T13:11:34Zems19Rota com Integral_time ="true" retorna erroAo usar a Rota API PRD "https://simcaq.c3sl.ufpr.br/api/v1/enrollment?filter=min_year:1991,max_year:2019,integral_time:%22true%22,education_level_short:[%221%22,%222%22,%223%22,%224%22,%225%22],adm_dependency:[%221%22,%222%22,%223%22]&ed...Ao usar a Rota API PRD "https://simcaq.c3sl.ufpr.br/api/v1/enrollment?filter=min_year:1991,max_year:2019,integral_time:%22true%22,education_level_short:[%221%22,%222%22,%223%22,%224%22,%225%22],adm_dependency:[%221%22,%222%22,%223%22]&education_level_short,integral_time&format=csv", recebemos um erro
E o console log acusa a consulta BD integral_time = NaNPietro CavassinPietro Cavassinhttps://gitlab.c3sl.ufpr.br/simcaq/simcaq-node/-/issues/20Migrar o banco de dados MongoDB da API para PostgreSQL.2023-08-14T13:07:03Zems19Migrar o banco de dados MongoDB da API para PostgreSQL.ems19ems19