Skip to content

Commit

Permalink
Cleaned up
Browse files Browse the repository at this point in the history
  • Loading branch information
otaviocap committed Sep 20, 2021
1 parent 6aef0e1 commit e7b51a7
Show file tree
Hide file tree
Showing 12 changed files with 6 additions and 108 deletions.
6 changes: 0 additions & 6 deletions Dockerfile

This file was deleted.

8 changes: 5 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# Backend

## Installation

## Alterations

Setted max retention time in kafka to 1 minute
To install please compile everything using:
```
python3 safeBuild.py --containers all --update-commons --env dev
```
24 changes: 0 additions & 24 deletions build-containers.sh

This file was deleted.

4 changes: 0 additions & 4 deletions compile-and-go.sh

This file was deleted.

File renamed without changes.
2 changes: 0 additions & 2 deletions services/gateway/gateway/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,7 @@

CONNECTIONS = [
'connections.login',
'connections.products',
'connections.users',
'connections.report',
]

LOCAL_APPS = [
Expand Down
2 changes: 0 additions & 2 deletions services/gateway/gateway/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,5 @@

urlpatterns = [
path('api/', include('connections.login.urls')),
path('api/', include('connections.products.urls')),
path('api/', include('connections.users.urls')),
path('api/', include('connections.report.urls')),
]
59 changes: 1 addition & 58 deletions services/login/modules/api/actions.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,6 @@
from common.error.error import ActionError
from common.error.handling import handleError, checkError
from common.error.handling import handleError
from common.models.message import Message
from common.kafka.actions import ActionHandler
from common.kafka.send import async_send_and_wait_message, send_message

import asyncio


actioneer = ActionHandler()
Expand All @@ -13,59 +9,6 @@
async def auth(message: Message):
message.data["JWToken"] = "fake-token-jwt"

@actioneer.register
async def self(message: Message):
data = await async_send_and_wait_message(
service="login",
action="auth",
data=message.data,
)
message.data = data['data']

@actioneer.register
async def whyAsync(message: Message):
await asyncio.sleep(5)

@actioneer.register
async def teste123(message: Message):
message.data["teste"] = "VALOR DE TESTE"

@actioneer.register
async def testForError(message: Message):

try:
print("1")
await async_send_and_wait_message(
service="products",
action="comeback",
data=message.data,
)

print("2")
message = await async_send_and_wait_message(
service="products",
action="345",
data=message.data,
)

print("3")
send_message(
service="login",
action="345",
data=message.data,
)

await asyncio.sleep(1)

message.data["ok"] = "ended cycle"

except ActionError as ex:
handleError(
message,
information=ex.args[0],
where="login"
)

@actioneer.default
async def default(message: Message):
handleError(
Expand Down
3 changes: 0 additions & 3 deletions services/login/modules/api/views.py

This file was deleted.

3 changes: 0 additions & 3 deletions services/users/modules/api/views.py

This file was deleted.

Empty file.
3 changes: 0 additions & 3 deletions services/users/modules/database/models.py

This file was deleted.

0 comments on commit e7b51a7

Please sign in to comment.