ワールドニュース strat_ai_server
-
Kone plans TK Elevator Europe sale to address antitrust concerns, sources say - Reuters
reuters_world | 2026-10-01 14:46 | id : 163792
Kone plans TK Elevator Europe sale to address antitrust concerns, sources say Reuters
-
MUCY.DE - | Stock Price & Latest News - Reuters
reuters_business | 2026-10-01 14:46 | id : 164026
MUCY.DE - | Stock Price & Latest News Reuters
-
About Logan Capital International ETF (LCIV.N) - Reuters
reuters_business | 2026-10-01 14:45 | id : 164207
About Logan Capital International ETF (LCIV.N) Reuters
-
1FRA.MI - Reuters
reuters_business | 2026-10-01 14:43 | id : 163959
1FRA.MI Reuters
-
トランプ氏 中間選挙に向け弱気発言
dmenu_world | 2026-10-01 14:41 | id : 163573
-
MUCY.DE - Reuters
reuters_business | 2026-10-01 14:41 | id : 167984
MUCY.DE Reuters
-
Go Website Sometimes Returns Stale Data After Updating Records
golangbridge | 2026-10-01 14:37 | id : 163748
Hi All, I am experiencing one specific problem with my Go-based website where an API endpoint sometimes returns an older version of a record even though the record has already been updated successfully in the database. The website is built in Go and uses a server-side API to retrieve the data that is displayed to visitors, and under normal circumstances the endpoint returns the current database values as expected. However, after a record is updated, there are situations where a subsequent request from the website still receives the previous value instead of the newly saved one. The database itself shows the updated information when I inspect it directly, so the problem appears to occur somewhere between the completed database update and the response generated by the Go application. This is intermittent rather than a permanent failure, because the same endpoint can return the updated record correctly after some time or after another request is made. I am trying to understand why the Go application can successfully complete the update while a later request can temporarily produce an older representation of the same data. The affected endpoint is used by the website to retrieve information dynamically, so the returned response is what the frontend ultimately displays to visitors. The request itself completes normally when the problem occurs and does not produce an HTTP error or an obvious database failure. Instead, the application returns a valid response containing the previous value, which makes the issue more difficult to diagnose than a normal request or connection error. I have checked the database immediately after performing an update and can confirm that the new value has been committed, but the website can still receive the earlier value when it requests the same record. If I repeat the request later, the response may contain the expected updated data without any change to the record itself. Because the endpoint is otherwise functioning normally, I am trying to determine whether the stale response could be caused by application-level caching, an in-memory data structure, a long-lived database connection, or some other part of the Go application’s request-handling path that is retaining an older value. I have already compared the behavior between records that have recently been updated and records that have not changed, and the issue appears to be specifically noticeable shortly after an update. I have also repeated the same GET request several times and compared the response with the value currently stored in the database. In the cases where the problem occurs, the database contains the new value while the Go endpoint continues returning the old value for a period of time. I have checked the handler responsible for retrieving the record and verified that it is using the expected database query rather than intentionally returning a previously stored response. I have also added basic logging around the update and retrieval operations so I can compare the value being written with the value being returned. This has helped confirm that the behavior is not simply a visual problem in the browser, because the HTTP response itself can contain the older data before the frontend receives it. What I am trying to identify now is why the server-side Go application can produce a stale response even though the underlying database already contains the latest version. One area I would particularly appreciate advice on is how Go developers normally diagnose unexpected stale data when the database has already been updated. The application does not intentionally need long-term caching for these records, so I want to make sure that I am not accidentally retaining an old object somewhere between requests. For example, if a handler or service layer keeps records in memory, I want to understand the safest way to invalidate that data after an update so that the next request always obtains the current database value. I am also wondering whether there is any possibility that concurrent requests are causing an older read to complete after a newer update, resulting in the older object being returned to the client. The website has multiple users accessing the same endpoint, so I want to make sure that the request lifecycle and shared application state are handled correctly. If there are standard Go debugging techniques for tracing a record from the update transaction through the database query and finally into the HTTP response, I would appreciate recommendations on what should be logged and compared. The reason I want to solve this at the application level is that simply refreshing the website or waiting for another request is not a reliable solution. Visitors should receive the current record when they request it, particularly because the data can be changed by administrators while the website is running. I would like to determine whether the stale response is caused by something in my Go code rather than making arbitrary changes to the database or frontend. I am especially interested in understanding whether I should inspect shared maps, structs retained by services, middleware, HTTP response caching, database transaction boundaries, or any other server-side state that could survive between requests. If there is a recommended approach for ensuring that a read occurring after a successful update always sees the committed value, I would also like to understand how that should be implemented safely when multiple requests may be processed concurrently. My main goal is to find the underlying reason for the stale response rather than simply adding delays or repeatedly querying until the expected value eventually appears. Has anyone experienced a Go web application returning an older database value even though the corresponding update has already been committed and the database shows the new value? I would appreciate guidance on how to trace this kind of stale-response behavior through a Go application’s handler, service layer, database query, and HTTP response. I can provide a simplified version of the update handler, retrieval handler, database access code, Go version, and an example showing the old and new values if that would help reproduce the problem. For now, I want to keep the investigation focused on this single issue: a Go website intermittently returns stale record data after the record has already been updated successfully in the database. I would like to understand whether the likely cause is application-side caching or shared state, concurrent request handling, transaction visibility, or another part of the Go request lifecycle, and what the recommended debugging and implementation approach would be to make the endpoint consistently return the current database value. 7 posts - 5 participants Read full topic
-
(42SG.SG) | Stock Price & Latest News - reuters.com
reuters_business | 2026-10-01 14:37 | id : 164271
(42SG.SG) | Stock Price & Latest News reuters.com
-
About Japan Elevator Service Holdings Co Ltd (JPEVF.PK) - Reuters
reuters_business | 2026-10-01 14:33 | id : 163981
About Japan Elevator Service Holdings Co Ltd (JPEVF.PK) Reuters
-
EU governments spent €18 billion in 2026 to cushion energy price jump - Reuters
reuters_world | 2026-10-01 14:33 | id : 163783
EU governments spent €18 billion in 2026 to cushion energy price jump Reuters
-
Finnish PM says suspected break-ins at MPs’ homes could be work of foreign power
guardian_world | 2026-10-01 14:29 | id : 163749
Police investigating reports of politicians’ homes being broken into in last year with nothing being stolenThe Finnish prime minister, Petteri Orpo, has said a foreign power could be responsible for a series of suspected break-ins at the homes of several members of parliament.Police said on Thursday they were investigating multiple reports of MPs’ homes being broken into in the Helsinki area in the last year in which nothing was stolen but subtle signs of breaking and entering were left. Continue reading...
-
日経平均株価 一時2000円以上上昇
dmenu_business | 2026-10-01 14:28 | id : 163574
-
EXCLUSIVE: US tells France and Germany to release diesel stocks or face US export ban, sources say - Reuters
reuters_world | 2026-10-01 14:27 | id : 163619
EXCLUSIVE: US tells France and Germany to release diesel stocks or face US export ban, sources say Reuters
-
EXCLUSIVE: Citing Iran war, US waives rights condition on Egypt military aid - Reuters
reuters_world | 2026-10-01 14:25 | id : 163782
EXCLUSIVE: Citing Iran war, US waives rights condition on Egypt military aid Reuters
-
About BNP Paribas Easy MSCI World II UCITS ETF EUR Accumulation (EEAF.DE) - Reuters
reuters_business | 2026-10-01 14:23 | id : 163814
About BNP Paribas Easy MSCI World II UCITS ETF EUR Accumulation (EEAF.DE) Reuters
-
CEMH.DE - | Stock Price & Latest News - Reuters
reuters_business | 2026-10-01 14:23 | id : 164036
CEMH.DE - | Stock Price & Latest News Reuters
-
McCormick's price hikes spice up quarterly results despite sluggish demand - Reuters
reuters_world | 2026-10-01 14:13 | id : 163745
McCormick's price hikes spice up quarterly results despite sluggish demand Reuters
-
Social media harms democracy by spreading rumors, survey shows - reuters.com
reuters_world | 2026-10-01 14:09 | id : 163781
Social media harms democracy by spreading rumors, survey shows reuters.com
-
TEL1.SG - Reuters
reuters_business | 2026-10-01 14:08 | id : 163967
TEL1.SG Reuters
-
Russian dissident Garry Kasparov says US warned him of danger to his life
bbc_world | 2026-10-01 14:05 | id : 163733
"My family and I will not truly be safe as long as Putin is in power," says the former chess world champion.
-
日銀委員 経済と物価の認識に隔たり
dmenu_business | 2026-10-01 14:02 | id : 163566
-
Flydubai passenger describes hugging his children as plane nosedived during attack
bbc_world | 2026-10-01 13:57 | id : 163721
Adam Polovincik tells the BBC he told his young children "everything is going to be all right" as flight plunged more than 17,000ft (5,200m).
-
HIV prevention drug hailed as breakthrough, but who gets access?
aljazeera_all | 2026-10-01 13:54 | id : 163747
Lenacapavir, a twice-a-year injection could transform HIV prevention, but it will not be available to all.
-
UK PM Burnham says Iran likely behind RAF base incident: Is there evidence?
aljazeera_all | 2026-10-01 13:51 | id : 163740
UK, US and Israeli officials point to Iranian involvement but remain tight-lipped on details.
-
Blasts heard in Ethiopian capital, pro-government forces claim further gains in northern war - Reuters
reuters_world | 2026-10-01 13:48 | id : 163620
Blasts heard in Ethiopian capital, pro-government forces claim further gains in northern war Reuters
-
XB13.DE - | Stock Price & Latest News - Reuters
reuters_business | 2026-10-01 13:47 | id : 164100
XB13.DE - | Stock Price & Latest News Reuters
-
0RL4.L - Reuters
reuters_business | 2026-10-01 13:44 | id : 163843
0RL4.L Reuters
-
0F7N.L - Reuters
reuters_business | 2026-10-01 13:42 | id : 163844
0F7N.L Reuters
-
日経平均株価 一時2000円超上昇
dmenu_business | 2026-10-01 13:42 | id : 163555
-
パワー半導体 3社の統合協議が難航
dmenu_business | 2026-10-01 13:36 | id : 163556