FetchingService

gitinsp.domain.interfaces.infrastructure.FetchingService

Service for handling HTTP communication with external resources Provides a generic interface for fetching content from URLs with configurable parameters

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any

Members list

Value members

Abstract methods

def fetchUrl(url: String, connectTimeout: Int, readTimeout: Int, requestMethod: String, headers: Map[String, String]): Try[String]

Fetches content from a specified URL with custom HTTP settings

Fetches content from a specified URL with custom HTTP settings

Value parameters

connectTimeout

Maximum time to wait for connection in milliseconds

headers

Map of HTTP headers to include in the request

readTimeout

Maximum time to wait for data in milliseconds

requestMethod

HTTP method to use (GET, POST, etc.)

url

The URL to fetch content from

Attributes

Returns

The content of the URL response as a string wrapped in a Try