All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.feingto.cloud.dto.message.LogMessage Maven / Gradle / Ivy

There is a newer version: 2.3.5.RELEASE
Show newest version
package com.feingto.cloud.dto.message;

import com.feingto.cloud.kit.json.JSON;
import lombok.Data;
import lombok.experimental.Accessors;
import org.springframework.integration.support.MessageBuilder;
import org.springframework.messaging.Message;

import java.io.Serializable;

/**
 * 日志消息
 *
 * @author longfei
 */
@Data
@Accessors(chain = true)
public class LogMessage implements Serializable {
    private static final long serialVersionUID = -2807542849641691703L;

    /**
     * 日志级别 1: INFO; 2: Debug; 3: Error
     */
    private Integer level;

    private String content;

    private String user;

    private String ip;

    private String module;

    private String source;

    private String browser;

    private String platform;

    public Message toMessage() {
        return MessageBuilder.withPayload(JSON.obj2json(this)).build();
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy