Skip to content

Extend existed rules. Add rules for openapi - #3

Open
D-Baykov wants to merge 3 commits into
masterfrom
ft/add/pr-1
Open

Extend existed rules. Add rules for openapi#3
D-Baykov wants to merge 3 commits into
masterfrom
ft/add/pr-1

Conversation

@D-Baykov

Copy link
Copy Markdown

No description provided.

Comment thread rules/code-conventions.md Outdated

## Architecture and dependencies

- Transport adapters handle protocol concerns only: they validate the transport

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Тут я бы написал Transport resources - мы скорее их ресурсами везде зовем

Comment thread rules/code-conventions.md Outdated

- Transport adapters handle protocol concerns only: they validate the transport
contract, delegate to a service, and translate failures into protocol errors.
- Services implement business scenarios, define the order of operations, and own

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Вот тут на счет транзакций я бы убрал и написал отдельно про то что транзакции реализуются на минимально возможном слое, если ее можно запереть в рамках метода репозитория я бы оставлял ее там и только для более сложных разрешал выносить в сервисы с учетом только реально необходимых вызовов внутри транзакции (тк я сталскивался с засовыванием им туда всего что попало вплоть удаленных вызовов)

Comment thread rules/code-conventions.md Outdated
`Map<String, Any>`.
- Transport models are converted before reaching repositories. Simple entities may
use generated persistence models; aggregates use local domain models.
- JSON property names are specified with Jackson annotations, and closed sets of

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

тут точно надо добавить что они именуются аннотациями только если имя не совпадает с названием переменной иначе бесявые анотации везде

Comment thread rules/code-conventions.md Outdated
Comment on lines +31 to +33
- Model conversion is performed by dedicated `@Component` classes implementing
Spring's `Converter<S, T>`.
- Requests and responses are created by converters.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

как будто 2 раза один и тот же смысл, первого достаточно либо туда добавить в том числе и Requests and responses

Comment thread rules/code-conventions.md Outdated
- Optional fields are set only when present. An omitted value and an explicitly
empty value remain distinct when the API contract distinguishes them.
- Unsupported conversion directions fail explicitly instead of returning `null`.
- Concrete converters are provided through constructor injection.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

наверное достаточно одного общего правила оно кажется было выше, что все спринг объекты так добавляются

Comment thread rules/database-conventions.md Outdated
- Storage invariants use database defaults and `NOT NULL` constraints and are also
represented consistently in converters and repositories.
- Flyway and ShedLock tables are excluded from jOOQ code generation.
- No foreign keys are used.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

вот это тоже у нас не строго на самом деле иногда использовали, я бы наверно убрал из общих и в рамках каждого сервиса отдельно принимал решения

Comment thread rules/database-conventions.md Outdated
Comment on lines +24 to +25
- A schema change is traced through migration, generated model, input conversion,
write query, read model, output conversion, and tests.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

вот этот пункт поясни, не смог понять что это значит

Comment thread rules/profiles/adapter.md Outdated

## Configuration and clients

- Application settings use typed `@ConfigurationProperties` with `@Validated` and

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

вроде уже есть в основном

Comment thread rules/profiles/adapter.md
Comment on lines +53 to +57
- Missing continuation state creates a new context; malformed state fails explicitly.
- Serialized context changes are backward compatible with states produced by the
previous deployed version and are covered by compatibility tests.
- Polling metadata, including the deadline and next interval, is stored with the
operation state.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

вот тут как бы не было косяков тк там есть пара мест для хрнения контекста которые в рамках некоторых сценариев отличают (где то пропадает котекст и надо пихать глубже)

Comment thread rules/profiles/adapter.md
callback replay.
- Tests assert outbound method, path, headers, and body as well as the mapped result.
- Shared flow fixtures and builders contain transport mechanics; test cases describe
scenario-specific mocks, actions, and assertions.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

я бы тут еще добавил про то что необходимо операться на шаблоны и стараться минимизировать изменения и максимально переиспользовать уже реализованное

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants