Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consolidate sensor api #260

Open
wants to merge 7 commits into
base: main
Choose a base branch
from
Open

Consolidate sensor api #260

wants to merge 7 commits into from

Conversation

Mryashbhardwaj
Copy link
Member

@Mryashbhardwaj Mryashbhardwaj commented Aug 1, 2024

Proton: goto/proton#120

const ExternalUpstreamEntity = "ExternalResourceInterface"

// NewExternalOptimusManager creates a new instance of externalResourceResolver
func NewExternalOptimusManager(resourceManagerConfigs []config.ResourceManager) (*ExternalOptimusConnectors, error) {
Copy link
Member

Choose a reason for hiding this comment

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

can we reuse NewExternalUpstreamResolver on job BC?
we can provide interface specific to this use cases (GetJobScheduleInterval and GetJobRuns)

Copy link
Member Author

Choose a reason for hiding this comment

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

Then we will be sending request to Job BC from Scheduler BC, even though when the Interface is diffrent.

what is your reason ?

Copy link
Member

@deryrahman deryrahman Aug 5, 2024

Choose a reason for hiding this comment

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

nvm, just want to minimize reimplementation of optimus manager constructor, since it's same with what we have in core/job/resolver/external_upstream_resolver.go, turns out it's used for different purpose, we're using same external manager that comes from package ext. not an issue

return manager, nil
}
}
return nil, errors.NewError(errors.ErrNotFound, ExternalUpstreamEntity, "could not find external resource manager by host: "+hostURL)
Copy link

Choose a reason for hiding this comment

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

Please use errors.NotFound(

@sravankorumilli
Copy link

The current refactoring will not align with the change in approach for the windowing, as it will be a new api altogether.
Hence thinking whether we should use a different approach for ignoring replay request.

As a next step we will not have these many sensors, we will just have one sensor which will depend on data availability for all inputs combined.

Should we implement this differently where job run gets the replay request for a given schedule, if the request has ignore upstreams we can ignore.

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.

4 participants