본문 바로가기

Programming110

[Mongo DB] MongoDB Column Store Index 대체 있는 거야? LLM의 등장 이후로 기술에 대한 글은 올릴만한 게 별로 없다.그래도 잘못된 정보나 테스트 결과는 알 수 있으므로 오랜만에 글을 쓴다.Mongo DB에서 집계 쿼리의 성능을 개선해야 하는 일이 있었다.나는 예전에 MS SQL Server에서 Columnstore Index로 집계 쿼리 성능을 비약적으로 상승시킨 경험이 있었다.먼저 Columnstore Index란 기존 우리에게 익숙한 Row Store Index와 다르게 각 Column 단위로 데이터를 저장한다.MS SQL 기준으로 104만 개의 row 단위로 행 그룹을 나누어 Column Segment에 각 열의 데이터를 저장한다.특히 대규모 데이터의 집계 쿼리에서 성능 개선의 효과가 있었다.먼저 Mongo DB 공식 documentation에 Col.. 2025. 7. 26.
[Influx DB] .bat 파일로 정기적으로 DB 백업(+ 복원) Influx DB를 docker로 사용 중인데 가끔 에러 때문에 계속 restart 되는 문제가 있었다.이럴 때마다 DB를 초기화해야 해서 백업 기능이 있는지 확인해 봤다.Enterprise 버전에는 UI에서 정기 백업하기 위한 기능을 설정할 수 있나 보다.https://community.influxdata.com/t/how-to-scheduled-a-backup-of-a-database-in-influxdb-windows/28913 How to scheduled a backup of a database in InfluxDB Windows?Hello I use InfluxDB on Windows. I was wondering if it is possible to scheduled a database ba.. 2024. 11. 23.
.NET 소스 코드 검색 최신 소스코드의 경우 Github에서 보면 된다.https://github.com/dotnet/runtime GitHub - dotnet/runtime: .NET is a cross-platform runtime for cloud, mobile, desktop, and IoT apps..NET is a cross-platform runtime for cloud, mobile, desktop, and IoT apps. - dotnet/runtimegithub.com 다만 가끔 없는 코드도 있는데 이럴 때는 아래 사이트에서 보면 된다.https://source.dot.net/ Source Browser source.dot.net 아래는 ReadAllText의 예시로 비교해 봤다. 2024. 11. 22.
[Oracle DB] VARCHAR2 vs VARCHAR 차이 VARCHAR2와 VARCHAR data type은 같다.그리고 공식 문서에서는 VARCHAR2 사용을 권장한다.The VARCHAR datatype is synonymous with the VARCHAR2 datatype. To avoid possible changes in behavior, always use the VARCHAR2 datatype to store variable-length character strings.https://docs.oracle.com/cd/B28359_01/server.111/b28318/datatype.htm#i1835 Oracle Data Types33/35 26 Oracle Data Types This chapter discusses the Oracle built.. 2024. 11. 21.
[Oracle DB] BLOB이 차지하는 저장 공간 용량 조회 Oracle에서 BLOB이 차지하는 저장 공간 용량을 다음과 같이 조회할 수 있다.SELECT segment_name, segment_type, SUM(bytes) / (1024 * 1024) AS size_in_mbFROM dba_segmentsWHERE segment_name IN ( SELECT segment_name FROM dba_lobs WHERE table_name = '{table_name}' AND owner = '{schema}' ) OR (segment_name = '{table_name}' AND owner = '{schema}')GROUP BY segment_name, .. 2024. 11. 19.
Serilog log levels Serilog로 로깅을 하고 있는데 가끔 어떤 level로 로그를 남겨야 할지 헷갈릴 때가 있다.Serilog의 log levels은 다음과 같이 6개가 있다.참고해서 상황에 따라 적절한 level을 보고 선택하면 될 것 같다.https://github.com/serilog/serilog/wiki/configuration-basics Configuration BasicsSimple .NET logging with fully-structured events. Contribute to serilog/serilog development by creating an account on GitHub.github.comhttps://code-maze.com/csharp-different-log-levels-in-se.. 2024. 11. 17.
[C#] static, readonly 등 modifier 순서 강제하기 (.editorconfig) 이전에 다루었던 C# Coding Style 중에 이런 규칙이 있다.( 2024.07.05 - [Programming/C#] - C# Coding Style )When used on static fields, readonly should come after static (e.g. static readonly not readonly static)..editorconfig 파일은 다음과 같이 순서가 설정되어 있다.csharp_preferred_modifier_order = public,private,protected,internal,static,extern,new,virtual,abstract,sealed,override,readonly,unsafe,volatile,asyncreadonly static, s.. 2024. 8. 14.
[C#] 어떤 프로그램이 설치되어 있는지 확인하기(windows 11) Windows 11에서 c#에서 특정 프로그램이 설치되어 있는지 확인하는 방법은 다음과 같다.예시 소스코드에서는 MongoDB의 설치여부를 확인한다.Console.WriteLine(CheckInstalled("MongoDB"));static bool CheckInstalled(string name){ using var key = Registry.LocalMachine.OpenSubKey(@"SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall") ?? Registry.LocalMachine.OpenSubKey(@"SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall"); if (ke.. 2024. 8. 10.
[Visual Studio] Spell checker 사용하기 Visual Studio 2022 version 17.5 Release 이상부터 사용할 수 있는 Spell checker하지만 이렇게 모든 단어에 밑줄이 쳐지는 모습을 볼 수 있어서 disable 해놓은 사람이 많은 것으로 알고 있다.다음과 같은 방법으로 영어 언어 팩을 설치하면 정상적으로 사용할 수 있다.1. Options > Evironment > Preview Features에서 Spell checker를 체크해서 다시 enable한다. 2. windows 설정(win + I) > 시간 및 언어 > 언어 및 지역 > 기본 설정 언어에서 언어 추가 버튼 클릭한다. 3. 영어를 선택하고 설치한다(Spell checker가 목적이면 언어 팩만 설치해도 된다). 4. 아래와 같이 영어(미국) 언어 팩이 설.. 2024. 8. 10.