Home / Function/ newSession() — netty Function Reference

newSession() — netty Function Reference

Architecture documentation for the newSession() function in BoringSSLSessionCallback.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  2ff17fec_bf74_715c_d31e_b69b2fcd115c["newSession()"]
  94eb0a3b_5243_5bc2_d05f_6c638aba2c5d["BoringSSLSessionCallback"]
  2ff17fec_bf74_715c_d31e_b69b2fcd115c -->|defined in| 94eb0a3b_5243_5bc2_d05f_6c638aba2c5d
  542fec67_9434_e1a5_46f0_2a5cbe2252cc["toQuicheQuicSession()"]
  2ff17fec_bf74_715c_d31e_b69b2fcd115c -->|calls| 542fec67_9434_e1a5_46f0_2a5cbe2252cc
  style 2ff17fec_bf74_715c_d31e_b69b2fcd115c fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

codec-classes-quic/src/main/java/io/netty/handler/codec/quic/BoringSSLSessionCallback.java lines 39–67

    @SuppressWarnings("unused")
    void newSession(long ssl, long creationTime, long timeout, byte[] session, boolean isSingleUse,
                    byte @Nullable [] peerParams) {
        if (sessionCache == null) {
            return;
        }

        QuicheQuicSslEngine engine = engineMap.get(ssl);
        if (engine == null) {
            logger.warn("engine is null ssl: {}", ssl);
            return;
        }

        if (peerParams == null) {
            peerParams = EmptyArrays.EMPTY_BYTES;
        }
        if (logger.isDebugEnabled()) {
            logger.debug("ssl: {}, session: {}, peerParams: {}", ssl, Arrays.toString(session),
                    Arrays.toString(peerParams));
        }
        byte[] quicSession = toQuicheQuicSession(session, peerParams);
        if (quicSession != null) {
            logger.debug("save session host={}, port={}",
                    engine.getSession().getPeerHost(), engine.getSession().getPeerPort());
            sessionCache.saveSession(engine.getSession().getPeerHost(), engine.getSession().getPeerPort(),
                    TimeUnit.SECONDS.toMillis(creationTime), TimeUnit.SECONDS.toMillis(timeout),
                    quicSession, isSingleUse);
        }
    }

Domain

Subdomains

Frequently Asked Questions

What does newSession() do?
newSession() is a function in the netty codebase, defined in codec-classes-quic/src/main/java/io/netty/handler/codec/quic/BoringSSLSessionCallback.java.
Where is newSession() defined?
newSession() is defined in codec-classes-quic/src/main/java/io/netty/handler/codec/quic/BoringSSLSessionCallback.java at line 39.
What does newSession() call?
newSession() calls 1 function(s): toQuicheQuicSession.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free