Oracle Cloud Infrastructure v3.7.0 published on Saturday, Sep 13, 2025 by Pulumi
oci.ApmTraces.getLog
Explore with Pulumi AI
This data source provides details about a specific Log resource in Oracle Cloud Infrastructure Apm Traces service.
Retrieve a log in the APM Domain.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";
const testLog = oci.ApmTraces.getLog({
apmDomainId: testApmDomain.id,
logKey: logLogKey,
timeLogEndedLessThan: logTimeLogEndedLessThan,
timeLogStartedGreaterThanOrEqualTo: logTimeLogStartedGreaterThanOrEqualTo,
});
import pulumi
import pulumi_oci as oci
test_log = oci.ApmTraces.get_log(apm_domain_id=test_apm_domain["id"],
log_key=log_log_key,
time_log_ended_less_than=log_time_log_ended_less_than,
time_log_started_greater_than_or_equal_to=log_time_log_started_greater_than_or_equal_to)
package main
import (
"github.com/pulumi/pulumi-oci/sdk/v3/go/oci/apmtraces"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := apmtraces.GetLog(ctx, &apmtraces.GetLogArgs{
ApmDomainId: testApmDomain.Id,
LogKey: logLogKey,
TimeLogEndedLessThan: logTimeLogEndedLessThan,
TimeLogStartedGreaterThanOrEqualTo: logTimeLogStartedGreaterThanOrEqualTo,
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Oci = Pulumi.Oci;
return await Deployment.RunAsync(() =>
{
var testLog = Oci.ApmTraces.GetLog.Invoke(new()
{
ApmDomainId = testApmDomain.Id,
LogKey = logLogKey,
TimeLogEndedLessThan = logTimeLogEndedLessThan,
TimeLogStartedGreaterThanOrEqualTo = logTimeLogStartedGreaterThanOrEqualTo,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.ApmTraces.ApmTracesFunctions;
import com.pulumi.oci.ApmTraces.inputs.GetLogArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var testLog = ApmTracesFunctions.getLog(GetLogArgs.builder()
.apmDomainId(testApmDomain.id())
.logKey(logLogKey)
.timeLogEndedLessThan(logTimeLogEndedLessThan)
.timeLogStartedGreaterThanOrEqualTo(logTimeLogStartedGreaterThanOrEqualTo)
.build());
}
}
variables:
testLog:
fn::invoke:
function: oci:ApmTraces:getLog
arguments:
apmDomainId: ${testApmDomain.id}
logKey: ${logLogKey}
timeLogEndedLessThan: ${logTimeLogEndedLessThan}
timeLogStartedGreaterThanOrEqualTo: ${logTimeLogStartedGreaterThanOrEqualTo}
Using getLog
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getLog(args: GetLogArgs, opts?: InvokeOptions): Promise<GetLogResult>
function getLogOutput(args: GetLogOutputArgs, opts?: InvokeOptions): Output<GetLogResult>
def get_log(apm_domain_id: Optional[str] = None,
log_key: Optional[str] = None,
time_log_ended_less_than: Optional[str] = None,
time_log_started_greater_than_or_equal_to: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetLogResult
def get_log_output(apm_domain_id: Optional[pulumi.Input[str]] = None,
log_key: Optional[pulumi.Input[str]] = None,
time_log_ended_less_than: Optional[pulumi.Input[str]] = None,
time_log_started_greater_than_or_equal_to: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetLogResult]
func GetLog(ctx *Context, args *GetLogArgs, opts ...InvokeOption) (*GetLogResult, error)
func GetLogOutput(ctx *Context, args *GetLogOutputArgs, opts ...InvokeOption) GetLogResultOutput
> Note: This function is named GetLog
in the Go SDK.
public static class GetLog
{
public static Task<GetLogResult> InvokeAsync(GetLogArgs args, InvokeOptions? opts = null)
public static Output<GetLogResult> Invoke(GetLogInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetLogResult> getLog(GetLogArgs args, InvokeOptions options)
public static Output<GetLogResult> getLog(GetLogArgs args, InvokeOptions options)
fn::invoke:
function: oci:ApmTraces/getLog:getLog
arguments:
# arguments dictionary
The following arguments are supported:
- Apm
Domain stringId - The APM Domain ID for the intended request.
- Log
Key string - Log key.
- Time
Log stringEnded Less Than - Include logs with log time less than this value.
- Time
Log stringStarted Greater Than Or Equal To - Include logs with log time equal to or greater than this value.
- Apm
Domain stringId - The APM Domain ID for the intended request.
- Log
Key string - Log key.
- Time
Log stringEnded Less Than - Include logs with log time less than this value.
- Time
Log stringStarted Greater Than Or Equal To - Include logs with log time equal to or greater than this value.
- apm
Domain StringId - The APM Domain ID for the intended request.
- log
Key String - Log key.
- time
Log StringEnded Less Than - Include logs with log time less than this value.
- time
Log StringStarted Greater Than Or Equal To - Include logs with log time equal to or greater than this value.
- apm
Domain stringId - The APM Domain ID for the intended request.
- log
Key string - Log key.
- time
Log stringEnded Less Than - Include logs with log time less than this value.
- time
Log stringStarted Greater Than Or Equal To - Include logs with log time equal to or greater than this value.
- apm_
domain_ strid - The APM Domain ID for the intended request.
- log_
key str - Log key.
- time_
log_ strended_ less_ than - Include logs with log time less than this value.
- time_
log_ strstarted_ greater_ than_ or_ equal_ to - Include logs with log time equal to or greater than this value.
- apm
Domain StringId - The APM Domain ID for the intended request.
- log
Key String - Log key.
- time
Log StringEnded Less Than - Include logs with log time less than this value.
- time
Log StringStarted Greater Than Or Equal To - Include logs with log time equal to or greater than this value.
getLog Result
The following output properties are available:
- Apm
Domain stringId - Attribute
Metadata Dictionary<string, string> - Metadata about the attributes in the logs.
- Attributes
List<Get
Log Attribute> - List of attributes associated with the logs.
- Body string
- Log body (Body).
- Event
Name string - Name of the event.
- Id string
- The provider-assigned unique ID for this managed resource.
- Log
Key string - Unique identifier (logId) for the logKey. Note that this field is defined as logKey in the API and it maps to the logId in Application Performance Monitoring.
- Overflow
Attributes string - Full values for attributes that are too long to be stored as a log attribute (Overflow).
- Severity
Number int - Log Severity number (SeverityNumber).
- Severity
Text string - Log Severity text (SeverityText). Also known as Log level.
- Span
Key string - Unique identifier for the span (spanId) associated with this log.
- Time
Created string - Time that the log event occurred (CreatedTime).
- Time
Log stringEnded Less Than - Time
Log stringStarted Greater Than Or Equal To - Time
Observed string - Time that the log was received by apm (ObservedTime).
- Timestamp string
- Time used by the time picker (RecordedTime). Either the timeCreated if present or the timeObserved.
- Trace
Flags int - Trace flags.
- Trace
Key string - Unique identifier for the trace (traceId) associated with this log.
- Apm
Domain stringId - Attribute
Metadata map[string]string - Metadata about the attributes in the logs.
- Attributes
[]Get
Log Attribute - List of attributes associated with the logs.
- Body string
- Log body (Body).
- Event
Name string - Name of the event.
- Id string
- The provider-assigned unique ID for this managed resource.
- Log
Key string - Unique identifier (logId) for the logKey. Note that this field is defined as logKey in the API and it maps to the logId in Application Performance Monitoring.
- Overflow
Attributes string - Full values for attributes that are too long to be stored as a log attribute (Overflow).
- Severity
Number int - Log Severity number (SeverityNumber).
- Severity
Text string - Log Severity text (SeverityText). Also known as Log level.
- Span
Key string - Unique identifier for the span (spanId) associated with this log.
- Time
Created string - Time that the log event occurred (CreatedTime).
- Time
Log stringEnded Less Than - Time
Log stringStarted Greater Than Or Equal To - Time
Observed string - Time that the log was received by apm (ObservedTime).
- Timestamp string
- Time used by the time picker (RecordedTime). Either the timeCreated if present or the timeObserved.
- Trace
Flags int - Trace flags.
- Trace
Key string - Unique identifier for the trace (traceId) associated with this log.
- apm
Domain StringId - attribute
Metadata Map<String,String> - Metadata about the attributes in the logs.
- attributes
List<Get
Log Attribute> - List of attributes associated with the logs.
- body String
- Log body (Body).
- event
Name String - Name of the event.
- id String
- The provider-assigned unique ID for this managed resource.
- log
Key String - Unique identifier (logId) for the logKey. Note that this field is defined as logKey in the API and it maps to the logId in Application Performance Monitoring.
- overflow
Attributes String - Full values for attributes that are too long to be stored as a log attribute (Overflow).
- severity
Number Integer - Log Severity number (SeverityNumber).
- severity
Text String - Log Severity text (SeverityText). Also known as Log level.
- span
Key String - Unique identifier for the span (spanId) associated with this log.
- time
Created String - Time that the log event occurred (CreatedTime).
- time
Log StringEnded Less Than - time
Log StringStarted Greater Than Or Equal To - time
Observed String - Time that the log was received by apm (ObservedTime).
- timestamp String
- Time used by the time picker (RecordedTime). Either the timeCreated if present or the timeObserved.
- trace
Flags Integer - Trace flags.
- trace
Key String - Unique identifier for the trace (traceId) associated with this log.
- apm
Domain stringId - attribute
Metadata {[key: string]: string} - Metadata about the attributes in the logs.
- attributes
Get
Log Attribute[] - List of attributes associated with the logs.
- body string
- Log body (Body).
- event
Name string - Name of the event.
- id string
- The provider-assigned unique ID for this managed resource.
- log
Key string - Unique identifier (logId) for the logKey. Note that this field is defined as logKey in the API and it maps to the logId in Application Performance Monitoring.
- overflow
Attributes string - Full values for attributes that are too long to be stored as a log attribute (Overflow).
- severity
Number number - Log Severity number (SeverityNumber).
- severity
Text string - Log Severity text (SeverityText). Also known as Log level.
- span
Key string - Unique identifier for the span (spanId) associated with this log.
- time
Created string - Time that the log event occurred (CreatedTime).
- time
Log stringEnded Less Than - time
Log stringStarted Greater Than Or Equal To - time
Observed string - Time that the log was received by apm (ObservedTime).
- timestamp string
- Time used by the time picker (RecordedTime). Either the timeCreated if present or the timeObserved.
- trace
Flags number - Trace flags.
- trace
Key string - Unique identifier for the trace (traceId) associated with this log.
- apm_
domain_ strid - attribute_
metadata Mapping[str, str] - Metadata about the attributes in the logs.
- attributes
Sequence[Get
Log Attribute] - List of attributes associated with the logs.
- body str
- Log body (Body).
- event_
name str - Name of the event.
- id str
- The provider-assigned unique ID for this managed resource.
- log_
key str - Unique identifier (logId) for the logKey. Note that this field is defined as logKey in the API and it maps to the logId in Application Performance Monitoring.
- overflow_
attributes str - Full values for attributes that are too long to be stored as a log attribute (Overflow).
- severity_
number int - Log Severity number (SeverityNumber).
- severity_
text str - Log Severity text (SeverityText). Also known as Log level.
- span_
key str - Unique identifier for the span (spanId) associated with this log.
- time_
created str - Time that the log event occurred (CreatedTime).
- time_
log_ strended_ less_ than - time_
log_ strstarted_ greater_ than_ or_ equal_ to - time_
observed str - Time that the log was received by apm (ObservedTime).
- timestamp str
- Time used by the time picker (RecordedTime). Either the timeCreated if present or the timeObserved.
- trace_
flags int - Trace flags.
- trace_
key str - Unique identifier for the trace (traceId) associated with this log.
- apm
Domain StringId - attribute
Metadata Map<String> - Metadata about the attributes in the logs.
- attributes List<Property Map>
- List of attributes associated with the logs.
- body String
- Log body (Body).
- event
Name String - Name of the event.
- id String
- The provider-assigned unique ID for this managed resource.
- log
Key String - Unique identifier (logId) for the logKey. Note that this field is defined as logKey in the API and it maps to the logId in Application Performance Monitoring.
- overflow
Attributes String - Full values for attributes that are too long to be stored as a log attribute (Overflow).
- severity
Number Number - Log Severity number (SeverityNumber).
- severity
Text String - Log Severity text (SeverityText). Also known as Log level.
- span
Key String - Unique identifier for the span (spanId) associated with this log.
- time
Created String - Time that the log event occurred (CreatedTime).
- time
Log StringEnded Less Than - time
Log StringStarted Greater Than Or Equal To - time
Observed String - Time that the log was received by apm (ObservedTime).
- timestamp String
- Time used by the time picker (RecordedTime). Either the timeCreated if present or the timeObserved.
- trace
Flags Number - Trace flags.
- trace
Key String - Unique identifier for the trace (traceId) associated with this log.
Supporting Types
GetLogAttribute
- Attribute
Name string - Key that specifies the attribute name.
- Attribute
Value string - Value associated with the attribute key.
- Attribute
Name string - Key that specifies the attribute name.
- Attribute
Value string - Value associated with the attribute key.
- attribute
Name String - Key that specifies the attribute name.
- attribute
Value String - Value associated with the attribute key.
- attribute
Name string - Key that specifies the attribute name.
- attribute
Value string - Value associated with the attribute key.
- attribute_
name str - Key that specifies the attribute name.
- attribute_
value str - Value associated with the attribute key.
- attribute
Name String - Key that specifies the attribute name.
- attribute
Value String - Value associated with the attribute key.
Package Details
- Repository
- oci pulumi/pulumi-oci
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
oci
Terraform Provider.